35 lines
No EOL
935 B
YAML
35 lines
No EOL
935 B
YAML
pipeline:
|
|
build:
|
|
image: docker:dind
|
|
privileged: true
|
|
commands:
|
|
- docker build -t frontend:${CI_COMMIT_SHA:0:8} .
|
|
- docker tag frontend:${CI_COMMIT_SHA:0:8} frontend:latest
|
|
|
|
deploy:
|
|
image: docker:dind
|
|
privileged: true
|
|
commands:
|
|
- docker stop frontend || true
|
|
- docker rm frontend || true
|
|
- docker run -d --name frontend -p 5173:5173 frontend:latest
|
|
|
|
# clone:
|
|
# git:
|
|
# image: woodpeckerci/plugin-git
|
|
# settings:
|
|
# depth: 1
|
|
|
|
# pipeline:
|
|
# build_and_deploy:
|
|
# image: docker:dind
|
|
# privileged: true
|
|
# commands:
|
|
# - sleep 5 # Give Docker daemon time to start
|
|
# - docker build -t frontend:${CI_COMMIT_SHA:0:8} .
|
|
# - docker tag frontend:${CI_COMMIT_SHA:0:8} frontend:latest
|
|
# - docker stop frontend || true
|
|
# - docker rm frontend || true
|
|
# - docker run -d --name frontend -p 5137:5137 frontend:latest
|
|
|
|
branches: master |