我有一个docker container正在运行的gitlab community edition.
它工作正常,只是容器仍然存在unhealthty
问题来自/opt/gitlab/etc/gitlab-healthcheck-rc文件。它包含url='http://localhost:80/gitlab/help'并且应该是url='http://myhostname:80/gitlab/help'
如果我改变它,它的工作。但是每次有 agitlab-ctl reconfigure时,它都会返回localhost
确实,在日志中我可以看到
* template[/opt/gitlab/etc/gitlab-healthcheck-rc] action create
- update content in file /opt/gitlab/etc/gitlab-healthcheck-rc from 1e4e16 to 1a5b11
但从哪里来localhost?有没有办法以正确的值启动容器?
我在其中添加了一个hostname: myhostname,docker-compose.yml但它不起作用。