Skip to content

Commit

Permalink
added redeploy from UAT
Browse files Browse the repository at this point in the history
  • Loading branch information
cqbanh committed Mar 27, 2024
1 parent 0679175 commit 6e5e223
Showing 1 changed file with 18 additions and 6 deletions.
24 changes: 18 additions & 6 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@ jobs:
TARGET_BRANCH: ${{ github.event.inputs.target_branch }}
DEPLOY_LATEST_OPS: ${{ github.event.inputs.deploy_latest_ops }}
NEW_BRANCH: false
APPEND_CHANGE: false

steps:
- name: Init Setup for UAT
Expand Down Expand Up @@ -99,6 +100,7 @@ jobs:
echo "latest_release_branch=$latest_release_branch" >> $GITHUB_ENV
echo "TARGET_BRANCH=$latest_release_branch" >> $GITHUB_ENV
echo "SOURCE_BRANCH=$latest_release_branch" >> $GITHUB_ENV
echo "APPEND_CHANGE=true" >> $GITHUB_ENV
- name: Set OPS branch
if: ${{ env.VENUE == 'OPS' && github.event.inputs.deploy_latest_ops == 'true' }}
Expand Down Expand Up @@ -164,7 +166,7 @@ jobs:
fi
- name: Append text to file (${{ env.SWODLR_SOURCE_REPO }})
if: env.NEW_BRANCH == 'true'
if: env.NEW_BRANCH == 'true' || env.APPEND_CHANGE == 'true'
run: |
echo "${{ env.SWODLR_SOURCE_REPO }} deployment ${{ github.event.inputs.commit }}" >> CHANGE
git add CHANGE
Expand All @@ -182,6 +184,7 @@ jobs:
TARGET_BRANCH: ${{ github.event.inputs.target_branch }}
DEPLOY_LATEST_OPS: ${{ github.event.inputs.deploy_latest_ops }}
NEW_BRANCH: false
APPEND_CHANGE: false

steps:
- name: Init Setup for UAT
Expand Down Expand Up @@ -231,6 +234,7 @@ jobs:
echo "latest_release_branch=$latest_release_branch" >> $GITHUB_ENV
echo "TARGET_BRANCH=$latest_release_branch" >> $GITHUB_ENV
echo "SOURCE_BRANCH=$latest_release_branch" >> $GITHUB_ENV
echo "APPEND_CHANGE=true" >> $GITHUB_ENV
- name: Set OPS branch
if: ${{ env.VENUE == 'OPS' && github.event.inputs.deploy_latest_ops == 'true' }}
Expand Down Expand Up @@ -296,7 +300,7 @@ jobs:
fi
- name: Append text to file (${{ env.SWODLR_SOURCE_REPO }})
if: env.NEW_BRANCH == 'true'
if: env.NEW_BRANCH == 'true' || env.APPEND_CHANGE == 'true'
run: |
echo "${{ env.SWODLR_SOURCE_REPO }} deployment ${{ github.event.inputs.commit }}" >> CHANGE
git add CHANGE
Expand All @@ -314,6 +318,7 @@ jobs:
TARGET_BRANCH: ${{ github.event.inputs.target_branch }}
DEPLOY_LATEST_OPS: ${{ github.event.inputs.deploy_latest_ops }}
NEW_BRANCH: false
APPEND_CHANGE: false

steps:
- name: Init Setup for UAT
Expand Down Expand Up @@ -363,6 +368,7 @@ jobs:
echo "latest_release_branch=$latest_release_branch" >> $GITHUB_ENV
echo "TARGET_BRANCH=$latest_release_branch" >> $GITHUB_ENV
echo "SOURCE_BRANCH=$latest_release_branch" >> $GITHUB_ENV
echo "APPEND_CHANGE=true" >> $GITHUB_ENV
- name: Set OPS branch
if: ${{ env.VENUE == 'OPS' && github.event.inputs.deploy_latest_ops == 'true' }}
Expand Down Expand Up @@ -428,7 +434,7 @@ jobs:
fi
- name: Append text to file (${{ env.SWODLR_SOURCE_REPO }})
if: env.NEW_BRANCH == 'true'
if: env.NEW_BRANCH == 'true' || env.APPEND_CHANGE == 'true'
run: |
echo "${{ env.SWODLR_SOURCE_REPO }} deployment ${{ github.event.inputs.commit }}" >> CHANGE
git add CHANGE
Expand All @@ -446,6 +452,7 @@ jobs:
TARGET_BRANCH: ${{ github.event.inputs.target_branch }}
DEPLOY_LATEST_OPS: ${{ github.event.inputs.deploy_latest_ops }}
NEW_BRANCH: false
APPEND_CHANGE: false

