mirror of
https://github.com/r-freeman/workflow-with-secrets.git
synced 2024-11-11 11:55:41 +00:00
first commit
This commit is contained in:
commit
b42c5f4f0f
1
.env.gpg
Normal file
1
.env.gpg
Normal file
@ -0,0 +1 @@
|
||||
Њ
‡-о)y—ЙюТgБ‡UlзHВЯљs(*}јД ТПµ9H©tRФwCЯРKї5МхЅpяіФH4§0ЙЗО‰iVБ {?Ч3& ¦jу|с(&L2ЛџХ<D19F>аµцP„¶T:I2hя·q{ в›
|
18
.gitea/workflows/decrypt_secrets.yml
Normal file
18
.gitea/workflows/decrypt_secrets.yml
Normal file
@ -0,0 +1,18 @@
|
||||
name: Decrypt Secrets
|
||||
run-name: Workflow for decrypting secrets
|
||||
on: [ push ]
|
||||
|
||||
jobs:
|
||||
DecryptSecrets:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- name: Decrypt secrets
|
||||
run: ./decrypt_secret.sh
|
||||
env:
|
||||
SECRET_PASSPHRASE: ${{ secrets.SECRET_PASSPHRASE }}
|
||||
# This command is just an example to show your secret being printed
|
||||
# Ensure you remove any print statements of your secrets. GitHub does
|
||||
# not hide secrets that use this workaround.
|
||||
- name: Test printing your secret (Remove this step in production)
|
||||
run: cat ./.env
|
2
.gitignore
vendored
Normal file
2
.gitignore
vendored
Normal file
@ -0,0 +1,2 @@
|
||||
.env
|
||||
.idea/
|
6
decrypt_secrets.sh
Normal file
6
decrypt_secrets.sh
Normal file
@ -0,0 +1,6 @@
|
||||
#!/bin/sh
|
||||
|
||||
# --batch to prevent interactive command
|
||||
# --yes to assume "yes" for questions
|
||||
gpg --quiet --batch --yes --decrypt --passphrase="$SECRET_PASSPHRASE" \
|
||||
--output ./.env ./.env.gpg
|
Loading…
Reference in New Issue
Block a user