Skip to content

Only require GitHub, OAuth and S3 settings on the master - #314

Merged
ericmj merged 1 commit into
mainfrom
agent-config
Oct 8, 2026
Merged

ericmj merged 1 commit into
mainfrom
agent-config

Conversation

@ericmj

@ericmj ericmj commented Oct 8, 2026

Copy link
Copy Markdown
Member

The agents run only the build jobs: they upload OTP builds with the aws CLI and its AWS_* variables, push and sign images, and report back with the agent secret. GitHub (the checkers), ExAws (the S3 store) and the OAuth login run only on the master, but config/runtime.exs read their settings with fetch_env! on every node. That meant the agents had to be given the master's GitHub token, OAuth client secret and S3 key just to boot. Those settings are now read only when BOB_WHO is master, so hexpm/hexpm-ops can give the agents a separate, smaller secret.

Checked by evaluating config/runtime.exs with Config.Reader and MIX_ENV=prod. It now boots with the agent variables alone, and a master without BOB_GITHUB_USER still raises.

The agents run the build jobs, which upload to S3 with the aws CLI and
its AWS_* variables and never call GitHub, the OAuth flow or ExAws. Those
settings were read with fetch_env! on every node, so the agents had to
be given the master's GitHub token, OAuth client secret and S3 key to
boot. They are now read only when BOB_WHO is master.
@ericmj
ericmj merged commit c119559 into main Oct 8, 2026
4 checks passed
@ericmj
ericmj deleted the agent-config branch October 8, 2026 10:37
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.

1 participant