diff --git a/.github/workflows/piperider-compare-action.yml b/.github/workflows/piperider-compare-action.yml new file mode 100644 index 0000000..bea955d --- /dev/null +++ b/.github/workflows/piperider-compare-action.yml @@ -0,0 +1,50 @@ +name: PipeRider Compare Action + +on: + pull_request: + branches: + - main + +jobs: + piperider-compare-action: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + with: + ref: main + + - name: Set up Python 3.9 + uses: actions/setup-python@v4 + with: + python-version: 3.9 + + - name: Set up dbt + PipeRider + run: | + pip install -r requirements.txt + + - name: Clone git repo ${{ vars.GIT_REPO_URL }} + run: | + url=${{ vars.GIT_REPO_URL }} + git clone $url git_repo + + - name: Read git repo commits + run: | + python3 read_git_repo.py + + - name: Debug + run: | + pwd + ls -la + ls -la .piperider + ls -la .piperider/compare + + - name: PipeRider Compare Action - Upload and Share to PipeRider Cloud Staging + uses: InfuseAI/piperider-compare-action@v1 + env: + PIPERIDER_API_SERVICE: https://staging.cloud.piperider.io + with: + cloud_project: ${{ vars.PIPERIDER_CLOUD_PROJECT }} + cloud_api_token: ${{ secrets.PIPERIDER_CLOUD_TOKEN }} + upload: true + share: true + recipe: default diff --git a/.piperider/compare/default.yml b/.piperider/compare/default.yml new file mode 100644 index 0000000..c798e04 --- /dev/null +++ b/.piperider/compare/default.yml @@ -0,0 +1,15 @@ +base: + branch: main + dbt: + commands: + - dbt deps + - dbt build + piperider: + command: piperider run +target: + dbt: + commands: + - dbt deps + - dbt build + piperider: + command: piperider run