You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
74 lines
2.1 KiB
74 lines
2.1 KiB
kind: pipeline
|
|
type: docker
|
|
name: API_Formulaire
|
|
|
|
|
|
trigger:
|
|
event:
|
|
- push
|
|
|
|
|
|
steps:
|
|
|
|
#PHP compilation with php -l
|
|
- name: PHP_Compilation
|
|
image: php:8.1
|
|
commands:
|
|
- find -name "*.php" -exec php -l "{}" \;
|
|
|
|
# docker image build
|
|
- name: set_api_form
|
|
image: plugins/docker
|
|
settings:
|
|
dockerfile: ./Source/API/Dockerfile
|
|
context: Source/API
|
|
registry: hub.codefirst.iut.uca.fr
|
|
repo: hub.codefirst.iut.uca.fr/dorian.hodin/sae4.01_api_form
|
|
username:
|
|
from_secret: SECRET_USERNAME
|
|
password:
|
|
from_secret: SECRET_PASSWD
|
|
|
|
# conteneur deployment
|
|
- name: deploy_api_form
|
|
image: hub.codefirst.iut.uca.fr/thomas.bellembois/codefirst-dockerproxy-clientdrone:latest
|
|
environment:
|
|
IMAGENAME: hub.codefirst.iut.uca.fr/dorian.hodin/sae4.01_api_form:latest
|
|
CONTAINERNAME: deploy_api_form
|
|
COMMAND: create
|
|
OVERWRITE: true
|
|
CODEFIRST_CLIENTDRONE_ENV_HOST:
|
|
from_secret: db_host
|
|
CODEFIRST_CLIENTDRONE_ENV_DATABASE:
|
|
from_secret: db_database
|
|
CODEFIRST_CLIENTDRONE_ENV_USER:
|
|
from_secret: db_user
|
|
CODEFIRST_CLIENTDRONE_ENV_PASSWORD:
|
|
from_secret: db_password
|
|
CODEFIRST_CLIENTDRONE_ENV_ROOT_PASSWORD:
|
|
from_secret: db_root_password
|
|
ADMINS: dorianhodin,alexislamande,baptistebaverel,johanlachenal
|
|
depends_on: [ set_api_form ]
|
|
|
|
|
|
# database container deployment
|
|
- name: db_form
|
|
image: hub.codefirst.iut.uca.fr/thomas.bellembois/codefirst-dockerproxy-clientdrone:latest
|
|
environment:
|
|
IMAGENAME: mariadb:10.5
|
|
CONTAINERNAME: db_form
|
|
PRIVATE : true
|
|
COMMAND: create
|
|
CODEFIRST_CLIENTDRONE_ENV_MARIADB_ROOT_PASSWORD:
|
|
from_secret: db_root_password
|
|
CODEFIRST_CLIENTDRONE_ENV_MARIADB_DATABASE:
|
|
from_secret: db_database
|
|
CODEFIRST_CLIENTDRONE_ENV_MARIADB_USER:
|
|
from_secret: db_user
|
|
CODEFIRST_CLIENTDRONE_ENV_MARIADB_PASSWORD:
|
|
from_secret: db_password
|
|
ADMINS: dorianhodin,alexislamande,baptistebaverel,johanlachenal
|
|
depends_on: [ deploy_api_form ]
|
|
|
|
|