Skip to content

Commit

Permalink
Update MainMigrationWorkflow.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
JayanaGunaweera01 authored Jun 25, 2023
1 parent 660c8ad commit 7adcfc7
Showing 1 changed file with 25 additions and 25 deletions.
50 changes: 25 additions & 25 deletions .github/workflows/MainMigrationWorkflow.yml
Original file line number Diff line number Diff line change
Expand Up @@ -115,22 +115,22 @@ jobs:
echo "All postgre scripts executed successfully!"
- name: Execute Migration Automation Script Ubuntu
run: |
chmod +x ./.github/migration-tester/migration-automation/ubuntu-os/migration-script-ubuntu.sh
sh ./.github/migration-tester/migration-automation/ubuntu-os/migration-script-ubuntu.sh "${{ github.event.inputs.urlOld }}" "${{ github.event.inputs.urlNew }}" "${{ github.event.inputs.currentVersion }}" "${{ github.event.inputs.migratingVersion }}" "${{ github.event.inputs.database }}" "${{ github.event.inputs.os }}" "${{ secrets.MIGRATION_EMAIL }}" "${{ secrets.MIGRATION_PASSWORD }}" "${{ secrets.MIGRATION_PAT }}" | tee "./.github/migration-tester/migration-automation/logs.txt"
chmod +x ${{ github.workspace }}/.github/migration-tester/migration-automation/ubuntu-os/migration-script-ubuntu.sh
sh ${{ github.workspace }}/.github/migration-tester/migration-automation/ubuntu-os/migration-script-ubuntu.sh "${{ github.event.inputs.urlOld }}" "${{ github.event.inputs.urlNew }}" "${{ github.event.inputs.currentVersion }}" "${{ github.event.inputs.migratingVersion }}" "${{ github.event.inputs.database }}" "${{ github.event.inputs.os }}" "${{ secrets.MIGRATION_EMAIL }}" "${{ secrets.MIGRATION_PASSWORD }}" "${{ secrets.MIGRATION_PAT }}" | tee "./.github/migration-tester/migration-automation/logs.txt"
continue-on-error: true

- name: Persist Logs
run: |
mkdir -p ./.github/migration-tester/migration-automation/artifacts
cp ./.github/migration-tester/migration-automation/logs.txt migration-automation/artifacts/
mkdir -p ${{ github.workspace }}/.github/migration-tester/migration-automation/artifacts
cp ${{ github.workspace }}/.github/migration-tester/migration-automation/logs.txt ${{ github.workspace }}/.github/migration-tester/migration-automation/artifacts/
if: ${{ always() }}

- name: Upload Artifacts
uses: actions/upload-artifact@v2
if: always()
with:
name: "logs-${{ github.event.inputs.currentVersion }}-${{ github.event.inputs.migratingVersion }}-${{ github.event.inputs.database }}-${{ github.event.inputs.os }}"
path: ./.github/migration-tester/migration-automation/artifacts
path: ${{ github.workspace }}/.github/migration-tester/migration-automation/artifacts


ubuntu-mysql-migration:
Expand Down Expand Up @@ -196,22 +196,22 @@ jobs:
echo "Copied mssql scripts to docker container"
- name: Execute Migration Automation Script Ubuntu
run: |
chmod +x ./.github/migration-tester/migration-automation/ubuntu-os/migration-script-ubuntu.sh
sh ./.github/migration-tester/migration-automation/ubuntu-os/migration-script-ubuntu.sh "${{ github.event.inputs.urlOld }}" "${{ github.event.inputs.urlNew }}" "${{ github.event.inputs.currentVersion }}" "${{ github.event.inputs.migratingVersion }}" "${{ github.event.inputs.database }}" "${{ github.event.inputs.os }}" "${{ secrets.MIGRATION_EMAIL }}" "${{ secrets.MIGRATION_PASSWORD }}" "${{ secrets.MIGRATION_PAT }}" | tee "./.github/migration-tester/migration-automation/logs.txt"
chmod +x ${{ github.workspace }}/.github/migration-tester/.github/migration-tester/migration-automation/ubuntu-os/migration-script-ubuntu.sh
sh ${{ github.workspace }}/.github/migration-tester/.github/migration-tester/migration-automation/ubuntu-os/migration-script-ubuntu.sh "${{ github.event.inputs.urlOld }}" "${{ github.event.inputs.urlNew }}" "${{ github.event.inputs.currentVersion }}" "${{ github.event.inputs.migratingVersion }}" "${{ github.event.inputs.database }}" "${{ github.event.inputs.os }}" "${{ secrets.MIGRATION_EMAIL }}" "${{ secrets.MIGRATION_PASSWORD }}" "${{ secrets.MIGRATION_PAT }}" | tee "./.github/migration-tester/migration-automation/logs.txt"
continue-on-error: true

