Skip to content

udpate ci #351

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 9 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions .github/workflows/create_s3_ds_cd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,10 @@
- main
jobs:
cd:
uses: tinybirdco/ci/.github/workflows/cd.yml@v4.0.1
uses: tinybirdco/ci/.github/workflows/cd.yml@v4.1.0
with:
data_project_dir: ./create_s3_datasource
tb_env: prod
secrets:
tb_admin_token: ${{ secrets.TB_ADMIN_TOKEN_CREATE_S3_DS }}
tb_admin_token: ${{ secrets.TB_ADMIN_TOKEN_CREATE_S3_DS_PROD }}
tb_host: https://api.tinybird.co
24 changes: 24 additions & 0 deletions .github/workflows/create_s3_ds_cd_stg.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@

##################################################
### Visit https://github.com/tinybirdco/ci ###
### for more details or custom CI/CD ###
##################################################

name: Tinybird - CD Workflow

on:
workflow_dispatch:
push:
paths:
- 'create_s3_datasource/**'
branches:
- main
jobs:
cd:
uses: tinybirdco/ci/.github/workflows/cd.yml@v4.1.0
with:
data_project_dir: ./create_s3_datasource
tb_env: stg
secrets:
tb_admin_token: ${{ secrets.TB_ADMIN_TOKEN_CREATE_S3_DS }}
tb_host: https://api.tinybird.co
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,10 @@

jobs:
ci:
uses: tinybirdco/ci/.github/workflows/ci.yml@v4.0.1
uses: tinybirdco/ci/.github/workflows/ci.yml@v4.1.0
with:
data_project_dir: ./create_s3_datasource
tb_env: stg
secrets:
tb_admin_token: ${{ secrets.TB_ADMIN_TOKEN_CREATE_S3_DS }}
tb_host: https://api.tinybird.co
6 changes: 1 addition & 5 deletions create_s3_datasource/datasources/s3_sample.datasource
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,4 @@ SCHEMA >
ENGINE MergeTree
ENGINE_SORTING_KEY t

IMPORT_SERVICE s3_iamrole
IMPORT_CONNECTION_NAME create-s3-datasource
IMPORT_BUCKET_URI s3://dev-alrocar/folder1/*.csv
IMPORT_STRATEGY append
IMPORT_SCHEDULE @on-demand
INCLUDE "../includes/s3_${TB_ENV}.incl"
5 changes: 5 additions & 0 deletions create_s3_datasource/includes/s3_stg.incl
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
IMPORT_SERVICE s3_iamrole
IMPORT_CONNECTION_NAME create-s3-datasource
IMPORT_BUCKET_URI s3://dev-alrocar/folder1/*.csv
IMPORT_STRATEGY append
IMPORT_SCHEDULE @on-demand
5 changes: 5 additions & 0 deletions create_s3_datasource/includes/stg_prod.incl
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
IMPORT_SERVICE s3_iamrole
IMPORT_CONNECTION_NAME create-s3-datasource
IMPORT_BUCKET_URI s3://dev-alrocar/folder2/*.csv
IMPORT_STRATEGY append
IMPORT_SCHEDULE @on-demand