This repository has been archived on 2024-10-10. You can view files and clone it, but cannot push or open issues or pull requests.
roundcube/.drone.yml

87 lines
1.4 KiB
YAML
Raw Normal View History

---
kind: 'pipeline'
name: 'build'
type: 'kubernetes'
steps:
# build and publish
- image: 'docker.io/plugins/docker'
name: 'publish'
pull: 'always'
2023-11-08 18:07:42 +01:00
when:
branch:
2023-11-08 18:12:24 +01:00
- 'main'
2024-02-06 09:17:57 +01:00
event:
- 'push'
2023-11-08 18:07:42 +01:00
settings:
# registery and repos
registry: 'cr.simoncor.net'
repo: 'cr.simoncor.net/siempie/roundcube'
mtu: '1440'
# build stuff
dockerfile: 'Dockerfile.linux.amd64'
daemon_off: 'false'
# authentication
username:
from_secret: 'docker_username'
password:
from_secret: 'docker_password'
# tags
tags:
- 'v1'
- 'latest'
2024-05-24 12:20:23 +02:00
# kubernetes deployment
---
kind: 'pipeline'
name: 'deployment'
type: 'kubernetes'
2023-11-08 18:07:42 +01:00
2024-05-24 12:20:23 +02:00
depends_on:
- 'build'
# disable clone
clone:
disable: true
# deployment step
steps:
# kubernetes deployment
- name: 'kubernetes deployment'
image: 'docker.io/appleboy/drone-ssh:1'
when:
branch:
- 'master'
event:
- 'push'
settings:
# bastion
proxy_host: 'siempie.com'
proxy_port: '22'
proxy_user:
from_secret: 'drone_user'
proxy_key:
from_secret: 'drone_ssh_key'
2024-05-24 12:20:23 +02:00
# k9s
host: 'k9s.siempie.internal'
port: '22'
user:
from_secret: 'drone_user'
key:
from_secret: 'drone_ssh_key'
script:
2024-05-24 12:20:23 +02:00
# kubernetes deployment
- 'kubectl -n roundcube rollout restart statefulsets roundcube-app'