This commit is contained in:
@@ -15,6 +15,7 @@ env:
|
||||
|
||||
jobs:
|
||||
deploy:
|
||||
name: Renovate PR Deployment
|
||||
if: |
|
||||
github.event.pull_request.merged == true &&
|
||||
github.event.pull_request.user.login == 'renovate-bot'
|
||||
@@ -25,11 +26,6 @@ jobs:
|
||||
with:
|
||||
fetch-depth: 0 # required so we can access main^1
|
||||
|
||||
- name: Install Vault
|
||||
uses: cpanato/vault-installer@main
|
||||
with:
|
||||
version: ${{ env.HC_VAULT_VERSION }}
|
||||
|
||||
- name: Save docker-compose.yml before merge (old)
|
||||
run: |
|
||||
git fetch origin main
|
||||
@@ -80,11 +76,6 @@ jobs:
|
||||
echo "No image tag/digest changes detected. Exiting."
|
||||
exit 0
|
||||
|
||||
- name: Generate .env file for Docker Compose
|
||||
run: |
|
||||
vault kv get -format=json rinoa-docker/env | jq -r '.data.data' \
|
||||
| jq -r 'keys[] as $k | "\($k)='\''\(.[$k])'\''"' > .env
|
||||
|
||||
- name: Gotify Notification (Start)
|
||||
uses: eikendev/gotify-action@master
|
||||
with:
|
||||
@@ -93,6 +84,15 @@ jobs:
|
||||
notification_title: "GITEA: [RENOVATE] Docker Compose Deployment @ Rinoa"
|
||||
notification_message: "Starting Docker Compose run..."
|
||||
|
||||
- name: Generate .env from Hashicorp Vault
|
||||
uses: https://git.trez.wtf/Trez/hc-vault-env@main
|
||||
with:
|
||||
HC_VAULT_VERSION: ${{ env.HC_VAULT_VERSION }}
|
||||
HC_VAULT_ADDR: ${{ secrets.TREZ_VAULT_ADDR }}
|
||||
HC_VAULT_USERNAME: ${{ secrets.VAULT_GITEA_USER }}
|
||||
HC_VAULT_PASSWORD: ${{ secrets.VAULT_GITEA_PASSWORD }}
|
||||
HC_VAULT_SECRETS_PATH: rinoa-docker/env
|
||||
|
||||
- name: Docker Compose Deployment
|
||||
uses: hoverkraft-tech/compose-action@b716db5b717cb9b81e391fe638e5aceaa2299e43 # v2.4.0
|
||||
env:
|
||||
|
||||
Reference in New Issue
Block a user