bod-cli 0.10.5 → 0.10.6
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.
|
@@ -39,10 +39,23 @@ jobs:
|
|
|
39
39
|
git add package.json
|
|
40
40
|
git commit -m "chore: release v${VERSION} [skip ci]"
|
|
41
41
|
|
|
42
|
+
- name: Pull NPM_TOKEN from bodify secrets store
|
|
43
|
+
# The npm token is NOT a per-repo secret — a repo-scoped NPM_TOKEN goes stale silently and every
|
|
44
|
+
# publish then dies on a 404. Pull the canonical token from bodify at publish time, so rotating it
|
|
45
|
+
# in ONE place fixes every repo. Only GitHub secret needed: BODIFY_API_KEY.
|
|
46
|
+
env:
|
|
47
|
+
BODIFY_API_KEY: ${{ secrets.BODIFY_API_KEY }}
|
|
48
|
+
run: |
|
|
49
|
+
TOKEN=$(curl -fsS -H "Authorization: Bearer $BODIFY_API_KEY" \
|
|
50
|
+
"https://bodify.bod.ee/api/apps/9ddba0fb-03bc-4490-8577-5e094b5b6792/env/NPM_TOKEN?environment=prod" \
|
|
51
|
+
| jq -r '.value')
|
|
52
|
+
[ -n "$TOKEN" ] && [ "$TOKEN" != "null" ] || { echo "::error::could not fetch NPM_TOKEN from bodify"; exit 1; }
|
|
53
|
+
echo "::add-mask::$TOKEN"
|
|
54
|
+
echo "NODE_AUTH_TOKEN=$TOKEN" >> "$GITHUB_ENV"
|
|
42
55
|
- name: Publish to npm
|
|
43
56
|
run: npm publish --access public
|
|
44
57
|
env:
|
|
45
|
-
NODE_AUTH_TOKEN: ${{
|
|
58
|
+
NODE_AUTH_TOKEN: ${{ env.NODE_AUTH_TOKEN }}
|
|
46
59
|
|
|
47
60
|
- name: Push tag
|
|
48
61
|
run: |
|