mirror of
https://git.netzspielplatz.de/docker-multiarch/writefreely.git
synced 2025-11-08 20:29:27 +00:00
initial commit
This commit is contained in:
commit
d22652ebb2
1 changed files with 24 additions and 0 deletions
24
.gitlab-ci.yml
Normal file
24
.gitlab-ci.yml
Normal file
|
|
@ -0,0 +1,24 @@
|
||||||
|
vimage: egon0/docker-with-buildx-and-git
|
||||||
|
|
||||||
|
variables:
|
||||||
|
DOCKER_HOST: tcp://docker:2375/
|
||||||
|
DOCKER_DRIVER: overlay2
|
||||||
|
DOCKER_TLS_CERTDIR: ""
|
||||||
|
|
||||||
|
services:
|
||||||
|
- docker:dind
|
||||||
|
|
||||||
|
build:
|
||||||
|
stage: build
|
||||||
|
variables:
|
||||||
|
IMAGE_TAG: $CI_REGISTRY_IMAGE:$CI_COMMIT_REF_SLUG
|
||||||
|
D_IMAGE_TAG: egon0/writefreely-multiarch:$CI_COMMIT_REF_SLUG
|
||||||
|
D_LATEST_TAG: egon0/writefreely-multiarch:latest
|
||||||
|
script:
|
||||||
|
- apk add --no-cache jq wget
|
||||||
|
- VERSION=$(wget --quiet "https://api.github.com/repos/writefreely/writefreely/releases/latest" -O - | jq -r '.tag_name') && wget https://github.com/writefreely/writefreely/archive/${VERSION}.tar.gz -O /tmp/writefreely.tar.gz
|
||||||
|
- tar xf /tmp/writefreely.tar.gz --strip-components=1
|
||||||
|
- docker login -u $CI_REGISTRY_USER -p $CI_REGISTRY_PASSWORD $CI_REGISTRY
|
||||||
|
- docker login -u $DOCKER_LOGIN -p $DOCKER_PASSWORD
|
||||||
|
- docker buildx create --use --name A$CI_COMMIT_SHORT_SHA
|
||||||
|
- docker buildx build --platform $BUILD_PLATFORMS --push -t $IMAGE_TAG -t $CI_REGISTRY_IMAGE:latest -t $D_IMAGE_TAG -t $D_LATEST_TAG .
|
||||||
Loading…
Add table
Add a link
Reference in a new issue