Added .woodpecker.yaml
This commit is contained in:
parent
cf0ffc9126
commit
36cfba920e
48
.woodpecker.yaml
Normal file
48
.woodpecker.yaml
Normal file
@ -0,0 +1,48 @@
|
|||||||
|
pipeline:
|
||||||
|
generate_docker_tag:
|
||||||
|
image: golang
|
||||||
|
commands:
|
||||||
|
- echo -n "${CI_COMMIT_BRANCH//\//-}-${CI_COMMIT_SHA:0:8}, latest" > .tags
|
||||||
|
when:
|
||||||
|
path: [ "frontend/**", "backend/**" ]
|
||||||
|
event: push
|
||||||
|
|
||||||
|
|
||||||
|
# -------------------------------------- Backend --------------------------------------
|
||||||
|
build_backend:
|
||||||
|
image: woodpeckerci/plugin-docker-buildx
|
||||||
|
settings:
|
||||||
|
repo:
|
||||||
|
from_secret: repository_backend
|
||||||
|
username:
|
||||||
|
from_secret: registry_username
|
||||||
|
password:
|
||||||
|
from_secret: registry_password
|
||||||
|
registry:
|
||||||
|
from_secret: registry
|
||||||
|
dockerfile: backend/Dockerfile
|
||||||
|
platforms: linux/amd64
|
||||||
|
when:
|
||||||
|
path: "backend/**"
|
||||||
|
event: push
|
||||||
|
|
||||||
|
|
||||||
|
# -------------------------------------- Frontend --------------------------------------
|
||||||
|
build_frontend:
|
||||||
|
image: woodpeckerci/plugin-docker-buildx
|
||||||
|
settings:
|
||||||
|
repo:
|
||||||
|
from_secret: repository_frontend
|
||||||
|
username:
|
||||||
|
from_secret: registry_username
|
||||||
|
password:
|
||||||
|
from_secret: registry_password
|
||||||
|
registry:
|
||||||
|
from_secret: registry
|
||||||
|
dockerfile: frontend/Dockerfile
|
||||||
|
platforms: linux/amd64
|
||||||
|
when:
|
||||||
|
path: "frontend/**"
|
||||||
|
event: push
|
||||||
|
|
||||||
|
branches: main
|
Loading…
Reference in New Issue
Block a user