|
11 | 11 | - docker-images/Dockerfile.java-connector-base
|
12 | 12 | - docker-images/Dockerfile.python-connector
|
13 | 13 | - docker-images/Dockerfile.python-connector-base
|
| 14 | + - docker-images/Dockerfile.manifest-only-connector |
14 | 15 |
|
15 | 16 | concurrency:
|
16 | 17 | group: connector-base-images-${{ github.event.pull_request.number }}
|
@@ -41,11 +42,14 @@ jobs:
|
41 | 42 | - 'docker-images/Dockerfile.python-connector'
|
42 | 43 | python-base:
|
43 | 44 | - 'docker-images/Dockerfile.python-connector-base'
|
| 45 | + manifest-only: |
| 46 | + - 'docker-images/Dockerfile.manifest-only-connector' |
44 | 47 | outputs:
|
45 | 48 | java-base: ${{ steps.changes.outputs.java-base }}
|
46 | 49 | python-base: ${{ steps.changes.outputs.python-base }}
|
47 | 50 | java-connector: ${{ steps.changes.outputs.java-connector }}
|
48 | 51 | python-connector: ${{ steps.changes.outputs.python-connector }}
|
| 52 | + manifest-only: ${{ steps.changes.outputs.manifest-only }} |
49 | 53 |
|
50 | 54 | build-java-base-image:
|
51 | 55 | name: Build Java Base Image
|
@@ -299,3 +303,69 @@ jobs:
|
299 | 303 | output-format: "table"
|
300 | 304 | severity-cutoff: critical # TODO: revert to 'high'
|
301 | 305 | fail-build: true
|
| 306 | + |
| 307 | + test-manifest-only-connector-image-matrix: |
| 308 | + runs-on: ubuntu-latest |
| 309 | + needs: [detect-changes] |
| 310 | + if: > |
| 311 | + needs.detect-changes.outputs.manifest-only |
| 312 | + strategy: |
| 313 | + fail-fast: false |
| 314 | + matrix: |
| 315 | + connector: |
| 316 | + - source-pokeapi |
| 317 | + name: Build ${{ matrix.connector }} Manifest-Only Test Image |
| 318 | + environment: |
| 319 | + name: ghcr.io/airbytehq |
| 320 | + url: https://ghcr.io/airbytehq/${{ matrix.connector }} |
| 321 | + steps: |
| 322 | + - name: Checkout code |
| 323 | + uses: actions/checkout@v4 |
| 324 | + with: |
| 325 | + fetch-depth: 1 |
| 326 | + |
| 327 | + - name: Log in to GHCR |
| 328 | + uses: docker/login-action@v3 |
| 329 | + with: |
| 330 | + registry: ghcr.io |
| 331 | + username: ${{ github.repository_owner }} |
| 332 | + password: ${{ secrets.GITHUB_TOKEN }} |
| 333 | + |
| 334 | + - name: Set up Docker Buildx |
| 335 | + uses: docker/setup-buildx-action@v3 |
| 336 | + |
| 337 | + - name: Debug BUILD_ARGS |
| 338 | + run: | |
| 339 | + echo "BASE_IMAGE=docker.io/airbyte/source-declarative-manifest:latest" |
| 340 | + echo "CONNECTOR_NAME=${{ matrix.connector }}" |
| 341 | +
|
| 342 | + - name: Build Manifest-Only Connector Image |
| 343 | + id: docker-build-manifest-only-connector |
| 344 | + uses: docker/build-push-action@v5 |
| 345 | + with: |
| 346 | + context: airbyte-integrations/connectors/${{ matrix.connector }} |
| 347 | + file: docker-images/Dockerfile.manifest-only-connector |
| 348 | + platforms: linux/amd64,linux/arm64 |
| 349 | + tags: | |
| 350 | + ghcr.io/airbytehq/${{ matrix.connector }}:draft-pr-${{ github.event.pull_request.number }} |
| 351 | + ghcr.io/airbytehq/${{ matrix.connector }}:draft-pr-${{ github.event.pull_request.number }}-build${{ github.run_number }} |
| 352 | + build-args: | |
| 353 | + BASE_IMAGE=docker.io/airbyte/source-declarative-manifest:latest |
| 354 | + CONNECTOR_NAME=${{ matrix.connector }} |
| 355 | + push: true |
| 356 | + |
| 357 | + - name: Run `spec` Image Test |
| 358 | + run: | |
| 359 | + docker run \ |
| 360 | + --rm \ |
| 361 | + ghcr.io/airbytehq/${{ matrix.connector }}:draft-pr-${{ github.event.pull_request.number }} \ |
| 362 | + spec |
| 363 | +
|
| 364 | + - name: Run ${{ matrix.connector }} Image Vulnerability Scan |
| 365 | + uses: anchore/scan-action@v6 |
| 366 | + with: |
| 367 | + image: "ghcr.io/airbytehq/${{ matrix.connector }}:draft-pr-${{ github.event.pull_request.number }}" |
| 368 | + output-format: "table" |
| 369 | + severity-cutoff: high |
| 370 | + # Don't fail build for manifest-only connectors since we don't control the base image here |
| 371 | + fail-build: false |
0 commit comments