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.
79 lines
2.0 KiB
79 lines
2.0 KiB
kind: pipeline
|
|
type: docker
|
|
name: CI
|
|
|
|
trigger:
|
|
event:
|
|
- push
|
|
|
|
steps:
|
|
- name: compilation
|
|
image: maven:3-openjdk-11
|
|
commands:
|
|
- cd Sources
|
|
- mvn clean package
|
|
|
|
|
|
---
|
|
|
|
kind: pipeline
|
|
type: docker
|
|
name: CD
|
|
|
|
trigger:
|
|
event:
|
|
- push
|
|
steps:
|
|
|
|
- name: hadolint
|
|
image: hadolint/hadolint:latest-alpine
|
|
commands:
|
|
- hadolint Sources/Dockerfile
|
|
|
|
- name: deploy-container-postgres
|
|
image: hub.codefirst.iut.uca.fr/thomas.bellembois/codefirst-dockerproxy-clientdrone:latest
|
|
environment:
|
|
IMAGENAME: postgres:latest
|
|
CONTAINERNAME: postgresapi
|
|
COMMAND: create
|
|
OVERWRITE: false
|
|
PRIVATE: false
|
|
ADMINS: lucasevard,emrekartal,arthurvalin,lucasdelanier
|
|
CODEFIRST_CLIENTDRONE_ENV_POSTGRES_ROOT_PASSWORD:
|
|
from_secret: db_root_password
|
|
CODEFIRST_CLIENTDRONE_ENV_POSTGRES_DB:
|
|
from_secret: db_database
|
|
CODEFIRST_CLIENTDRONE_ENV_POSTGRES_USER:
|
|
from_secret: db_user
|
|
CODEFIRST_CLIENTDRONE_ENV_POSTGRES_PASSWORD:
|
|
from_secret: db_password
|
|
|
|
- name: docker-image
|
|
image: plugins/docker
|
|
settings:
|
|
dockerfile: Sources/Dockerfile
|
|
context: Sources
|
|
registry: hub.codefirst.iut.uca.fr
|
|
repo: hub.codefirst.iut.uca.fr/lucas.evard/api
|
|
username:
|
|
from_secret: SECRET_REGISTRY_USERNAME
|
|
password:
|
|
from_secret: SECRET_REGISTRY_PASSWORD
|
|
|
|
- name: deploy-container
|
|
image: hub.codefirst.iut.uca.fr/thomas.bellembois/codefirst-dockerproxy-clientdrone:latest
|
|
environment:
|
|
IMAGENAME: hub.codefirst.iut.uca.fr/lucas.evard/api:latest
|
|
CONTAINERNAME: api
|
|
COMMAND: create
|
|
OVERWRITE: true
|
|
CODEFIRST_CLIENTDRONE_ENV_POSTGRES_DB:
|
|
from_secret: db_database
|
|
CODEFIRST_CLIENTDRONE_ENV_POSTGRES_USER:
|
|
from_secret: db_user
|
|
CODEFIRST_CLIENTDRONE_ENV_POSTGRES_PASSWORD:
|
|
from_secret: db_password
|
|
ADMINS: lucasevard,emrekartal,arthurvalin,lucasdelanier
|
|
depends_on: [docker-image]
|
|
|