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

Adding arm support #44

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
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
27 changes: 23 additions & 4 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,18 +20,37 @@ before_script:
- docker info
#- docker login -u $CI_REGISTRY_USER -p $CI_REGISTRY_PASSWORD $CI_REGISTRY

buildx:
image: docker:19.03-git
stage: buildx
variables:
GIT_STRATEGY: none
artifacts:
paths:
- buildx
expire_in: 1 hour
services:
- docker:19.03-dind
script:
- export DOCKER_BUILDKIT=1
- git clone git://github.com/docker/buildx ./docker-buildx
- docker build --platform=local -o . ./docker-buildx

docker_build_repo1:
stage: build
image: docker:latest
services:
- docker:dind
- name: docker:19.03-dind
command: ["--experimental"]
before_script:
- mkdir -p ~/.docker/cli-plugins
- mv buildx ~/.docker/cli-plugins/docker-buildx
- docker run --rm --privileged multiarch/qemu-user-static --reset -p yes
script:
- echo "$CI_PROJECT_PATH"
- docker login -u gitlab-ci-token -p $CI_JOB_TOKEN $CI_REGISTRY
- docker pull $REGPATH/$REPO1:$CI_COMMIT_REF_SLUG || true
- docker build --pull -t $REGPATH/$REPO1:$CI_COMMIT_SHA -t $REGPATH/$REPO1:$CI_COMMIT_REF_SLUG ./$REPO1
- docker push $REGPATH/$REPO1:$CI_COMMIT_SHA
- docker push $REGPATH/$REPO1:$CI_COMMIT_REF_SLUG
- docker buildx build --push -t $REGPATH/$REPO1:$CI_COMMIT_SHA -t $REGPATH/$REPO1:$CI_COMMIT_REF_SLUG --platform linux/amd64,linux/arm/v7 ./$REPO1
only:
refs:
- master
Expand Down
8 changes: 4 additions & 4 deletions rclone-mount/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
FROM alpine:latest
FROM alpine:3.12.0

ARG OVERLAY_VERSION="v1.22.1.0"
ARG OVERLAY_ARCH="amd64"
ARG TARGETARCH

ENV DEBUG="false" \
GOPATH="/go" \
Expand All @@ -18,9 +18,9 @@ RUN apk --no-cache upgrade \
&& apk add --no-cache --update alpine-sdk ca-certificates go git fuse fuse-dev gnupg \
&& echo "Installing S6 Overlay" \
&& curl -o /tmp/s6-overlay.tar.gz -L \
"https://github.com/just-containers/s6-overlay/releases/download/${OVERLAY_VERSION}/s6-overlay-${OVERLAY_ARCH}.tar.gz" \
"https://github.com/just-containers/s6-overlay/releases/download/${OVERLAY_VERSION}/s6-overlay-${TARGETARCH}.tar.gz" \
&& curl -o /tmp/s6-overlay.tar.gz.sig -L \
"https://github.com/just-containers/s6-overlay/releases/download/${OVERLAY_VERSION}/s6-overlay-${OVERLAY_ARCH}.tar.gz.sig" \
"https://github.com/just-containers/s6-overlay/releases/download/${OVERLAY_VERSION}/s6-overlay-${TARGETARCH}.tar.gz.sig" \
&& curl https://keybase.io/justcontainers/key.asc | gpg --import \
&& gpg --verify /tmp/s6-overlay.tar.gz.sig /tmp/s6-overlay.tar.gz \
&& tar xfz /tmp/s6-overlay.tar.gz -C / \
Expand Down