Skip to content

Commit 567f0f2

Browse files
authored
chore: update CI to use sharding (#581)
1 parent 42ffdb5 commit 567f0f2

File tree

4 files changed

+7
-32
lines changed

4 files changed

+7
-32
lines changed

.github/workflows/example.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ jobs:
1616
strategy:
1717
matrix:
1818
dbversion: ['postgres:latest']
19-
cloudquery-version: ['5.12.1', 'v5.12.1']
19+
cloudquery-version: ['6.8.0', 'v6.8.0']
2020
os: [ubuntu-latest]
2121
fail-fast: false
2222
services:
@@ -49,4 +49,4 @@ jobs:
4949
- name: Sync with CloudQuery
5050
env:
5151
CLOUDQUERY_API_KEY: ${{ secrets.CLOUDQUERY_API_KEY }}
52-
run: cloudquery sync example_configs/serial.yml --log-console
52+
run: cloudquery sync example_configs/spec.yml --log-console

.github/workflows/example_matrix.yml

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ jobs:
1313
runs-on: ubuntu-latest
1414
strategy:
1515
matrix:
16-
region: [us-east-1, us-east-2, us-west-1, us-west-2, eu-west-1, eu-west-2] # List of regions to sync in parallel
16+
shard: [1/6, 2/6, 3/6, 4/6, 5/6, 6/6]
1717
services:
1818
postgres:
1919
image: postgres:latest
@@ -31,12 +31,6 @@ jobs:
3131
--health-retries 5
3232
steps:
3333
- uses: actions/checkout@v4 # Checkout the code so we have access to the config file
34-
- name: Set region in config file
35-
uses: jacobtomlinson/gha-find-replace@099c88fbf2a7da26b083521a8bfa13e4f0886b97
36-
with:
37-
include: example_configs/parallel.yml
38-
find: REGION_PLACEHOLDER
39-
replace: ${{ matrix.region }}
4034
- name: Configure AWS credentials
4135
uses: aws-actions/configure-aws-credentials@e3dd6a429d7300a6a4c196c26e071d42e0343502 # v4
4236
with:
@@ -45,9 +39,9 @@ jobs:
4539
- name: Setup CloudQuery
4640
uses: ./.
4741
with:
48-
version: 'v5.12.1'
42+
version: 'v6.8.0'
4943
- name: Sync with CloudQuery
50-
run: cloudquery sync example_configs/parallel.yml --log-console
44+
run: cloudquery sync example_configs/spec.yml --log-console --shard ${{ matrix.shard }}
5145
env:
5246
CLOUDQUERY_API_KEY: ${{ secrets.CLOUDQUERY_API_KEY }}
5347
CQ_DSN: postgresql://postgres:pass@localhost:5432/postgres?sslmode=disable

example_configs/parallel.yml

Lines changed: 0 additions & 19 deletions
This file was deleted.

example_configs/serial.yml renamed to example_configs/spec.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@ spec:
44
path: 'cloudquery/aws'
55
version: 'v27.20.0' # latest version of aws plugin
66
destinations: ['postgresql']
7-
tables: [aws_s3_buckets]
8-
skip_dependent_tables: true
7+
tables: ['*']
8+
skip_tables: ['aws_cloudtrail_events', 'aws_iam_*']
99
---
1010
kind: destination
1111
spec:

0 commit comments

Comments
 (0)