Commit b6a7cb76 authored by Manuel Vazquez Acosta's avatar Manuel Vazquez Acosta

Initial commit.

parents
Pipeline #14597 failed with stages
in 28 seconds
---
stages:
- build
- publish
.build_image: &build_image
image: docker
stage: build
script:
- apk add --update libintl
- apk add --virtual build_deps gettext
- cp /usr/bin/envsubst /usr/local/bin/envsubst
- envsubst < Dockerfile.$base.in > Dockerfile.$rust_version-$base
- |
if [ -f Dockerfile.$rust_version.in ]; then
envsubst < Dockerfile.$rust_version.in >> Dockerfile.$rust_version-$base
fi
if [ -f Dockerfile.$rust_version-$base.in ]; then
envsubst < Dockerfile.$rust_version-$base.in >> Dockerfile.$rust_version-$base
fi
- docker build -f Dockerfile.$rust_version-$base -t "$CI_REGISTRY_IMAGE:$rust_version-$CI_COMMIT_SHA-$base" .
- docker login -u "$CI_REGISTRY_USER" -p "$CI_REGISTRY_PASSWORD" "$CI_REGISTRY"
- docker push "$CI_REGISTRY_IMAGE:$rust_version-$CI_COMMIT_SHA-$base"
.tag_image: &tag_image
image: docker
stage: publish
script:
- docker login -u "$CI_REGISTRY_USER" -p "$CI_REGISTRY_PASSWORD" "$CI_REGISTRY"
- docker pull "$CI_REGISTRY_IMAGE:$rust_version-$CI_COMMIT_SHA-$base"
- docker tag "$CI_REGISTRY_IMAGE:$rust_version-$CI_COMMIT_SHA-$base" "$CI_REGISTRY_IMAGE:$rust_version-$base"
- docker push "$CI_REGISTRY_IMAGE:$rust_version-$base"
build Rust 1.41 image with Alpine:
<<: *build_image
variables:
rust_version: "1.41"
base: alpine
only:
changes:
- Dockerfile.alpine.in
- Dockerfile.3.5.in
- .gitlab-ci.yml
build Rust 1.41 image with Debian:
<<: *build_image
variables:
rust_version: "1.41"
base: debian
only:
changes:
- Dockerfile.debian.in
- Dockerfile.1.41.in
- .gitlab-ci.yml
tag Rust 1.41-alpine image:
<<: *tag_image
variables:
rust_version: "1.41"
base: alpine
only:
changes:
- Dockerfile.alpine.in
- Dockerfile.1.41.in
- .gitlab-ci.yml
tag Rust 1.41-debian image:
<<: *tag_image
variables:
rust_version: "1.41"
base: debian
only:
changes:
- Dockerfile.debian.in
- Dockerfile.1.41.in
- .gitlab-ci.yml
FROM rust:${python_version}-alpine
LABEL maintainer="Merchise Autrement <info@merchise.org>"
RUN rustup component add clippy && rustup component add rustfmt
FROM rust:${python_version}
LABEL maintainer="Merchise Autrement <info@merchise.org>"
RUN rustup component add clippy && rustup component add rustfmt
Images for Rust with rustfmt and clippy
=======================================
Each tag in based in its equivalent official ``rust`` image.
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment