Skip to content

rollback_changes_targeted #20

rollback_changes_targeted

rollback_changes_targeted #20

# This is a basic workflow to help you get started with Actions
name: rollback_changes_targeted
# Controls when the action will run. Triggers the workflow on push or pull request
# events but only for the main branch
on:
workflow_dispatch:
# push:
# branches: [ main ]
# pull_request:
# branches: [ main ]
inputs:
author:
description: 'Author'
required: true
default: 'liquibase-docs'
id:
description: 'ID'
required: true
default: 'createView-example2'
path:
description: 'Path'
required: true
default: 'Changelogs/changelog.sql'
env:
LIQUIBASE_PRO_LICENSE_KEY: ${{ secrets.LIQUIBASE_PRO_LICENSE_KEY }}
LIQUIBASE_COMMAND_URL: ${{ secrets.LIQUIBASE_COMMAND_URL }}
LIQUIBASE_COMMAND_USERNAME: ${{ secrets.LIQUIBASE_COMMAND_USERNAME }}
LIQUIBASE_COMMAND_PASSWORD: ${{ secrets.LIQUIBASE_COMMAND_PASSWORD }}
LIQUIBASE_COMMAND_CHANGELOG_FILE: ${{ secrets.LIQUIBASE_COMMAND_CHANGELOG_FILE }}
jobs:
Build_Job:
runs-on: ubuntu-latest
environment:
name: DEV
steps:
- uses: actions/checkout@v2
- name: Rolling back DEV
uses: docker://liquibase/liquibase
with:
args: rollbackOneChangeset --changeset-author=${{ github.event.inputs.author }} --changeset-id=${{ github.event.inputs.id }} --changeset-path=${{ github.event.inputs.path }} --force
Test_Job:
needs: Build_Job
runs-on: ubuntu-latest
environment:
name: TEST
steps:
- uses: actions/checkout@v2
- name: Rolling back TEST
uses: docker://liquibase/liquibase
with:
args: rollbackOneChangeset --changeset-author=${{ github.event.inputs.author }} --changeset-id=${{ github.event.inputs.id }} --changeset-path=${{ github.event.inputs.path }} --force
Deploy_Prod_Job:
needs: Test_Job
runs-on: ubuntu-latest
environment:
name: PROD
steps:
- uses: actions/checkout@v2
- name: Rolling back PROD
uses: docker://liquibase/liquibase
with:
args: rollbackOneChangeset --changeset-author=${{ github.event.inputs.author }} --changeset-id=${{ github.event.inputs.id }} --changeset-path=${{ github.event.inputs.path }} --force