[Support] GitLab-CE


Recommended Posts

Hi guys,

 

I configured Gitlab-CE about a week ago, and so far it was working smoothly, but today I noticed it was down.

 

When trying to get it back up, I get the following in the logs:
 

Spoiler


      * execute[create gitlab postgresql user] action run

		=========================================================================
        Error executing action `run` on resource 'execute[create gitlab postgres'
        =========================================================================

        RuntimeError
        ------------
        Exhausted service checks and database is still not available

        Cookbook Trace:
        ---------------
        /opt/gitlab/embedded/cookbooks/cache/cookbooks/gitlab/libraries/helpers/'
        /opt/gitlab/embedded/cookbooks/cache/cookbooks/gitlab/libraries/helpers/'
        /opt/gitlab/embedded/cookbooks/cache/cookbooks/postgresql/resources/user'

        Resource Declaration:
        ---------------------
        # In /opt/gitlab/embedded/cookbooks/cache/cookbooks/postgresql/resourcesb

         11:   execute "create #{new_resource.username} postgresql user" do
         12:     command %(/opt/gitlab/bin/#{new_resource.helper.service_cmd} -d)
         13:     user account_helper.postgresql_user
         14:     only_if { new_resource.helper.is_running? && new_resource.helpe}
         15:     not_if { new_resource.helper.is_offline_or_readonly? || new_res}
         16:   end
         17:

        Compiled Resource:
        ------------------
        # Declared in /opt/gitlab/embedded/cookbooks/cache/cookbooks/postgresql/'

        execute("create gitlab postgresql user") do
          action [:run]
          default_guard_interpreter :execute
          command "/opt/gitlab/bin/gitlab-psql -d template1 -c \"CREATE USER \\\"
          backup 5
          declared_type :execute
          cookbook_name "postgresql"
          domain nil
          user "gitlab-psql"
          not_if { #code block }
          only_if { #code block }
        end

        System Info:
        ------------
        chef_version=15.17.4
        platform=ubuntu
        platform_version=20.04
        ruby=ruby 2.7.5p203 (2021-11-24 revision f69aeb8314) [x86_64-linux]
        program_name=/opt/gitlab/embedded/bin/chef-client
        executable=/opt/gitlab/embedded/bin/chef-client

 

For what I can guess, it's trying to run some startup scripts and at some point Postgres either dies off or won't answer. I can't figure out what is happening since the container won't stay up for more than 2 minutes.

 

How do I debug/fix it?

 

The repos are almost empty, and I have copies of everything involved, the only thing I don't want to lose is the user accounts since I made my teammates register already. If there's any way to nuke the thing while keeping the users, and start over it's fine by me too.

 

Thank you!

Link to comment
56 minutes ago, ondono said:

How do I debug/fix it?

 

I don't know but a Google of the error message  took me to this forum discussion:

 

>  Initializing to bash, running gitlab-ctl reconfigure (waiting for the db to fail, then start accepting connections, which took ~12 minutes for me) and then running reconfigure again allows it start.

 

 

Link to comment
12 minutes ago, frakman1 said:

I don't know but a Google of the error message  took me to this forum discussion:

 

First of all thank you for taking the time to respond!

 

I had seen that, but it's not resolving my issue. I can run gitlab-ctl reconfigure once (until it fails), but the container will stop itself, so I can't run it again.

Link to comment
  • 3 weeks later...

I try but I don't really understand this...
 

I set in /opt/gitlab/embedded/service/gitlab-rails/config/gitlab.yml my parameters:

production: &base
  #
  # 1. GitLab app settings
  # ==========================

  ## GitLab settings
  gitlab:
    ## Web server settings (note: host is the FQDN, do not include http://)
    host: mydomain.org
    port: 443
    https: true

 

I understand I had to put in /etc/gitlab/gitlab.rb to keep my data at every restart...

 

but what are this variable?

 

If I use external_url='https://mydomain.org' the data in /etc/gitlab/gitlab.rb are changing on restart... but container doesn't work!

 

instead... if I change manually JUST into /etc/gitlab/gitlab.rb, everythink works!

 

 

I don't find correct variables... so I think I need something like:

gitlab_rails['host'] = 'mydomain.org'

gitlab_rails['port'] = 443

gitlab_rails['https'] = true

gitlab_rails['max_request_duration_seconds'] = 33

 

but just max_request_duration_seconds works and is changed in gitlab.rb

 

what is the correct gitlab_rails['????'] variable for host?

 

thanks

Edited by Jack_T
better
Link to comment
  • 1 month later...
  • 4 weeks later...
Posted (edited)

Greetings.  I've just installed this container and got it up and running but I have 2 things I'm not sure how to do.  1. I want to setup the email.  Do I have to use gmail?  2. Can I change the data directory from cache to the array?  Thanks in advance for your help!

Edited by Spectral Force
Link to comment
  • 2 weeks later...
  • 2 weeks later...
  • 3 weeks later...
On 6/5/2022 at 5:03 PM, Cemion said:

The same question lol. 
Dont undestands why people didnt write it in description/comments... Not first app with same problem

 

There's a file in the gitlab-ce config folder. It's called initial_root_password. It has the root password you need to initially login. Hoping this helps everyone who looks for this.

  • Like 1
Link to comment
  • 3 weeks later...

Tried to install Socat with default parameters and I get this:

root@localhost:# /usr/local/emhttp/plugins/dynamix.docker.manager/scripts/docker run -d --name='socat' --net='bridge' -e TZ="America/New_York" -e HOST_OS="Unraid" -p '443:443/tcp' -p '100:PGID/tcp' --expose 443 'tynor88/socat'

docker: Invalid containerPort: PGID.
See 'docker run --help'.

The command failed.

I'm wanting socat so my HomeAssistant VM can talk to an iTach. Should I be using some parameters other than default? 

 

Cheers, Richard

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.