You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: tools/ghsecrets/README.md
+9-9Lines changed: 9 additions & 9 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -30,40 +30,40 @@ By default, `ghsecrets set` assumes you want to store secrets in AWS Secrets Man
30
30
> **⚠️ Note:** Ensure you authenticate with AWS before using the tool:
31
31
>
32
32
> ```sh
33
-
> aws sso login --profile <your-aws-profile>
33
+
> aws sso login --profile <your-aws-sdlc-profile>
34
34
>```
35
-
>By default, use the SDLC profile
35
+
>Use the **SDLC** profilein AWS
36
36
37
37
This will read from `~/.testsecrets` (by default) and create/update a secret in AWS Secrets Manager:
38
38
39
39
```sh
40
-
ghsecrets set --profile <your-aws-profile>
40
+
ghsecrets set --profile <your-aws-sdlc-profile>
41
41
```
42
42
43
43
If you’d like to specify a different file:
44
44
45
45
```sh
46
-
ghsecrets set --file /path/to/mysecrets.env --profile <your-aws-profile>
46
+
ghsecrets set --file /path/to/mysecrets.env --profile <your-aws-sdlc-profile>
47
47
```
48
48
49
49
If you’d like to specify a custom secret name:
50
50
51
51
```sh
52
-
ghsecrets set --secret-id my-custom-secret --profile <your-aws-profile>
52
+
ghsecrets set --secret-id my-custom-secret --profile <your-aws-sdlc-profile>
53
53
```
54
54
55
55
Note: For AWS backend, the tool automatically adds the `testsecrets/` prefix if it is missing. This ensures consistency and allows GitHub Actions to access all secrets with this designated prefix.
56
56
57
57
If you’d like to share this secret with additional AWS IAM principals (e.g., a collaborator’s account):
58
58
59
59
```sh
60
-
ghsecrets set --shared-with arn:aws:iam::123456789012:role/SomeRole --profile <your-aws-profile>
60
+
ghsecrets set --shared-with arn:aws:iam::123456789012:role/SomeRole --profile <your-aws-sdlc-profile>
61
61
```
62
62
63
63
You can specify multiple ARNs using commas:
64
64
65
65
```sh
66
-
ghsecrets set --shared-with arn:aws:iam::123456789012:role/SomeRole,arn:aws:iam::345678901234:root --profile <your-aws-profile>
66
+
ghsecrets set --shared-with arn:aws:iam::123456789012:role/SomeRole,arn:aws:iam::345678901234:root --profile <your-aws-sdlc-profile>
67
67
```
68
68
69
69
#### b) Set secrets in GitHub
@@ -82,13 +82,13 @@ This will:
82
82
If you want to retrieve an existing secret from AWS Secrets Manager, use:
83
83
84
84
```sh
85
-
ghsecrets get --secret-id testsecrets/MySecretName --profile <your-aws-profile>
85
+
ghsecrets get --secret-id testsecrets/MySecretName --profile <your-aws-sdlc-profile>
86
86
```
87
87
88
88
By default, it prints out the Base64-encoded string. To decode it automatically:
89
89
90
90
```sh
91
-
ghsecrets get --secret-id testsecrets/MySecretName --decode --profile <your-aws-profile>
91
+
ghsecrets get --secret-id testsecrets/MySecretName --decode --profile <your-aws-sdlc-profile>
0 commit comments