According to Http://docs.gitlab.com/ce/administration/container_registry.html#container-registry-domain-configuration
Official document configuration GITLAB.RB, results error:
Recipe:gitlab::d efault
* Directory[/etc/gitlab] Action Create (up to date)
================================================================================
Recipe Compile Error in/opt/gitlab/embedded/cookbooks/cache/cookbooks/gitlab/recipes/default.rb
================================================================================
Nomethoderror
-------------
Undefined method ' []= ' for Nil:nilclass
Cookbook Trace:
---------------
/opt/gitlab/embedded/cookbooks/cache/cookbooks/gitlab/recipes/default.rb:35:in ' From_file '
Relevant File Content:
----------------------
/OPT/GITLAB/EMBEDDED/COOKBOOKS/CACHE/COOKBOOKS/GITLAB/RECIPES/DEFAULT.RB:
28:group "root"
29:mode "0775"
30:action:nothing
31:end.run_action (: Create)
:
33:gitlab[:n ODE] = node
34:if file.exists? (" /etc/gitlab/gitlab.rb ")
35>> gitlab.from_file ("/etc/gitlab/gitlab.rb ")
36:end
37:node.consume_ Attributes (Gitlab.generate_config (node[' FQDN '))
:
39:if file.exists? (" /var/opt/gitlab/bootstrapped ")
40:node.set[' Gitlab ' [' Bootstrap '] [' enable '] = False
41:end
:
43: Directory "/var/opt/gitlab" do
44:owner "root"
Running handlers:
[2016-08-08t13:25:18+08:00] Error:running Exception handlers
Running handlers Complete
[2016-08-08t13:25:18+08:00] Error:exception handlers Complete
Chef Client failed. 0 Resources updated in seconds
[2016-08-08t13:25:18+08:00] Fatal:stacktrace dumped To/opt/gitlab/embedded/cookbooks/cache/chef-stacktrace.out
[2016-08-08t13:25:18+08:00] Error:undefined method ' []= ' for Nil:nilclass
[2016-08-08t13:25:19+08:00] Fatal:chef::exceptions::childconvergeerror:chef Run Process exited unsuccessfully (exit code 1)
Reason:
Gitlab version too low!! Container registry is not supported.
Gitlab-ce supports container registry starting from 8.8:
https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/4040
View Gitlab version:
Https://gityu.com/help
Upgrade Gitlab-ce:
sudo yum install Gitlab-ce
Https://gitlab.com/gitlab-org/omnibus-gitlab/blob/master/doc/update/README.md#updating-using-the-official-repositories
Use Yum info gitlab-ce to view the version, if it is still below the latest version;
Update cache:
Yum Makecache Fast
Refer to Https://packages.gitlab.com/gitlab/gitlab-ce/install using RPM below
Curl-s https://packages.gitlab.com/install/repositories/gitlab/gitlab-ce/script.rpm.sh | sudo bash
Update Reposiroty
At this point, yum info Gitlab-ce sees that the version has been updated:
At last
sudo yum install Gitlab-ce
Install the latest version.
Omnibus Gitlab Installation Container Registry error