Skip to content

Commit

Permalink
feat: arm64 support in docker images
Browse files Browse the repository at this point in the history
Resolves # 143

Signed-off-by: Ievgenii Shepeliuk <eshepelyuk@gmail.com>
  • Loading branch information
eshepelyuk committed May 10, 2022
1 parent ef5fac5 commit 87cd4d4
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 31 deletions.
2 changes: 2 additions & 0 deletions .github/workflows/build.yaml
Expand Up @@ -13,6 +13,8 @@ on:
pull_request:
branches:
- "master"
- "feat/*"
- "fix/*"

jobs:
build_job:
Expand Down
24 changes: 0 additions & 24 deletions Dockerfile

This file was deleted.

6 changes: 3 additions & 3 deletions justfile
Expand Up @@ -11,7 +11,7 @@ defaul:
build-release:
#!/usr/bin/env bash
set -euxo pipefail
skaffold build -b kube-mgmt -t {{VERSION}} --file-output=skaffold.json
skaffold build -b kube-mgmt -t {{VERSION}} --file-output=tags.json
helm package charts/opa --version {{VERSION}} --app-version {{VERSION}}

LATEST="$(jq -r .builds[0].imageName skaffold.json):latest"
Expand All @@ -36,7 +36,7 @@ k3d: && _skaffold-ctx
k3d cluster create --config ./test/e2e/k3d.yaml

build:
skaffold build --file-output=tags.json
skaffold build --file-output=tags.json --platform=linux/amd64

# install into local k8s
up: _skaffold-ctx down
Expand All @@ -59,5 +59,5 @@ test-e2e-all: build
#!/usr/bin/env bash
set -euxo pipefail
for E in $(find test/e2e/ -mindepth 1 -maxdepth 1 -type d -printf '%f\n'); do
just E2E_TEST=${E} test-e2e
just E2E_TEST=${E} test-e2e
done
13 changes: 9 additions & 4 deletions skaffold.yaml
Expand Up @@ -5,11 +5,16 @@ metadata:
build:
artifacts:
- image: openpolicyagent/kube-mgmt
ko:
fromImage: alpine:3.12.3
main: ./cmd/kube-mgmt/.../
ldflags:
- "-X github.com/open-policy-agent/kube-mgmt/pkg/version.Version={{.VERSION}}"
- "-X github.com/open-policy-agent/kube-mgmt/pkg/version.Git={{.COMMIT}}"
platforms:
- "linux/amd64"
- "linux/arm64"
context: .
docker:
buildArgs:
VERSION: "{{.VERSION}}"
COMMIT: "{{.COMMIT}}"
local:
push: true
useBuildkit: true
Expand Down

0 comments on commit 87cd4d4

Please sign in to comment.