github-action-rotate-aws-secrets icon indicating copy to clipboard operation
github-action-rotate-aws-secrets copied to clipboard

Support organization secrets

Open Alw3ys opened this issue 4 years ago • 5 comments
trafficstars

Add support to manage organization secrets

Alw3ys avatar Apr 21 '21 06:04 Alw3ys

@Alw3ys can you elaborate what is missing for organization secrets?

kneemaa avatar Jun 27 '21 19:06 kneemaa

Hi @kneemaa,

Thanks for your reply! and sure!

Currently there's only support to update repositories actions secret. It's the way the api is called, so if you look at your code at: https://github.com/kneemaa/github-action-rotate-aws-secrets/blob/master/rotate_keys.py#L137 https://api.github.com/repos/{owner_repo}/actions/secrets/{key_name}

In order to support organization secrets another endpoint would need to be called: https://api.github.com/orgs/{org}/actions/secrets/{key_name} Here you can find the github documentation reference: https://docs.github.com/en/rest/reference/actions#create-or-update-an-organization-secret

If you have any further questions, please feel free to ask!

Alw3ys avatar Jun 29 '21 10:06 Alw3ys

For reference I've created a PR with the feature changes,

It's not tested but that should do it for what, Otherwise I hope it gets you a better understand of what feature request I'm asking.

https://github.com/kneemaa/github-action-rotate-aws-secrets/pull/10

Alw3ys avatar Jun 29 '21 10:06 Alw3ys

Is there any chance this FEATURE gets implemented?

This works great, but AWS secret for the GitHub Actions user is normally stored on an organisation level instead of duplicating it into every repo with actions.

Would be a neat addition.

pukkancs avatar May 18 '23 14:05 pukkancs