removing staging
This commit is contained in:
10
.github/workflows/deploy-on-demand-v2.yml
vendored
10
.github/workflows/deploy-on-demand-v2.yml
vendored
@@ -46,7 +46,7 @@ jobs:
|
||||
password: ${{ secrets.AZURE_CLIENT_SECRET }}
|
||||
|
||||
- name: JFrog Auth
|
||||
run: echo ${JFROG_NPMRC} | base64 -d > .npmrc
|
||||
run: echo ${JFROG_NPMRC} | base64 -d > .npmrc
|
||||
|
||||
- name: Set Env
|
||||
env:
|
||||
@@ -56,8 +56,6 @@ jobs:
|
||||
case ${ENV} in
|
||||
dev)
|
||||
ENVIRONMENT=dev;;
|
||||
stage)
|
||||
ENVIRONMENT=stg;;
|
||||
preprod)
|
||||
ENVIRONMENT=prd;;
|
||||
*)
|
||||
@@ -78,14 +76,14 @@ jobs:
|
||||
tags: ${{ env.REGISTRY }}/${{ env.PROJECT }}:${{ env.TAG }}
|
||||
cache-from: type=gha
|
||||
cache-to: type=gha,mode=max
|
||||
|
||||
|
||||
- name: Notify if failure
|
||||
if: ${{ failure() }}
|
||||
uses: rtCamp/action-slack-notify@v2
|
||||
env:
|
||||
SLACK_COLOR: ${{ job.status }}
|
||||
SLACK_MESSAGE: "Failed to build ${{ env.PROJECT }} ${{ inputs.environment }}! :this-is-fine:"
|
||||
|
||||
|
||||
deploy:
|
||||
needs: build
|
||||
runs-on: [self-hosted, azure]
|
||||
@@ -115,7 +113,7 @@ jobs:
|
||||
env:
|
||||
SLACK_COLOR: ${{ job.status }}
|
||||
SLACK_MESSAGE: "Failed to deploy ${{ env.PROJECT }} on ${{ inputs.environment }}! :this-is-fine:"
|
||||
|
||||
|
||||
- name: Notify deploy success
|
||||
uses: rtCamp/action-slack-notify@v2
|
||||
env:
|
||||
|
||||
3
.github/workflows/deploy-on-demand.yml
vendored
3
.github/workflows/deploy-on-demand.yml
vendored
@@ -9,7 +9,6 @@ on:
|
||||
type: choice
|
||||
options:
|
||||
- dev
|
||||
- stage
|
||||
- preprod
|
||||
|
||||
env:
|
||||
@@ -54,8 +53,6 @@ jobs:
|
||||
case ${ENV} in
|
||||
dev)
|
||||
ENVIRONMENT=dev;;
|
||||
stage)
|
||||
ENVIRONMENT=stg;;
|
||||
preprod)
|
||||
ENVIRONMENT=prd;;
|
||||
*)
|
||||
|
||||
111
.github/workflows/deploy.yml
vendored
111
.github/workflows/deploy.yml
vendored
@@ -18,7 +18,7 @@ env:
|
||||
jobs:
|
||||
build-dev:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
|
||||
steps:
|
||||
- name: Slack Notification
|
||||
uses: rtCamp/action-slack-notify@v2
|
||||
@@ -50,14 +50,14 @@ jobs:
|
||||
tags: ${{ env.REGISTRY }}/${{ env.PROJECT }}:${{ env.TAG }}-dev
|
||||
cache-from: type=gha
|
||||
cache-to: type=gha,mode=max
|
||||
|
||||
|
||||
- name: Notify if failure
|
||||
if: ${{ failure() }}
|
||||
uses: rtCamp/action-slack-notify@v2
|
||||
env:
|
||||
SLACK_COLOR: ${{ job.status }}
|
||||
SLACK_MESSAGE: "Failed to build ${{ env.PROJECT }} dev! :this-is-fine:"
|
||||
|
||||
|
||||
deploy-dev:
|
||||
needs: [build-dev]
|
||||
runs-on: [self-hosted, azure]
|
||||
@@ -86,91 +86,13 @@ jobs:
|
||||
env:
|
||||
SLACK_COLOR: ${{ job.status }}
|
||||
SLACK_MESSAGE: "Failed to deploy ${{ env.PROJECT }} on dev! :this-is-fine:"
|
||||
|
||||
|
||||
- name: Notify deploy success
|
||||
uses: rtCamp/action-slack-notify@v2
|
||||
env:
|
||||
MSG_MINIMAL: true
|
||||
SLACK_MESSAGE: "Successfully deployed ${{ env.PROJECT }} to dev! :gopher_party:"
|
||||
|
||||
build-stg:
|
||||
runs-on: ubuntu-latest
|
||||
needs: [deploy-dev]
|
||||
steps:
|
||||
- name: Slack Notification
|
||||
uses: rtCamp/action-slack-notify@v2
|
||||
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Azure Login
|
||||
uses: azure/login@v1
|
||||
with:
|
||||
creds: ${{ secrets.AZURE_CREDENTIALS }}
|
||||
|
||||
- name: Login to ACR
|
||||
uses: docker/login-action@v3
|
||||
with:
|
||||
registry: ${{ env.REGISTRY }}
|
||||
username: ${{ secrets.AZURE_CLIENT_ID }}
|
||||
password: ${{ secrets.AZURE_CLIENT_SECRET }}
|
||||
|
||||
- name: Set up Docker Buildx
|
||||
uses: docker/setup-buildx-action@v3
|
||||
|
||||
- name: Build and push STG
|
||||
uses: docker/build-push-action@v5
|
||||
with:
|
||||
context: .
|
||||
build-args: ENVIRONMENT=stg
|
||||
push: true
|
||||
tags: ${{ env.REGISTRY }}/${{ env.PROJECT }}:${{ env.TAG }}-stg
|
||||
cache-from: type=gha
|
||||
cache-to: type=gha,mode=max
|
||||
|
||||
- name: Notify if failure
|
||||
if: ${{ failure() }}
|
||||
uses: rtCamp/action-slack-notify@v2
|
||||
env:
|
||||
SLACK_COLOR: ${{ job.status }}
|
||||
SLACK_MESSAGE: "Failed to build ${{ env.PROJECT }} stg! :this-is-fine:"
|
||||
|
||||
|
||||
deploy-stg:
|
||||
needs: [deploy-dev, build-stg]
|
||||
runs-on: [self-hosted, azure]
|
||||
environment: stg
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- uses: rtCamp/action-slack-notify@v2
|
||||
env:
|
||||
MSG_MINIMAL: true
|
||||
SLACK_MESSAGE: "Deploying ${{ env.PROJECT }} to stg... :partydeploy:"
|
||||
|
||||
- name: Deploy to stg
|
||||
run: |-
|
||||
helm upgrade \
|
||||
--kube-context stg \
|
||||
--set image.registry=$REGISTRY \
|
||||
--set image.name=$PROJECT \
|
||||
--set image.tag=$TAG-stg \
|
||||
--wait -i -f k8s/values-stg.yaml $PROJECT k8s/
|
||||
|
||||
- name: Notify deploy failure
|
||||
if: ${{ failure() }}
|
||||
uses: rtCamp/action-slack-notify@v2
|
||||
env:
|
||||
SLACK_COLOR: ${{ job.status }}
|
||||
SLACK_MESSAGE: "Failed to deploy ${{ env.PROJECT }} on stg! :this-is-fine:"
|
||||
|
||||
- name: Notify deploy success
|
||||
uses: rtCamp/action-slack-notify@v2
|
||||
env:
|
||||
MSG_MINIMAL: true
|
||||
SLACK_MESSAGE: "Successfully deployed ${{ env.PROJECT }} to stg! :gopher_party:"
|
||||
|
||||
build-preprod:
|
||||
runs-on: ubuntu-latest
|
||||
needs: [deploy-dev]
|
||||
@@ -212,7 +134,7 @@ jobs:
|
||||
env:
|
||||
SLACK_COLOR: ${{ job.status }}
|
||||
SLACK_MESSAGE: "Failed to build ${{ env.PROJECT }} preprod! :this-is-fine:"
|
||||
|
||||
|
||||
deploy-preprod:
|
||||
needs: [deploy-dev, build-preprod]
|
||||
runs-on: [self-hosted, azure]
|
||||
@@ -241,16 +163,16 @@ jobs:
|
||||
env:
|
||||
SLACK_COLOR: ${{ job.status }}
|
||||
SLACK_MESSAGE: "Failed to deploy ${{ env.PROJECT }} on preprod! :this-is-fine:"
|
||||
|
||||
|
||||
- name: Notify deploy success
|
||||
uses: rtCamp/action-slack-notify@v2
|
||||
env:
|
||||
MSG_MINIMAL: true
|
||||
SLACK_MESSAGE: "Successfully deployed ${{ env.PROJECT }} to preprod! :gopher_party:"
|
||||
SLACK_MESSAGE: "Successfully deployed ${{ env.PROJECT }} to preprod! :gopher_party:"
|
||||
|
||||
build-cec-prd:
|
||||
runs-on: ubuntu-latest
|
||||
needs: [deploy-dev, deploy-stg, deploy-preprod]
|
||||
needs: [deploy-dev, deploy-preprod]
|
||||
steps:
|
||||
- name: Slack Notification
|
||||
uses: rtCamp/action-slack-notify@v2
|
||||
@@ -282,7 +204,7 @@ jobs:
|
||||
tags: ${{ env.REGISTRY }}/${{ env.PROJECT }}:${{ env.TAG }}-cec-prd
|
||||
cache-from: type=gha
|
||||
cache-to: type=gha,mode=max
|
||||
|
||||
|
||||
- name: Notify if failure
|
||||
if: ${{ failure() }}
|
||||
uses: rtCamp/action-slack-notify@v2
|
||||
@@ -291,7 +213,7 @@ jobs:
|
||||
SLACK_MESSAGE: "Failed to build ${{ env.PROJECT }} cec-prd! :this-is-fine:"
|
||||
|
||||
deploy-cec-prd:
|
||||
needs: [deploy-dev, deploy-stg, deploy-preprod, build-cec-prd]
|
||||
needs: [deploy-dev, deploy-preprod, build-cec-prd]
|
||||
runs-on: [self-hosted, azure]
|
||||
environment: prd
|
||||
steps:
|
||||
@@ -318,7 +240,7 @@ jobs:
|
||||
env:
|
||||
SLACK_COLOR: ${{ job.status }}
|
||||
SLACK_MESSAGE: "Failed to deploy ${{ env.PROJECT }} on cec-prd! :this-is-fine:"
|
||||
|
||||
|
||||
- name: Notify deploy success
|
||||
uses: rtCamp/action-slack-notify@v2
|
||||
env:
|
||||
@@ -327,7 +249,7 @@ jobs:
|
||||
|
||||
build-cec-euprd:
|
||||
runs-on: ubuntu-latest
|
||||
needs: [deploy-dev, deploy-stg, deploy-preprod]
|
||||
needs: [deploy-dev, deploy-preprod]
|
||||
steps:
|
||||
- name: Slack Notification
|
||||
uses: rtCamp/action-slack-notify@v2
|
||||
@@ -349,7 +271,7 @@ jobs:
|
||||
|
||||
- name: Set up Docker Buildx
|
||||
uses: docker/setup-buildx-action@v3
|
||||
|
||||
|
||||
- name: Build and push CEC-EUPRD
|
||||
uses: docker/build-push-action@v5
|
||||
with:
|
||||
@@ -359,7 +281,7 @@ jobs:
|
||||
tags: ${{ env.REGISTRY }}/${{ env.PROJECT }}:${{ env.TAG }}-cec-euprd
|
||||
cache-from: type=gha
|
||||
cache-to: type=gha,mode=max
|
||||
|
||||
|
||||
- name: Notify if failure
|
||||
if: ${{ failure() }}
|
||||
uses: rtCamp/action-slack-notify@v2
|
||||
@@ -367,9 +289,8 @@ jobs:
|
||||
SLACK_COLOR: ${{ job.status }}
|
||||
SLACK_MESSAGE: "Failed to build ${{ env.PROJECT }} cec-euprd! :this-is-fine:"
|
||||
|
||||
|
||||
deploy-cec-euprd:
|
||||
needs: [deploy-dev, deploy-stg, deploy-preprod, build-cec-euprd]
|
||||
needs: [deploy-dev, deploy-preprod, build-cec-euprd]
|
||||
runs-on: [self-hosted, azure]
|
||||
environment: prd
|
||||
steps:
|
||||
@@ -396,7 +317,7 @@ jobs:
|
||||
env:
|
||||
SLACK_COLOR: ${{ job.status }}
|
||||
SLACK_MESSAGE: "Failed to deploy ${{ env.PROJECT }} on cec-euprd! :this-is-fine:"
|
||||
|
||||
|
||||
- name: Notify deploy success
|
||||
uses: rtCamp/action-slack-notify@v2
|
||||
env:
|
||||
|
||||
Reference in New Issue
Block a user