Skip to content

Commit 467978b

Browse files
committed
move locking into build action
1 parent 1084152 commit 467978b

File tree

2 files changed

+11
-12
lines changed

2 files changed

+11
-12
lines changed

.github/workflows/build-notebooks-TEMPLATE.yaml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -124,6 +124,17 @@ jobs:
124124
systemctl --user start homebrew.podman.service
125125
echo "PODMAN_SOCK=/run/user/${UID}/podman/podman.sock" >> $GITHUB_ENV
126126
127+
- name: Unlock encrypted secrets with git-crypt
128+
if: ${{ inputs.subscription }}
129+
run: |
130+
sudo apt-get update
131+
sudo apt-get install git-crypt
132+
echo "${GIT_CRYPT_KEY}" | base64 --decode > ./git-crypt-key
133+
git-crypt unlock ./git-crypt-key
134+
rm ./git-crypt-key
135+
env:
136+
GIT_CRYPT_KEY: ${{ secrets.GIT_CRYPT_KEY }}
137+
127138
- name: Add subscriptions from GitHub secret
128139
if: ${{ inputs.subscription }}
129140
run: |

.github/workflows/build-notebooks-pr-rhel.yaml

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -33,16 +33,6 @@ jobs:
3333
with:
3434
ref: "refs/pull/${{ github.event.number }}/merge"
3535

36-
- name: Unlock encrypted secrets with git-crypt
37-
run: |
38-
sudo apt-get update
39-
sudo apt-get install git-crypt
40-
echo "${GIT_CRYPT_KEY}" | base64 --decode > ./git-crypt-key
41-
git-crypt unlock ./git-crypt-key
42-
rm ./git-crypt-key
43-
env:
44-
GIT_CRYPT_KEY: ${{ secrets.GIT_CRYPT_KEY }}
45-
4636
- name: Determine targets to build based on changed files
4737
run: |
4838
set -x
@@ -53,8 +43,6 @@ jobs:
5343
--to-ref '${{ github.event.pull_request.head.ref }}' \
5444
--only-rhel
5545
id: gen
56-
env:
57-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
5846
shell: bash
5947

6048
build:

0 commit comments

Comments
 (0)