resilient/.woodpecker.yml
root 22fe2d8114
Some checks failed
ci/woodpecker/manual/woodpecker Pipeline failed
Update .woodpecker.yml
2025-06-08 11:01:01 +01:00

74 lines
2.1 KiB
YAML

steps:
debug-secrets:
image: alpine
environment:
GITHUB_USERNAME2: omguerreiro@gmail.com
# TOKEN PAT: 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
GITHUB_PAT:
from_secret: GITHUB_PAT
commands:
- env
- 'echo "GITHUB_USERNAME2 is set to: ${GITHUB_USERNAME2}"'
- 'echo "GITHUB_PAT is set to: ${GITHUB_PAT}"'
when:
event: [push, pull_request, manual]
docker-login:
image: docker
environment:
# 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
GITHUB_PAT: from_secret:GITHUB_PAT
# omguerreiro@gmail.com
GITHUB_USERNAME: from_secret:GITHUB_USERNAME
commands:
# - echo $GITHUB_PAT | docker login ghcr.io -u $GITHUB_USERNAME --password-stdin
- echo "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" | docker login ghcr.io -u omguerreiro@gmail.com --password-stdin
when:
event: [push, pull_request, manual]
restore-cache:
image: plugins/cache
settings:
restore: true
mount:
- /root/.m2
- frontend/node_modules
path: /tmp/woodpecker-cache
when:
event: [push, pull_request, manual]
backend-build:
image: maven:3.9-eclipse-temurin-17
volumes:
- build:/output
commands:
- echo "Building backend + frontend"
- mvn clean install -Pprod -DskipTests
- cp target/resilient*.jar /output/
when:
event: [push, pull_request, manual]
branch:
include:
- main
- master
- develop
save-cache:
image: plugins/cache
settings:
rebuild: true
mount:
- /root/.m2
- frontend/node_modules
path: /tmp/woodpecker-cache
when:
event: [push, pull_request, manual]
save-artifacts:
image: ghcr.io/woodpecker-ci/plugin-artifacts
settings:
files:
- /output/resilient*.jar
destination: build
when:
event: [push, pull_request, manual]