keypin 0.11.0 → 0.12.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +12 -9
- package/package.json +5 -5
package/README.md
CHANGED
|
@@ -64,22 +64,25 @@ It never changes the file: it tells you which lines to remove. See
|
|
|
64
64
|
|
|
65
65
|
### Production keys
|
|
66
66
|
|
|
67
|
-
|
|
67
|
+
Put each prod value in 1Password first:
|
|
68
68
|
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
69
|
+
- **In a file:** `keypin import .env.production STRIPE_KEY --env prod --vault Private`
|
|
70
|
+
- **Only in GitHub or Cloudflare:** neither keypin nor you can read it back, so make a new key at the provider.
|
|
71
|
+
|
|
72
|
+
For staging, add it to `environments` first (`check` prints the line), then import with `--env staging`.
|
|
72
73
|
|
|
73
|
-
|
|
74
|
-
from = "op://<vault>/<item>/<field>"
|
|
74
|
+
Then `keypin check` prints the TOML to add for each secret a workflow or Worker needs:
|
|
75
75
|
|
|
76
|
+
```toml
|
|
76
77
|
[[keys.STRIPE_KEY.prod.publish]]
|
|
77
78
|
to = "github-actions"
|
|
78
79
|
repo = "me/my-project"
|
|
79
80
|
```
|
|
80
81
|
|
|
81
|
-
Paste it into `keypin.toml` and replace each `<...>`. For
|
|
82
|
-
**Copy Secret Reference**.
|
|
82
|
+
Paste it into `keypin.toml` and replace each `<...>`. For a key you didn't import, `from` takes its reference: in
|
|
83
|
+
1Password, open the field's menu and select **Copy Secret Reference**.
|
|
84
|
+
|
|
85
|
+
Then publish:
|
|
83
86
|
|
|
84
87
|
```sh
|
|
85
88
|
keypin publish --all
|
|
@@ -95,7 +98,7 @@ keypin init [folder] # write keypin.toml and register the pr
|
|
|
95
98
|
keypin check [folder] # report one project; writes nothing
|
|
96
99
|
keypin import <env-file> [NAME...] [--env <name>] --vault <vault>
|
|
97
100
|
# move an env file's values into 1Password and map them
|
|
98
|
-
keypin run -- <command>
|
|
101
|
+
keypin run [--only NAME] -- <command> # run a command with the dev keys, or only the named ones
|
|
99
102
|
keypin publish <VARIABLE> | --all # write prod keys to their destinations
|
|
100
103
|
keypin status # every project's keys, and when each is due for rotation
|
|
101
104
|
keypin unregister [folder] # stop listing a project
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "keypin",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.12.0",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"homepage": "https://github.com/caiopizzol/keypin#readme",
|
|
6
6
|
"bugs": {
|
|
@@ -26,9 +26,9 @@
|
|
|
26
26
|
"x64"
|
|
27
27
|
],
|
|
28
28
|
"optionalDependencies": {
|
|
29
|
-
"@keypin/cli-darwin-arm64": "0.
|
|
30
|
-
"@keypin/cli-darwin-x64": "0.
|
|
31
|
-
"@keypin/cli-linux-x64": "0.
|
|
32
|
-
"@keypin/cli-linux-arm64": "0.
|
|
29
|
+
"@keypin/cli-darwin-arm64": "0.12.0",
|
|
30
|
+
"@keypin/cli-darwin-x64": "0.12.0",
|
|
31
|
+
"@keypin/cli-linux-x64": "0.12.0",
|
|
32
|
+
"@keypin/cli-linux-arm64": "0.12.0"
|
|
33
33
|
}
|
|
34
34
|
}
|