diff options
-rw-r--r-- | .gitlab-ci.yml | 12 | ||||
-rw-r--r-- | Dockerfile | 15 |
2 files changed, 26 insertions, 1 deletions
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index fdf25e4..e0294a1 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -2,6 +2,7 @@ stages: - Package - Build - Test + - Release Tarball: stage: Package @@ -60,5 +61,14 @@ Community Modules: script: - make modules-test -# TODO: Release an updated Docker container +Docker: + stage: Release + image: docker:stable + services: + - docker:dind + before_script: + - docker login -u $CI_REGISTRY_USER -p $CI_REGISTRY_PASSWORD $CI_REGISTRY + - docker build --build-arg "VERSION=$CI_COMMIT_REF_NAME" -t "$CI_REGISTRY_IMAGE:$CI_COMMIT_REF_NAME" . + - docker push "$CI_REGISTRY_IMAGE:$CI_COMMIT_REF_NAME" + # TODO: Release the tarball to some Raku server diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..09ea8bc --- /dev/null +++ b/Dockerfile @@ -0,0 +1,15 @@ +FROM alpine:latest AS build + +ARG VERSION + +COPY work /tmp + +RUN cd -- /tmp/rakudo-star-$VERSION +RUN apk add --no-cache build-base git perl perl-utils libressl +RUN perl Configure.pl --prefix=/usr/local --backend=moar --gen-moar --make-install + +FROM alpine:latest + +COPY --from=build /usr/local /usr/local + +CMD [ "perl6" ] |