Skip to content

Commit

Permalink
ci: change prd pipeline to new infra
Browse files Browse the repository at this point in the history
  • Loading branch information
ArneD committed Feb 5, 2024
1 parent d92b6d3 commit 3bfa4d2
Showing 1 changed file with 49 additions and 12 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ jobs:
SLACK_CHANNEL: ${{ secrets.VBR_NOTIFIER_CHANNEL_NAME }}
REPOSITORY_NAME: ${{ env.REPOSITORY_NAME }}

deploy_to_production:
deploy_services_to_production:
if: github.repository_owner == 'Informatievlaanderen'
needs: [ deploy_to_production_start_slack ]
name: Deploy to Production
Expand All @@ -44,27 +44,27 @@ jobs:
'streetname-registry-backoffice-api',
'streetname-registry-consumer',
'streetname-registry-producer',
'streetname-registry-migrator-streetname',
'streetname-registry-producer-snapshot-oslo',
'streetname-registry-projections-backoffice',
'streetname-registry-snapshot-verifier'
'streetname-registry-projections-backoffice'
]

steps:
- name: CD services
env:
BUILD_URL: ${{ secrets.VBR_AWS_BUILD_API }}/${{matrix.services}}
STATUS_URL: ${{ secrets.VBR_AWS_BUILD_STATUS_API }}/${{matrix.services}}
uses: informatievlaanderen/awscurl-polling-action/polling-action@v1.0.1
BUILD_URL: ${{ vars.VBR_AWS_BUILD_API_DEVOPS }}/${{matrix.services}}
STATUS_URL: ${{ vars.VBR_AWS_BUILD_STATUS_API_DEVOPS }}/${{matrix.services}}
uses: informatievlaanderen/awscurl-polling-action/polling-action@main
with:
environment: acc
environment: prd
version: ${{ github.event.inputs.version }}
status-url: $STATUS_URL
deploy-url: $BUILD_URL
access-key: ${{ secrets.VBR_AWS_BUILD_USER_ACCESS_KEY_ID }}
secret-key: ${{ secrets.VBR_AWS_BUILD_USER_SECRET_ACCESS_KEY }}
region: eu-west-1
access-key: ${{ secrets.VBR_AWS_ACCESS_KEY_ID_DEVOPS }}
secret-key: ${{ secrets.VBR_AWS_SECRET_ACCESS_KEY_DEVOPS }}
interval: 2
deploy-target: 'agb_ecs_service'
domain: 'basisregisters'
project: 'basisregisters'

- name: output CD services
shell: bash
Expand All @@ -73,9 +73,46 @@ jobs:
echo Status: ${{ steps.awscurl-polling-action.outputs.status }}
echo ${{ steps.awscurl-polling-action.outputs.final-message }}
deploy_tasks_to_production:
if: github.repository_owner == 'Informatievlaanderen'
needs: [ deploy_to_production_start_slack ]
name: Deploy to Production
runs-on: ubuntu-latest
strategy:
matrix:
services: [
#'streetname-registry-migrator-streetname',
'streetname-registry-snapshot-verifier'
]

steps:
- name: CD tasks
env:
BUILD_URL: ${{ vars.VBR_AWS_BUILD_API_DEVOPS }}/${{matrix.services}}
STATUS_URL: ${{ vars.VBR_AWS_BUILD_STATUS_API_DEVOPS }}/${{matrix.services}}
uses: informatievlaanderen/awscurl-polling-action/polling-action@main
with:
environment: prd
version: ${{ github.event.inputs.version }}
status-url: $STATUS_URL
deploy-url: $BUILD_URL
access-key: ${{ secrets.VBR_AWS_ACCESS_KEY_ID_DEVOPS }}
secret-key: ${{ secrets.VBR_AWS_SECRET_ACCESS_KEY_DEVOPS }}
interval: 2
deploy-target: 'ecs_scheduled_task'
domain: 'basisregisters'
project: 'basisregisters'

- name: output CD tasks
shell: bash
run: |
echo build-uuid: ${{ steps.awscurl-polling-action.outputs.build-uuid }}
echo Status: ${{ steps.awscurl-polling-action.outputs.status }}
echo ${{ steps.awscurl-polling-action.outputs.final-message }}
deploy_lambda_to_production:
if: github.repository_owner == 'Informatievlaanderen'
needs: [deploy_to_production]
needs: [deploy_services_to_production, deploy_tasks_to_production]
name: Deploy lambda to production
runs-on: ubuntu-latest

Expand Down

0 comments on commit 3bfa4d2

Please sign in to comment.