- name: Persist Logs
run: |
mkdir -p ./.github/migration-tester/migration-automation/artifacts
cp ./.github/migration-tester/migration-automation/logs.txt migration-automation/artifacts/
mkdir -p ${{ github.workspace }}/.github/migration-tester/.github/migration-tester/migration-automation/artifacts
cp ${{ github.workspace }}/.github/migration-tester/.github/migration-tester/migration-automation/logs.txt migration-automation/artifacts/
if: ${{ always() }}

- name: Upload Artifacts
uses: actions/upload-artifact@v2
if: always()
with:
name: "logs-${{ github.event.inputs.currentVersion }}-${{ github.event.inputs.migratingVersion }}-${{ github.event.inputs.database }}-${{ github.event.inputs.os }}"
path: ./.github/migration-tester/migration-automation/artifacts
path: ${{ github.workspace }}/.github/migration-tester/.github/migration-tester/migration-automation/artifacts

macos-mysql-migration:
if: ${{ github.event.inputs.database == 'mysql' && github.event.inputs.os == 'macos-latest' }}
Expand All @@ -222,21 +222,21 @@ jobs:

- name: Execute Migration Automation Script Mac
run: |
chmod +x ./.github/migration-tester/migration-automation/mac-os/migration-script-mac.sh
sh ./.github/migration-tester/migration-automation/mac-os/migration-script-mac.sh "${{ github.event.inputs.urlOld }}" "${{ github.event.inputs.urlNew }}" "${{ github.event.inputs.currentVersion }}" "${{ github.event.inputs.migratingVersion }}" "${{ github.event.inputs.database }}" "${{ github.event.inputs.os }}" "${{ secrets.MIGRATION_EMAIL }}" "${{ secrets.MIGRATION_PASSWORD }}" "${{ secrets.MIGRATION_PAT }}" | tee "./.github/migration-tester/migration-automation/logs.txt"
chmod +x ${{ github.workspace }}/.github/migration-tester/.github/migration-tester/migration-automation/mac-os/migration-script-mac.sh
sh ${{ github.workspace }}/.github/migration-tester/.github/migration-tester/migration-automation/mac-os/migration-script-mac.sh "${{ github.event.inputs.urlOld }}" "${{ github.event.inputs.urlNew }}" "${{ github.event.inputs.currentVersion }}" "${{ github.event.inputs.migratingVersion }}" "${{ github.event.inputs.database }}" "${{ github.event.inputs.os }}" "${{ secrets.MIGRATION_EMAIL }}" "${{ secrets.MIGRATION_PASSWORD }}" "${{ secrets.MIGRATION_PAT }}" | tee "./.github/migration-tester/migration-automation/logs.txt"
continue-on-error: true
- name: Persist Logs
run: |
mkdir -p ./.github/migration-tester/migration-automation/artifacts
cp ./.github/migration-tester/migration-automation/logs.txt migration-automation/artifacts/
mkdir -p ${{ github.workspace }}/.github/migration-tester/.github/migration-tester/migration-automation/artifacts
cp ${{ github.workspace }}/.github/migration-tester/.github/migration-tester/migration-automation/logs.txt migration-automation/artifacts/
if: ${{ always() }}

- name: Upload Artifacts
uses: actions/upload-artifact@v2
if: always()
with:
name: "logs-${{ github.event.inputs.currentVersion }}-${{ github.event.inputs.migratingVersion }}-${{ github.event.inputs.database }}-${{ github.event.inputs.os }}"
path: ./.github/migration-tester/migration-automation/artifacts
path: ${{ github.workspace }}/.github/migration-tester/.github/migration-tester/migration-automation/artifacts

macos-postgres-migration:
runs-on: ${{ github.event.inputs.os }}
Expand Down Expand Up @@ -269,21 +269,21 @@ jobs:

