makefile for arm

pull/486/head 0.16.0
Karolis Rusenas 2020-03-02 23:44:15 +00:00
parent a0a95f183a
commit 1156d42eee
2 changed files with 18 additions and 5 deletions

View File

@ -1,4 +1,16 @@
FROM arm32v6/alpine:3.8
FROM node:lts-alpine as ui
WORKDIR /app
COPY ui /app
RUN yarn
RUN yarn run lint --no-fix
RUN yarn run build
FROM arm32v7/debian:buster
ADD ca-certificates.crt /etc/ssl/certs/
COPY cmd/keel/release/keel-linux-arm /bin/keel
COPY --from=ui /app/dist /www
VOLUME /data
ENV XDG_DATA_HOME /data
EXPOSE 9300
ENTRYPOINT ["/bin/keel"]

View File

@ -29,8 +29,9 @@ build-binaries:
-ldflags "$(LDFLAGS)" -osarch="linux/arm"
build-arm:
cd cmd/keel && env GOARCH=arm GOOS=linux go build -ldflags="$(ARMFLAGS)" -o release/keel-linux-arm
cd cmd/keel && env GOARCH=arm64 GOOS=linux go build -ldflags="$(ARMFLAGS)" -o release/keel-linux-aarc64
cd cmd/keel && env CC=arm-linux-gnueabihf-gcc CGO_ENABLED=1 GOARCH=arm GOOS=linux go build -ldflags="$(ARMFLAGS)" -o release/keel-linux-arm
# disabling for now 64bit builds
# cd cmd/keel && env GOARCH=arm64 GOOS=linux go build -ldflags="$(ARMFLAGS)" -o release/keel-linux-aarc64
armhf-latest:
docker build -t keelhq/keel-arm:latest -f Dockerfile.armhf .
@ -42,7 +43,7 @@ aarch64-latest:
armhf:
docker build -t keelhq/keel-arm:$(VERSION) -f Dockerfile.armhf .
docker push keelhq/keel-arm:$(VERSION)
# docker push keelhq/keel-arm:$(VERSION)
aarch64:
docker build -t keelhq/keel-aarch64:$(VERSION) -f Dockerfile.aarch64 .
@ -80,7 +81,7 @@ e2e: install
cd tests && go test
run: install
keel --no-incluster --ui-dir ../../rusenask/keel-ui/dist
keel --no-incluster --ui-dir ui/dist
lint-ui:
cd ui && yarn