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: add job to build the container to validate #335

Merged
merged 1 commit into from
Jun 17, 2021
Merged
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
17 changes: 17 additions & 0 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,23 @@ jobs:
- name: Ensure no files were modified as a result of the build
run: git update-index --refresh && git diff-index --quiet HEAD -- || git diff --exit-code

container-build:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v2.3.4
- name: Extract version of Go to use
run: echo "GOVERSION=$(cat Dockerfile|grep golang | awk ' { print $2 } ' | sed -r 's/^.*://g'| uniq)" >> $GITHUB_ENV
- uses: actions/setup-go@v2
with:
go-version: ${{ env.GOVERSION }}
- uses: imjasonh/setup-ko@v0.4
with:
version: v0.8.3
- name: container
run: |
KO_DOCKER_REPO=ko.local make ko 2>&1 | tee output.txt
docker run --rm $(tail -1 output.txt) version

e2e:
runs-on: ubuntu-20.04
needs: build
Expand Down