Skip to content

Commit d48df06

Browse files
DEVOPS-49 workflow file
1 parent f8ac208 commit d48df06

File tree

1 file changed

+38
-38
lines changed

1 file changed

+38
-38
lines changed

.github/workflows/create_or_update_repository_secrets.yaml

Lines changed: 38 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -21,41 +21,41 @@ on:
2121
run-name: ${{ github.actor }} creting or updating ${{ inputs.secret_name }} in ${{ inputs.repository_name }}
2222
jobs:
2323
create_or_update_repository_secrets:
24-
runs-on: ubuntu-latest
25-
steps:
26-
- name: git checkout
27-
uses: actions/checkout@v4
28-
- name: Set up Python
29-
uses: actions/setup-python@v2
30-
with:
31-
python-version: '3.11'
32-
- name: package installations
33-
run: |
34-
pip install pipenv
35-
pipenv install
36-
- name: get public key
37-
id: get-public-key
38-
env:
39-
GH_TOKEN: ${{ secrets.DEVWITHKRISHNA_PERSONAL_ACCESS_TOKEN }}
40-
run: |
41-
pipenv run python3 get_repository_public_key --organization ${{ inputs.organization }} \
42-
--repository_name ${{ inputs.repository_name }}
43-
- name: Encrypt secret
44-
id: encrypt-secret
45-
env:
46-
REPOSITORY_PUBLIC_KEY: ${{ env.REPOSITORY_PUBLIC_KEY }}
47-
SECRET_VALUE: ${{ inputs.secret_value }}
48-
run: |
49-
pipenv run python3 encrypt_using_libnacl.py
50-
- name: create or update repository secret
51-
env:
52-
organization: ${{ inputs.organization }}
53-
secret_name: ${{ inputs.secret_name }}
54-
ENCRYPTED_SECRET: ${{ env.ENCRYPTED_SECRET }}
55-
REPOSITORY_PUBLIC_KEY_ID: ${{ env.REPOSITORY_PUBLIC_KEY_ID }}
56-
GH_TOKEN: ${{ secrets.DEVWITHKRISHNA_PERSONAL_ACCESS_TOKEN }}
57-
run: |
58-
pipenv run python3 create_or_update_repo_secret.py
59-
- name: Completed
60-
run: |
61-
echo "program completed successfully"
24+
runs-on: ubuntu-latest
25+
steps:
26+
- name: git checkout
27+
uses: actions/checkout@v4
28+
- name: Set up Python
29+
uses: actions/setup-python@v2
30+
with:
31+
python-version: '3.11'
32+
- name: package installations
33+
run: |
34+
pip install pipenv
35+
pipenv install
36+
- name: get public key
37+
id: get-public-key
38+
env:
39+
GH_TOKEN: ${{ secrets.DEVWITHKRISHNA_PERSONAL_ACCESS_TOKEN }}
40+
run: |
41+
pipenv run python3 get_repository_public_key --organization ${{ inputs.organization }} \
42+
--repository_name ${{ inputs.repository_name }}
43+
- name: Encrypt secret
44+
id: encrypt-secret
45+
env:
46+
REPOSITORY_PUBLIC_KEY: ${{ env.REPOSITORY_PUBLIC_KEY }}
47+
SECRET_VALUE: ${{ inputs.secret_value }}
48+
run: |
49+
pipenv run python3 encrypt_using_libnacl.py
50+
- name: create or update repository secret
51+
env:
52+
organization: ${{ inputs.organization }}
53+
secret_name: ${{ inputs.secret_name }}
54+
ENCRYPTED_SECRET: ${{ env.ENCRYPTED_SECRET }}
55+
REPOSITORY_PUBLIC_KEY_ID: ${{ env.REPOSITORY_PUBLIC_KEY_ID }}
56+
GH_TOKEN: ${{ secrets.DEVWITHKRISHNA_PERSONAL_ACCESS_TOKEN }}
57+
run: |
58+
pipenv run python3 create_or_update_repo_secret.py
59+
- name: Completed
60+
run: |
61+
echo "program completed successfully"

0 commit comments

Comments
 (0)