- name: Execute Migration Automation Script Mac
run: |
chmod +x ./.github/migration-tester/migration-automation/mac-os/migration-script-mac.sh
sh ./.github/migration-tester/migration-automation/mac-os/migration-script-mac.sh "${{ github.event.inputs.urlOld }}" "${{ github.event.inputs.urlNew }}" "${{ github.event.inputs.currentVersion }}" "${{ github.event.inputs.migratingVersion }}" "${{ github.event.inputs.database }}" "${{ github.event.inputs.os }}" "${{ secrets.MIGRATION_EMAIL }}" "${{ secrets.MIGRATION_PASSWORD }}" "${{ secrets.MIGRATION_PAT }}" | tee "./.github/migration-tester/migration-automation/logs.txt"
chmod +x ${{ github.workspace }}/.github/migration-tester/.github/migration-tester/migration-automation/mac-os/migration-script-mac.sh
sh ${{ github.workspace }}/.github/migration-tester/.github/migration-tester/migration-automation/mac-os/migration-script-mac.sh "${{ github.event.inputs.urlOld }}" "${{ github.event.inputs.urlNew }}" "${{ github.event.inputs.currentVersion }}" "${{ github.event.inputs.migratingVersion }}" "${{ github.event.inputs.database }}" "${{ github.event.inputs.os }}" "${{ secrets.MIGRATION_EMAIL }}" "${{ secrets.MIGRATION_PASSWORD }}" "${{ secrets.MIGRATION_PAT }}" | tee "./.github/migration-tester/migration-automation/logs.txt"
continue-on-error: true
- name: Persist Logs
run: |
mkdir -p ./.github/migration-tester/migration-automation/artifacts
cp ./.github/migration-tester/migration-automation/logs.txt migration-automation/artifacts/
mkdir -p ${{ github.workspace }}/.github/migration-tester/.github/migration-tester/migration-automation/artifacts
cp ${{ github.workspace }}/.github/migration-tester/.github/migration-tester/migration-automation/logs.txt migration-automation/artifacts/
if: ${{ always() }}

- name: Upload Artifacts
uses: actions/upload-artifact@v2
if: always()
with:
name: "logs-${{ github.event.inputs.currentVersion }}-${{ github.event.inputs.migratingVersion }}-${{ github.event.inputs.database }}-${{ github.event.inputs.os }}"
path: ./.github/migration-tester/migration-automation/artifacts
path: ${{ github.workspace }}/.github/migration-tester/.github/migration-tester/migration-automation/artifacts

macos-mssql-migration:
if: ${{ github.event.inputs.database == 'mssql' && github.event.inputs.os == 'macos-latest' }}
Expand Down Expand Up @@ -317,21 +317,21 @@ jobs:

- name: Execute Migration Automation Script Mac
run: |
chmod +x ./.github/migration-tester/migration-automation/mac-os/migration-script-mac.sh
sh ./.github/migration-tester/migration-automation/mac-os/migration-script-mac.sh "${{ github.event.inputs.urlOld }}" "${{ github.event.inputs.urlNew }}" "${{ github.event.inputs.currentVersion }}" "${{ github.event.inputs.migratingVersion }}" "${{ github.event.inputs.database }}" "${{ github.event.inputs.os }}" "${{ secrets.MIGRATION_EMAIL }}" "${{ secrets.MIGRATION_PASSWORD }}" "${{ secrets.MIGRATION_PAT }}" | tee "./.github/migration-tester/migration-automation/logs.txt"
chmod +x ${{ github.workspace }}/.github/migration-tester/.github/migration-tester/migration-automation/mac-os/migration-script-mac.sh
sh ${{ github.workspace }}/.github/migration-tester/.github/migration-tester/migration-automation/mac-os/migration-script-mac.sh "${{ github.event.inputs.urlOld }}" "${{ github.event.inputs.urlNew }}" "${{ github.event.inputs.currentVersion }}" "${{ github.event.inputs.migratingVersion }}" "${{ github.event.inputs.database }}" "${{ github.event.inputs.os }}" "${{ secrets.MIGRATION_EMAIL }}" "${{ secrets.MIGRATION_PASSWORD }}" "${{ secrets.MIGRATION_PAT }}" | tee "./.github/migration-tester/migration-automation/logs.txt"
continue-on-error: true
- name: Persist Logs
run: |
mkdir -p ./.github/migration-tester/migration-automation/artifacts
cp ./.github/migration-tester/migration-automation/logs.txt migration-automation/artifacts/
mkdir -p ${{ github.workspace }}/.github/migration-tester/.github/migration-tester/migration-automation/artifacts
cp ${{ github.workspace }}/.github/migration-tester/.github/migration-tester/migration-automation/logs.txt migration-automation/artifacts/
if: ${{ always() }}

- name: Upload Artifacts
uses: actions/upload-artifact@v2
if: always()
with:
name: "logs-${{ github.event.inputs.currentVersion }}-${{ github.event.inputs.migratingVersion }}-${{ github.event.inputs.database }}-${{ github.event.inputs.os }}"
path: ./.github/migration-tester/migration-automation/artifacts
path: ${{ github.workspace }}/.github/migration-tester/.github/migration-tester/migration-automation/artifacts

validate-migration:
needs:
Expand Down

0 comments on commit 7adcfc7

Please sign in to comment.