问题
I installed teamcity 9.1 on mac os. I can access teamcity via http://localhost:8111/
. I can change port in file TeamCity/conf/server.xml
by changing <Connector port="8111" protocol="org.apache.coyote.http11.Http11NioProtocol"
.
But how can I change server url e.g. http://localhost:8111/
to http://teamcity.test:8111/
I tried changing in server.xml
from <Engine name="Catalina" defaultHost="localhost">
But after I start teamcity as ./runAll.sh start
it stills can access from http://localhost:8111/
but not from http://teamcity.test:8111/
回答1:
Try changing from Teamcity UI. Go to Administration -> Global Settings and update Server URL property.
回答2:
In order to make server accessible by some other url/domain name you need to update the DNS entry to make the address resolve to the IP address of the new server and after all cached DNS results expire, all clients will be automatically using the new server. Also please note that after changing the URL you'll need to:
- Switch agents to new URL (requires updating serverUrl property in buildAgent.properties on each agent).
- Upon new server startup do not forget to update Server URL on Server configuration administration page.
来源:https://stackoverflow.com/questions/37634554/change-server-url-from-localhost