Skip to content

Commit 673505b

Browse files
authored
Signing everything inside circle ci (#538)
1 parent 918892b commit 673505b

File tree

1 file changed

+25
-15
lines changed

1 file changed

+25
-15
lines changed

.circleci/config.yml

Lines changed: 25 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -102,6 +102,16 @@ jobs:
102102
steps:
103103
- setup_remote_docker
104104
- checkout
105+
- run:
106+
name: Import GPG Key
107+
command: |
108+
echo -e "$GPG_PRIVATE_KEY" | gpg --import
109+
echo -e "trust\n5\ny\n" | gpg --command-fd 0 --edit-key 4C19E4CC17E67B7B
110+
- run:
111+
name: Configure Git for Signing
112+
command: |
113+
git config --global user.signingkey 4C19E4CC17E67B7B
114+
git config --global commit.gpgSign true
105115
- run:
106116
name: "Create build branch"
107117
command: |
@@ -170,7 +180,7 @@ jobs:
170180
git pull
171181
# Check for wasm changes
172182
git add framework/artifacts --force
173-
git commit -m 'Update framework WASM' || true
183+
git commit -S -m 'Update framework WASM' || true
174184
git push origin "$CIRCLE_BRANCH-build" || true
175185
- run:
176186
name: Remove temporary branch if it failed during build framework
@@ -228,7 +238,7 @@ jobs:
228238
git pull
229239
# Check for wasm changes
230240
git add modules/artifacts --force
231-
git commit -m 'Update modules WASM [skip ci]' || true
241+
git commit -S -m 'Update modules WASM [skip ci]' || true
232242
git push origin "$CIRCLE_BRANCH-build" || true
233243
- run:
234244
name: Remove temporary branch if it failed during building modules
@@ -285,7 +295,7 @@ jobs:
285295
git pull
286296
# Check for schema changes
287297
git add schema --force
288-
git commit -m 'Update Schemas [skip ci]' || true
298+
git commit -S -m 'Update Schemas [skip ci]' || true
289299
git push origin "$CIRCLE_BRANCH-build" || true
290300
- run:
291301
name: Remove temporary branch if it failed during build schemas
@@ -303,16 +313,6 @@ jobs:
303313
steps:
304314
- setup_remote_docker
305315
- checkout
306-
- run:
307-
name: Import GPG Key
308-
command: |
309-
echo -e "$GPG_PRIVATE_KEY" | gpg --import
310-
echo -e "trust\n5\ny\n" | gpg --command-fd 0 --edit-key 4C19E4CC17E67B7B
311-
- run:
312-
name: Configure Git for Signing
313-
command: |
314-
git config --global user.signingkey 4C19E4CC17E67B7B
315-
git config --global commit.gpgSign true
316316
- run:
317317
name: "Merge build branch"
318318
command: |
@@ -377,13 +377,23 @@ jobs:
377377
export TEST_MNEMONIC="$decoded_value"
378378
cd framework
379379
cargo run --bin full_deploy -- --network-ids $NETWORKS
380+
- run:
381+
name: Import GPG Key
382+
command: |
383+
echo -e "$GPG_PRIVATE_KEY" | gpg --import
384+
echo -e "trust\n5\ny\n" | gpg --command-fd 0 --edit-key 4C19E4CC17E67B7B
385+
- run:
386+
name: Configure Git for Signing
387+
command: |
388+
git config --global user.signingkey 4C19E4CC17E67B7B
389+
git config --global commit.gpgSign true
380390
- run:
381391
name: Commit and push deploy file
382392
command: |
383393
git config --global user.name 'CircleCI'
384394
git config --global user.email 'circleci@example.com'
385395
git add framework/scripts --force
386-
git commit -m 'Update deploy deploy file [skip ci]'
396+
git commit -S -m 'Update deploy deploy file [skip ci]'
387397
git push origin $CIRCLE_BRANCH
388398
- run:
389399
name: Commit and push state file
@@ -392,7 +402,7 @@ jobs:
392402
git config --global user.email 'circleci@example.com'
393403
cp ~/.cw-orchestrator/state.json ./framework/scripts/
394404
git add ./framework/scripts/state.json
395-
git commit -m 'Update deploy deploy file [skip ci]'
405+
git commit -S -m 'Update deploy deploy file [skip ci]'
396406
git push origin $CIRCLE_BRANCH
397407
- save_cache:
398408
paths:

0 commit comments

Comments
 (0)