steps:
- name: Init Setup for UAT
Expand Down Expand Up @@ -495,6 +502,7 @@ jobs:
echo "latest_release_branch=$latest_release_branch" >> $GITHUB_ENV
echo "TARGET_BRANCH=$latest_release_branch" >> $GITHUB_ENV
echo "SOURCE_BRANCH=$latest_release_branch" >> $GITHUB_ENV
echo "APPEND_CHANGE=true" >> $GITHUB_ENV
- name: Set OPS branch
if: ${{ env.VENUE == 'OPS' && github.event.inputs.deploy_latest_ops == 'true' }}
Expand Down Expand Up @@ -560,7 +568,7 @@ jobs:
fi
- name: Append text to file (${{ env.SWODLR_SOURCE_REPO }})
if: env.NEW_BRANCH == 'true'
if: env.NEW_BRANCH == 'true' || env.APPEND_CHANGE == 'true'
run: |
echo "${{ env.SWODLR_SOURCE_REPO }} deployment ${{ github.event.inputs.commit }}" >> CHANGE
git add CHANGE
Expand All @@ -578,6 +586,7 @@ jobs:
TARGET_BRANCH: ${{ github.event.inputs.target_branch }}
DEPLOY_LATEST_OPS: ${{ github.event.inputs.deploy_latest_ops }}
NEW_BRANCH: false
APPEND_CHANGE: false

steps:
- name: Init Setup for UAT
Expand Down Expand Up @@ -627,6 +636,7 @@ jobs:
echo "latest_release_branch=$latest_release_branch" >> $GITHUB_ENV
echo "TARGET_BRANCH=$latest_release_branch" >> $GITHUB_ENV
echo "SOURCE_BRANCH=$latest_release_branch" >> $GITHUB_ENV
echo "APPEND_CHANGE=true" >> $GITHUB_ENV
- name: Set OPS branch
if: ${{ env.VENUE == 'OPS' && github.event.inputs.deploy_latest_ops == 'true' }}
Expand Down Expand Up @@ -692,7 +702,7 @@ jobs:
fi
- name: Append text to file (${{ env.SWODLR_SOURCE_REPO }})
if: env.NEW_BRANCH == 'true'
if: env.NEW_BRANCH == 'true' || env.APPEND_CHANGE == 'true'
run: |
echo "${{ env.SWODLR_SOURCE_REPO }} deployment ${{ github.event.inputs.commit }}" >> CHANGE
git add CHANGE
Expand All @@ -710,6 +720,7 @@ jobs:
TARGET_BRANCH: ${{ github.event.inputs.target_branch }}
DEPLOY_LATEST_OPS: ${{ github.event.inputs.deploy_latest_ops }}
NEW_BRANCH: false
APPEND_CHANGE: false

steps:
- name: Init Setup for UAT
Expand Down Expand Up @@ -759,6 +770,7 @@ jobs:
echo "latest_release_branch=$latest_release_branch" >> $GITHUB_ENV
echo "TARGET_BRANCH=$latest_release_branch" >> $GITHUB_ENV
echo "SOURCE_BRANCH=$latest_release_branch" >> $GITHUB_ENV
echo "APPEND_CHANGE=true" >> $GITHUB_ENV
- name: Set OPS branch
if: ${{ env.VENUE == 'OPS' && github.event.inputs.deploy_latest_ops == 'true' }}
Expand Down Expand Up @@ -824,7 +836,7 @@ jobs:
fi
- name: Append text to file (${{ env.SWODLR_SOURCE_REPO }})
if: env.NEW_BRANCH == 'true'
if: env.NEW_BRANCH == 'true' || env.APPEND_CHANGE == 'true'
run: |
echo "${{ env.SWODLR_SOURCE_REPO }} deployment ${{ github.event.inputs.commit }}" >> CHANGE
git add CHANGE
Expand Down

0 comments on commit 6e5e223

Please sign in to comment.