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

Use the --ephemeral flag by default #1189

Closed
toast-gear opened this issue Mar 7, 2022 · 2 comments
Closed

Use the --ephemeral flag by default #1189

toast-gear opened this issue Mar 7, 2022 · 2 comments
Labels
enhancement New feature or request
Milestone

Comments

@toast-gear
Copy link
Collaborator

toast-gear commented Mar 7, 2022

Context
The flag --ephemeral has been the standard flag for a while and we should migrate to using it by default now that GHES 3.3 has been out for over 3 months.

Currently, a runner is configured with the --once flag unless the runner has the environment variable RUNNER_FEATURE_FLAG_EPHEMERAL: "true" set. This env var should be changed to be ENABLE_LEGACY_EPHEMERAL: "true" which results in the runner being configured with the --once flag instead of the default --ephemeral flag.

The bulk of the work has been done on PR #831, it just needs updating to use the desired env var name and the docs need updating:

  1. the new flag needs adding in https://github.com/actions-runner-controller/actions-runner-controller#runner-entrypoint-features
  2. The Ephemeral Runner section needs turning into Static Runners as by default our runners are ephemeral. The configuration option is ephemeral: false and so that's what needs documenting.

EDIT edited to reflect ethmoson's comment

@toast-gear toast-gear added the enhancement New feature or request label Mar 7, 2022
@ethomson
Copy link

ethomson commented Mar 7, 2022

The Ephemeral Runner section needs turning into Long-Lived Runners (or something like that) as by default our runners are ephemeral. The configuration option is ephemeral: false and so that's what needs documenting.

The Actions team uses the term static runners as the opposing notion to ephemeral runners.

@toast-gear
Copy link
Collaborator Author

OK new-ish plan. We are going to remove the --once flag entirely in the subsequent release to this issue being released (due to be part of the next milestone to be released).

Tasks:

  • Update controller to set RUNNER_FEATURE_FLAG_EPHEMERAL to true as part of a runner creation
  • Update docs to highlight this change as well as highlight --once is being removed
  • Update runner entrypoint to highlight --once is deprecated

@mumoshu mumoshu modified the milestones: v0.23.0, v0.22.0 Mar 11, 2022
mumoshu added a commit that referenced this issue Mar 12, 2022
mumoshu added a commit that referenced this issue Mar 12, 2022
…-by-default

Use --ephemeral by default

Every runner is now --ephemeral by default.

Note that this works by ARC setting the RUNNER_FEATURE_FLAG_EPHEMERAL envvar to true by default. Previously you had to explicitly set it to true otherwise the runner was passed --once which is known to various race conditions.

It's worth noting that the very confusing and related configuration, ephemeral: true, which creates --once runners instead of static(or persistent) runners had been the default since many months ago. So, this should be the only change needed to make every runner ephemeral without any explicit configuration.

You can still fall back to static(persistent) runners by setting ephemeral: false, and to --once runners by setting RUNNER_FEATURE_FLAG_EPHEMERAL to "false". But I don't think there're many reasons to do so.

Ref #1189
@toast-gear toast-gear unpinned this issue Apr 6, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants