Files
fullstack-portfolio/.woodpecker.yml
Moh Dzulfikri Maulana 0f2746fffd
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
refactor: update Woodpecker CI Telegram notification configuration for improved security and message content.
2026-03-10 10:10:56 +07:00

61 lines
1.5 KiB
YAML

steps:
# 1. Build & Push Image
build-and-push:
image: plugins/docker
settings:
registry: git.exavolt.web.id
repo: git.exavolt.web.id/fikri/fullstack-portfolio
dockerfile: Dockerfile
use_cache: true
username:
from_secret: gitea_user
password:
from_secret: gitea_token
when:
branch: master
event: push
# 2. Deploy via SSH
deploy:
image: appleboy/drone-ssh
settings:
host: 103.197.190.44
username: exavolt
port: 22
key:
from_secret: ssh_key
envs: [ GITEA_USER, GITEA_TOKEN ]
gitea_user:
from_secret: gitea_user
gitea_token:
from_secret: gitea_token
script:
- cd ~/projects/fikri-fullstack-portfolio
- echo $GITEA_TOKEN | docker login git.exavolt.web.id -u $GITEA_USER --password-stdin
- docker compose pull
- docker compose up -d --remove-orphans
- docker image prune -f
when:
branch: master
event: push
# 3.Telegram Notification
notify-telegram:
image: appleboy/drone-telegram
settings:
token:
from_secret: telegram_token
to:
from_secret: telegram_chat_id
thread_id: 8
format: html
message: >
<b>🚀 Deployment {{ build.status }}!</b>
<b>Project:</b> {{ repo.name }}
<b>Commit:</b> {{ commit.message }}
<b>Author:</b> {{ commit.author }}
<b>Status:</b> {{ build.status }}
when:
- event: [push]
branch: master
status: [ success, failure ]