mezzotre/.drone.yml

52 lines
1.1 KiB
YAML

kind: pipeline
type: docker
name: default
steps:
- name: Static checks
image: eclipse-temurin:17-jdk
commands:
- apt-get update -qq && apt-get install python3 pip && pip install pre-commit
- pre-commit run --all-files
- name: UT & IT Tests
image: quay.io/testcontainers/dind-drone-plugin
environment:
CI_WORKSPACE: "/drone/src"
settings:
cmd: ./mvnw -B test
build_image: eclipse-temurin:17-jdk
prefetch_images:
- "postgres:13-alpine"
volumes:
- name: dockersock
path: /var/run
- name: Packaging
image: eclipse-temurin:17-jdk
commands:
- ./mvnw package -B -DskipTests=true
depends_on:
- UT & IT Tests
- Static checks
- name: Docker image
image: thegeeklab/drone-docker-buildx:23
privileged: true
settings:
pull_image: true
dry_run: true
depends_on:
- UT & IT Tests
- Static checks
# Specify docker:dind as a service
services:
- name: docker
image: docker:dind
privileged: true
volumes:
- name: dockersock
path: /var/run
volumes:
- name: dockersock
temp: {}