LogoopenSUSE Build Service > Projects
Sign Up | Log In

Preconfigured GitLab for "localhost" (10.1-stable)

Gitlab preconfigured for a private local host.

Select the gitlab-config-mysql-apache package for a preconfigured install.

The service will use the `hostname -f` as system name, so this command has to work correctly BEFORE installing the packages. Please make sure your DNS is working.
Add the <fqdn> and gitlab.<fqdn> to your DNS records and/or to your /etc/hosts file.

Gitlab can be reached at: http://gitlab.<fqdn>

User:     root
Password: <your password>

Topics that will need manual configuration:

 * gitlab-runner

     To configure the gitlab-runner, login as root in Gitlab, go to the "Admin area -> Runners" and
     use the URL and registration token when you run this command as root in a shell:

 * Mail confirmation:
     su
     cd /srv/www/vhosts/gitlab-ce/config/initializers
     cp smtp_settings.rb.sample smtp_settings.rb
     chown root.gitlab smtp_settings.rb

   Edit the settings and restart GitLab: systemctl restart gitlab

   Example setting for a GMail account:
     ...
     address: "smtp.gmail.com",
     port: 587,
     user_name: "your.name@gmail.com",
     password: "your password",
     domain: "smtp.gmail.com",
     authentication: :login,
     enable_starttls_auto: true,
     openssl_verify_mode: 'none'
     ...


Other users/passwords used:
 
mysql
-----

Please be aware that changing the root password will break the automatic
database migrations. You will need to manually migrate after every update.
see Hints and Tips.

User:     root
Password: opensuse
User:     gitlab
Password: gitlab1234

!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
WARNING:

This is not a safe setup.
Do NOT use this setup for a public GIT.

!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

---
Hints and tips:

* Gitlab does not like symlinks. Use mount with the bind option instead.

mount command:
mount --bind /home/server/gitlab/gitlab /srv/gitlab

or a fstab entry:
/home/servers/gitlab/gitlab /srv/gitlab none defaults,bind 0 0

* If you want to relink the apache2 directories,
  edit the file /etc/apache2/httpd.conf and
  add in the section <Directory /> the statement "Options FollowSymLinks"

* Manually converting the database
 
   Only for 9.2 to 9.3 migration, run before migration:
     mysql -u root -p<your password> -e "GRANT Trigger ON TABLE gitlabhq_production.* TO 'gitlab'@'localhost'"
     mysql -u root -p<your password> -e "USE gitlabhq_production ; ALTER TABLE web_hooks DROP COLUMN job_events"

   Default migration:
     su root
     systemctl stop gitlab
     cd /srv/www/vhosts/gitlab-ce
     rake.ruby2.4 db:migrate RAILS_ENV=production
     rake.ruby2.4 assets:clean assets:precompile cache:clear RAILS_ENV=production
     rake.ruby2.4 webpack:compile RAILS_ENV=production
     systemctl start gitlab

* Gitlab setup check
     rake.ruby2.4 gitlab:check RAILS_ENV=production

---
KNOWN bugs / problems:

* API error
    Check the secret files in /srv/www/vhosts/gitlab-ce

    .gitlab_shell_secret
    .gitlab_workhorse_secret

    both should not be empty.

    The directory /usr/share/gitlab/shell should contain a copy / link of the shell secret file.
    The directory ????? should contain a copy / link of the workhorse secret file.


    You can generate new codes using:

      hexdump -v -n 64 -e '1/1 "%02x"' /dev/urandom > .gitlab_shell_secret
      hexdump -v -n 64 -e '1/1 "%02x"' /dev/urandom > .gitlab_workhorse_secret

      chown gitlab.gitlab .xxxx_secret
      chmod 600 .xxxx_secret

Comments for home:Ximi1970:Servers:Gitlab:10.1-stable (0)