Gitlab Docker fails to start: Error executing actioncreateon resource 'directory[Create /var/opt/gitlab]'
Hello,
Rebuilt my Kubernetes environment and loaded the prior manifest files and persistent data into the new cluster. Having a problem with the Gitlab-CE container though where it looks like it's trying to chown one of the folders which is an NFS volume. Below are the startup errors.
2017-01-24T00:12:19.511389883Z Thank you for using GitLab Docker Image! 2017-01-24T00:12:19.511454137Z Current version: gitlab-ce=8.16.1-ce.0 2017-01-24T00:12:19.511611621Z 2017-01-24T00:12:19.511855434Z Configure GitLab for your system by editing /etc/gitlab/gitlab.rb file 2017-01-24T00:12:19.511870661Z And restart this container to reload settings. 2017-01-24T00:12:19.512113020Z To do it use docker exec: 2017-01-24T00:12:19.512295457Z 2017-01-24T00:12:19.512317668Z docker exec -it gitlab vim /etc/gitlab/gitlab.rb 2017-01-24T00:12:19.512437390Z docker restart gitlab 2017-01-24T00:12:19.512449682Z 2017-01-24T00:12:19.512654530Z For a comprehensive list of configuration options please see the Omnibus GitLab readme 2017-01-24T00:12:19.512668522Z https://gitlab.com/gitlab-org/omnibus-gitlab/blob/master/README.md 2017-01-24T00:12:19.512674301Z 2017-01-24T00:12:19.512677845Z If this container fails to start due to permission problems try to fix it by executing: 2017-01-24T00:12:19.512731236Z 2017-01-24T00:12:19.512740203Z docker exec -it gitlab update-permissions 2017-01-24T00:12:19.512809140Z docker restart gitlab 2017-01-24T00:12:19.512817668Z 2017-01-24T00:12:22.516270257Z Preparing services... 2017-01-24T00:12:22.520633648Z Starting services... 2017-01-24T00:12:22.520751314Z Configuring GitLab package... 2017-01-24T00:12:22.522338857Z /opt/gitlab/embedded/bin/runsvdir-start: line 34: ulimit: max user processes: cannot modify limit: Operation not permitted 2017-01-24T00:12:22.522352720Z /opt/gitlab/embedded/bin/runsvdir-start: line 37: /proc/sys/fs/file-max: Read-only file system 2017-01-24T00:12:22.523046299Z Configuring GitLab... 2017-01-24T00:12:28.705830120Z 2017-01-24T00:12:28.705865282Z ================================================================================ 2017-01-24T00:12:28.705873898Z Error executing action
createon resource 'directory[Create /var/opt/gitlab]' 2017-01-24T00:12:28.705980372Z ================================================================================ 2017-01-24T00:12:28.706061036Z 2017-01-24T00:12:28.706070094Z Errno::EINVAL 2017-01-24T00:12:28.706138190Z ------------- 2017-01-24T00:12:28.706219679Z Invalid argument @ chown_internal - /var/opt/gitlab 2017-01-24T00:12:28.706227771Z 2017-01-24T00:12:28.706300407Z Resource Declaration: 2017-01-24T00:12:28.706308980Z --------------------- 2017-01-24T00:12:28.706377946Z # In /opt/gitlab/embedded/cookbooks/cache/cookbooks/gitlab/recipes/default.rb 2017-01-24T00:12:28.706386005Z 2017-01-24T00:12:28.706458824Z 39: directory "Create /var/opt/gitlab" do 2017-01-24T00:12:28.706477886Z 40: path "/var/opt/gitlab" 2017-01-24T00:12:28.706483147Z 41: owner "root" 2017-01-24T00:12:28.706541591Z 42: group "root" 2017-01-24T00:12:28.706549604Z 43: mode "0755" 2017-01-24T00:12:28.706554123Z 44: recursive true 2017-01-24T00:12:28.706624712Z 45: action :create 2017-01-24T00:12:28.706632762Z 46: end 2017-01-24T00:12:28.706637089Z 47: 2017-01-24T00:12:28.706701580Z 2017-01-24T00:12:28.706786069Z Compiled Resource: 2017-01-24T00:12:28.706794729Z ------------------ 2017-01-24T00:12:28.707033949Z # Declared in /opt/gitlab/embedded/cookbooks/cache/cookbooks/gitlab/recipes/default.rb:39:in
from_file'
2017-01-24T00:12:28.707043881Z
2017-01-24T00:12:28.707047666Z directory("Create /var/opt/gitlab") do
2017-01-24T00:12:28.707051417Z action [:create]
2017-01-24T00:12:28.707054772Z retries 0
2017-01-24T00:12:28.707063176Z retry_delay 2
2017-01-24T00:12:28.707066860Z default_guard_interpreter :default
2017-01-24T00:12:28.707071234Z path "/var/opt/gitlab"
2017-01-24T00:12:28.707074947Z recursive true
2017-01-24T00:12:28.707210317Z declared_type :directory
2017-01-24T00:12:28.707219443Z cookbook_name "gitlab"
2017-01-24T00:12:28.707223306Z recipe_name "default"
2017-01-24T00:12:28.707226929Z owner "root"
2017-01-24T00:12:28.707230341Z group "root"
2017-01-24T00:12:28.707234915Z mode "0755"
2017-01-24T00:12:28.707358201Z end
2017-01-24T00:12:28.707366138Z
2017-01-24T00:12:28.707369882Z Platform:
2017-01-24T00:12:28.707439667Z ---------
2017-01-24T00:12:28.707560803Z x86_64-linux
2017-01-24T00:12:28.707570237Z
2017-01-24T00:12:28.804875474Z `
Here's the Kubernetes manifest:
apiVersion: extensions/v1beta1 kind: Deployment metadata: name: gitlab spec: replicas: 1 template: metadata: labels: app: gitlab spec: containers: - name: gitlab image: gitlab/gitlab-ce:latest imagePullPolicy: Always ports: - containerPort: 443 protocol: TCP name: gitlab-443-tcp - containerPort: 80 name: gitlab-80-tcp protocol: TCP - containerPort: 22 name: gitlab-22-tcp protocol: TCP volumeMounts: - name: gitlab-data mountPath: /var/opt/gitlab - name: gitlab-config mountPath: /etc/gitlab - name: gitlab-logs mountPath: /var/log/gitlab volumes: - name: gitlab-data persistentVolumeClaim: claimName: gitlab-data-claim - name: gitlab-config persistentVolumeClaim: claimName: gitlab-config-claim - name: gitlab-logs persistentVolumeClaim: claimName: gitlab-logs-claim
Not sure what other information to provide.