Installing TC Agent on Mac
I have inherited a project that uses TC to build the Mac artifacts. For this I need to install the agent on my Mac.
I have taken my predecessors agent file and placed it on my Mac and tried to run sh agent.sh start. The error I get is regarding Java. At the time this error was correct as this was a brand new Mac and I hadn't installed it yet.
After installing a set the JAVA HOME and JRE HOME variables.
I have type commands such as "which java" and "java -version" with success.
However, the agent.sh start process STILL states I don't have Java and that JAVA HOME and JRE HOME aren't set.
Any ideas?
Please sign in to leave a comment.
Hi,
have you restarted after installing and setting up the variables? The process will inherit the variables from your environment, if the session was started before setting the variables, it's possible they are missing from your session, which a restart should help.
Firstly I didn't have the Java exports added to my bash profile, so on restart they weren't sticking. I have since added them and confirmed that the HOME variable stays on restart. However, I still have the same issue. The response to agent.sh start is below along with various Java checks
Thanks for the report, I can see where the issue lies now. TeamCity doesn't support Java 12 (or 11 for that matter) yet. We are working on its compatibility, but you will need to install a version between 8 and 10: https://confluence.jetbrains.com/display/TCD18/Supported+Platforms+and+Environments#SupportedPlatformsandEnvironments-BuildAgents
A quick follow up, versions 8-10 are supported in TeamCity 2018.2. If you are using an older release, I'd recommend checking with the docs of the specific release.
Thanks Denis, that was it! I rolled back to JDK 8 and it worked a treat. Thanks for all your help