maze-server/.drone.yml
Manuel Friedli ebf127bd93
All checks were successful
continuous-integration/drone/push Build is passing
try event instead of trigger
2023-04-01 00:42:59 +02:00

69 lines
1.4 KiB
YAML

kind: pipeline
type: docker
name: default
steps:
- name: build
image: maven:3.8-openjdk-18-slim
commands:
- mvn clean install -DskipTests=true -Dmaven.javadoc.skip=true -B -V
when:
branch:
include:
- master
- feature/*
- name: test
image: maven:3.8-openjdk-18-slim
commands:
- mvn test -B
when:
branch:
include:
- master
- feature/*
- name: deploy
image: maven:3.8-openjdk-18-slim
environment:
REPO_TOKEN:
from_secret: repo-token
commands:
- mvn -s maven-settings.xml deploy -DskipTests=true
when:
branch:
- master
event:
exclude:
- pull_request
- name: build_docker_image
image: plugins/docker
settings:
registry: gittr.ch
username: manuel
password:
from_secret: docker-token
repo: gittr.ch/java/labyrinth
tags:
- latest
dockerfile: docker/Dockerfile
when:
branch:
- master
event:
exclude:
- pull_request
- tag
- name: build_docker_image_release
image: plugins/docker
settings:
registry: gittr.ch
username: manuel
password:
from_secret: docker-token
repo: gittr.ch/java/labyrinth
tags:
- latest
- ${DRONE_TAG}
dockerfile: docker/Dockerfile
when:
event:
include:
- tag