chore(ci): update Tinybird CI workflow (#11033)
Added a new job to check for changed files before executing the CI workflow. Integrated Tinybird local service, updated environment variables, and refined the CI steps for better functionality and clarity.
This commit is contained in:
39
.github/workflows/ci-tinybird.yaml
vendored
39
.github/workflows/ci-tinybird.yaml
vendored
@ -2,6 +2,7 @@ name: CI Tinybird
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- feature/reimplement-tinybird
|
||||
- main
|
||||
paths:
|
||||
- 'package.json'
|
||||
@ -16,11 +17,37 @@ concurrency:
|
||||
group: ${{ github.workflow }}-${{ github.ref }}
|
||||
cancel-in-progress: true
|
||||
|
||||
env:
|
||||
TINYBIRD_HOST: https://api.eu-central-1.aws.tinybird.co
|
||||
TINYBIRD_TOKEN: ${{ secrets.TB_ADMIN_TOKEN }}
|
||||
|
||||
jobs:
|
||||
ci:
|
||||
uses: tinybirdco/ci/.github/workflows/ci.yml@main
|
||||
changed-files-check:
|
||||
uses: ./.github/workflows/changed-files.yaml
|
||||
with:
|
||||
data_project_dir: packages/twenty-tinybird
|
||||
secrets:
|
||||
tb_admin_token: ${{ secrets.TB_ADMIN_TOKEN }}
|
||||
tb_host: https://api.eu-central-1.aws.tinybird.co
|
||||
files: packages/twenty-tinybird/**
|
||||
ci:
|
||||
runs-on: ubuntu-latest
|
||||
needs: changed-files-check
|
||||
if: needs.changed-files-check.outputs.any_changed == 'true'
|
||||
timeout-minutes: 10
|
||||
defaults:
|
||||
run:
|
||||
working-directory: './packages/twenty-tinybird'
|
||||
services:
|
||||
tinybird:
|
||||
image: tinybirdco/tinybird-local:beta
|
||||
ports:
|
||||
- 7181:7181
|
||||
steps:
|
||||
- uses: actions/checkout@master
|
||||
with:
|
||||
fetch-depth: 1
|
||||
ref: ${{ github.event.pull_request.head.sha }}
|
||||
- name: Install Tinybird CLI
|
||||
run: curl https://tinybird.co | sh
|
||||
- name: Build project
|
||||
run: tb build
|
||||
- name: Test project
|
||||
run: tb test run
|
||||
|
||||
|
||||
Reference in New Issue
Block a user