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

Adding the provider #1

Merged
merged 1 commit into from
Feb 12, 2024
Merged

Adding the provider #1

merged 1 commit into from
Feb 12, 2024

Conversation

fabi200123
Copy link
Contributor

  • Adding the GCP External Provider
  • Update README.md

Copy link
Member

@gabriel-samfira gabriel-samfira left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just a few small comments. I have some doubts in regards to the startup script approach on Linux.

  • The runner user needs to be part of the "admin" group and be able to use passwordless sudo
  • The sudo user must exist
  • curl and tar must be installed

Normally, the package management and user creation management is done by cloud-init, but if we can;t leverage it here, we need to make sure we have a robust enough startup script that it can take care of all the dependency on our own.

Copy link
Member

@gabriel-samfira gabriel-samfira left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One last change. I am still not confident in the init script, but let's see what happens.

// Create user 'runner' if it doesn't exist; '|| true' to ignore if user already exists
"sudo useradd -m " + defaults.DefaultUser + " || true",
// Create the runner home directory if it doesn't exist
"sudo mkdir -p /home/" + defaults.DefaultUser,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You also need to chown runner:runner -R /home/runner.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is done already in the generated script:

sendStatus "enabling runner service"
cp /home/runner/actions-runner/bin/runsvc.sh /home/runner/actions-runner/ || fail "failed to copy runsvc.sh"
sudo chown runner:runner -R /home/runner || fail "failed to change owner"
sudo systemctl daemon-reload || fail "failed to reload systemd"
sudo systemctl enable $SVC_NAME

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good point

@gabriel-samfira gabriel-samfira merged commit 089ffb2 into cloudbase:main Feb 12, 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

Successfully merging this pull request may close these issues.

2 participants