Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Attaching a start up script to an instance template #443

Open
abdul-imonike opened this issue Feb 25, 2024 · 0 comments
Open

Attaching a start up script to an instance template #443

abdul-imonike opened this issue Feb 25, 2024 · 0 comments

Comments

@abdul-imonike
Copy link

          > Have the same issue with Jenkins 2.249.3 and compute engine plugin 4.3.3 despite installing java in "Startup script" section. Image used: "ubuntu-2004-focal-v20201028"

The issue appears to be related to:
#165

#166
#186

Have you got OSLogin enabled globally? If so then you you will need to create an instance template outside of jenkins and disable OSLogin within the metadata. In Jenkins then you just reference the instance template that you've already created.

That was how I resolved the issue in my case. OSLogin is enabled globally but the GCP Plugin in Jenkins doesn't seem to work when it is enabled so you need to disable it for any Jenkins nodes

Originally posted by @emmaLP in #194 (comment)

Sorry, I know this is a long time after this issue but please would you know if it was possible to attach a start up script to an instance template (not a vm instance) and if possible how to do so? I have successfully set up an instance template in jenkins that was cloned from an existing vm instance that had Java 11 installed but when the on-demand agents are created in GCP, I get the Java not installed error. I am hoping that a start up script will install Java on the fly, on the agents created from the template...Thanks

@abdul-imonike abdul-imonike changed the title > Have the same issue with Jenkins 2.249.3 and compute engine plugin 4.3.3 despite installing java in "Startup script" section. Image used: "ubuntu-2004-focal-v20201028" Attaching a start up script to an instance template Feb 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant