Commit affb4905 authored by Bertrand Gauthier's avatar Bertrand Gauthier
Browse files

Ajout d'un .gitlab-ci.yml pour builder une image par version de PHP

parent 6062bf36
Loading
Loading
Loading
Loading
Loading

.gitlab-ci.yml

0 → 100644
+53 −0
Original line number Diff line number Diff line
before_script:
  - docker info

stages:
  - build

build7.0:
  stage: build
  script:
    - export HTTP_PROXY=http://10.14.128.99:3128
    - export PHP_VERSION=7.0
    - docker build --rm --build-arg PHP_VERSION=${PHP_VERSION} --build-arg HTTP_PROXY=${HTTP_PROXY} -f Dockerfile -t sygal-import-ws-image-php${PHP_VERSION} .
    - docker tag sygal-import-ws-image-php${PHP_VERSION} registre.unicaen.fr:5000/sygal-import-ws-image-php${PHP_VERSION}
    - docker push registre.unicaen.fr:5000/sygal-import-ws-image-php${PHP_VERSION}
    - docker build --rm --build-arg PHP_VERSION=${PHP_VERSION} --build-arg HTTP_PROXY=${HTTP_PROXY} -f Dockerfile -t open-source/docker/sygal-import-ws-image:php${PHP_VERSION} .
    - docker tag open-source/docker/sygal-import-ws-image:php${PHP_VERSION} registre.unicaen.fr:5000/open-source/docker/sygal-import-ws-image:php${PHP_VERSION}
    - docker push registre.unicaen.fr:5000/open-source/docker/sygal-import-ws-image:php${PHP_VERSION}

build7.3:
  stage: build
  script:
    - export HTTP_PROXY=http://10.14.128.99:3128
    - export PHP_VERSION=7.3
    - docker build --rm --build-arg PHP_VERSION=${PHP_VERSION} --build-arg HTTP_PROXY=${HTTP_PROXY} -f Dockerfile -t sygal-import-ws-image-php${PHP_VERSION} .
    - docker tag sygal-import-ws-image-php${PHP_VERSION} registre.unicaen.fr:5000/sygal-import-ws-image-php${PHP_VERSION}
    - docker push registre.unicaen.fr:5000/sygal-import-ws-image-php${PHP_VERSION}
    - docker build --rm --build-arg PHP_VERSION=${PHP_VERSION} --build-arg HTTP_PROXY=${HTTP_PROXY} -f Dockerfile -t open-source/docker/sygal-import-ws-image:php${PHP_VERSION} .
    - docker tag open-source/docker/sygal-import-ws-image:php${PHP_VERSION} registre.unicaen.fr:5000/open-source/docker/sygal-import-ws-image:php${PHP_VERSION}
    - docker push registre.unicaen.fr:5000/open-source/docker/sygal-import-ws-image:php${PHP_VERSION}

build7.4:
  stage: build
  script:
    - export HTTP_PROXY=http://10.14.128.99:3128
    - export PHP_VERSION=7.4
    - docker build --rm --build-arg PHP_VERSION=${PHP_VERSION} --build-arg HTTP_PROXY=${HTTP_PROXY} -f Dockerfile -t sygal-import-ws-image-php${PHP_VERSION} .
    - docker tag sygal-import-ws-image-php${PHP_VERSION} registre.unicaen.fr:5000/sygal-import-ws-image-php${PHP_VERSION}
    - docker push registre.unicaen.fr:5000/sygal-import-ws-image-php${PHP_VERSION}
    - docker build --rm --build-arg PHP_VERSION=${PHP_VERSION} --build-arg HTTP_PROXY=${HTTP_PROXY} -f Dockerfile -t open-source/docker/sygal-import-ws-image:php${PHP_VERSION} .
    - docker tag open-source/docker/sygal-import-ws-image:php${PHP_VERSION} registre.unicaen.fr:5000/open-source/docker/sygal-import-ws-image:php${PHP_VERSION}
    - docker push registre.unicaen.fr:5000/open-source/docker/sygal-import-ws-image:php${PHP_VERSION}

build8.0:
  stage: build
  script:
    - export HTTP_PROXY=http://10.14.128.99:3128
    - export PHP_VERSION=8.0
    - docker build --rm --build-arg PHP_VERSION=${PHP_VERSION} --build-arg HTTP_PROXY=${HTTP_PROXY} -f Dockerfile -t sygal-import-ws-image-php${PHP_VERSION} .
    - docker tag sygal-import-ws-image-php${PHP_VERSION} registre.unicaen.fr:5000/sygal-import-ws-image-php${PHP_VERSION}
    - docker push registre.unicaen.fr:5000/sygal-import-ws-image-php${PHP_VERSION}
    - docker build --rm --build-arg PHP_VERSION=${PHP_VERSION} --build-arg HTTP_PROXY=${HTTP_PROXY} -f Dockerfile -t open-source/docker/sygal-import-ws-image:php${PHP_VERSION} .
    - docker tag open-source/docker/sygal-import-ws-image:php${PHP_VERSION} registre.unicaen.fr:5000/open-source/docker/sygal-import-ws-image:php${PHP_VERSION}
    - docker push registre.unicaen.fr:5000/open-source/docker/sygal-import-ws-image:php${PHP_VERSION}