Skip to content
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

ci: build node-runner image #17

Merged
merged 2 commits into from
Jun 19, 2024
Merged
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
26 changes: 21 additions & 5 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ jobs:
with:
submodules: true

- name: Build and load
- name: Build and load nvim image
uses: docker/build-push-action@v5
with:
context: .
Expand All @@ -42,6 +42,19 @@ jobs:
push: false
cache-from: type=gha
cache-to: type=gha,mode=max

- name: Build and load node-runner image
uses: docker/build-push-action@v5
with:
context: .
file: sidecars/node-runner/Containerfile
build-args: ${{ matrix.build-args }}
load: true
tags: l7/node:20-bookworm
push: false
cache-from: type=gha
cache-to: type=gha,mode=max

test-make:
runs-on: ${{ matrix.os }}
strategy:
Expand All @@ -55,18 +68,21 @@ jobs:
- ubuntu-20.04
- ubuntu-22.04
- ubuntu-24.04
image:
- nvim
- runner
steps:
- uses: actions/checkout@v4
with:
submodules: true
- run: make IMAGE_NAME=localhost/foo IMAGE_TAG=bar CMD=${{ matrix.cmd }}
- run: make IMAGE_NAME=localhost/foo-${{ matrix.image }} IMAGE_TAG=bar CMD=${{ matrix.cmd }}
if: ${{ matrix.cmd != '' }}
env:
CMD: ${{ matrix.cmd }}
- run: make IMAGE_NAME=localhost/foo IMAGE_TAG=bar
- run: make IMAGE_NAME=localhost/foo-${{ matrix.image }} IMAGE_TAG=bar
if: ${{ matrix.cmd == '' }}
- run: ${{ matrix.cmd }} image inspect localhost/foo:bar
- run: ${{ matrix.cmd }} image inspect localhost/foo-${{ matrix.image }}:bar
if: ${{ matrix.cmd != '' }}
- run: podman image inspect localhost/foo:bar
- run: podman image inspect localhost/foo-${{ matrix.image }}:bar
if: ${{ matrix.cmd == '' }}
- run: make test
9 changes: 7 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -30,5 +30,10 @@ image_runner:
-f './sidecars/node-runner/Containerfile' \
.

test:
@echo TODO: tests
test: test_nvim test_runner

test_nvim:
@echo TODO: nvim image tests

test_runner:
@echo TODO: node-runner image tests