Skip to content
This repository was archived by the owner on Oct 13, 2023. It is now read-only.

Commit c4b779f

Browse files
committed
set secret for private repo only
1 parent cc8db93 commit c4b779f

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

rotate_keys.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -136,7 +136,8 @@ def upload_secret(owner_org,key_name,encrypted_value,pub_key_id,github_token):
136136
f'https://api.github.com/orgs/{owner_org}/actions/secrets/{key_name}',
137137
json={
138138
'encrypted_value': encrypted_value,
139-
'key_id': pub_key_id
139+
'key_id': pub_key_id,
140+
'visibility': f"private"
140141
},
141142
headers={'Authorization': f"token {github_token}"}
142143
)

0 commit comments

Comments
 (0)