SlideShare a Scribd company logo
Drone CI/CD
Container-Native
Continuous Delivery Platform
https://github.com/drone/drone
2019/04/20
Bo-yi Wu (appleboy)
Software Engineer in Mediatek
https://blog.wu-boy.com
https://github.com/appleboy
appleboy appleboy46
Drone cloud
free for the open source community
https://cloud.drone.io/
---
kind: pipeline
name: default
steps:
- name: backend
image: golang
commands:
- go build
- go test
- name: frontend
image: node
commands:
- npm install
- npm test
https://github.com/drone/drone-ui
Drone 1.0 Features
Support Platform
Multi-Machine
Multi-Architecture
Multi-Cloud
---
kind: pipeline
platform:
arch: arm
os: linux
steps:
- name: build
image: golang
commands:
- go build
- go test
Linux amd64, Linux arm, Linux arm64 and Windows server
---
kind: pipeline
name: backend
platform:
arch: arm
os: linux
steps:
- name: build
image: golang
commands:
- go build
- go test
---
kind: pipeline
name: frontend
platform:
arch: amd64
os: linux
steps:
- name: build
image: node
commands:
- npm install
- npm test
depends_on:
- backend
---
kind: pipeline
name: default
steps:
- name: backend
image: golang
commands:
- go build
- go test
- name: frontend
image: golang
commands:
- npm install
- npm test
- name: build
image: plugins/slack
settings:
channel: general
depends_on:
- backend
- frontend
Faster Pipelines with Parallelization
local pipeline = import 'pipeline.libsonnet';
local name = 'drone-ssh';
[
pipeline.test,
pipeline.build(name, 'linux', 'amd64'),
pipeline.build(name, 'linux', 'arm64'),
pipeline.build(name, 'linux', 'arm'),
pipeline.release,
pipeline.notifications(depends_on=[
'linux-amd64',
'linux-arm64',
'linux-arm',
'release-binary',
]),
]
Complex Configurations Simplified
Secret Management
---
kind: secret
name: slack_webhook
get:
path: secret/data/slack
name: webhook
---
kind: pipeline
name: default
steps:
- name: build
image: golang
commands:
- go build
- go test
- name: notify
image: plugins/slack
settings:
channel: general
webhook:
from_secret: slack_webhook
per-organization
secrets
http://bit.ly/drone-org-secrets
Cron Scheduling
@hourly, @dailys, @weekly and @monthly
# example when configuration
when:
cron: [ nightly ]
# example trigger configuration
trigger:
cron: [ nightly ]
Gitlab Pipelines
image: ruby:2.2
services:
- postgres:9.3
before_script:
- bundle install
test:
script:
- bundle exec rake spec
---
kind: pipeline
name: test
platform:
os: linux
arch: amd64
steps:
- name: test
image: ruby:2.2
commands:
- bundle install
- bundle exec rake spec
services:
- name: postgres-9-3
image: postgres:9.3
...$ drone convert .gitlab-ci.yml
automatic runtime conversion
Gitlab cache
cache:
untracked: true
key: "$CI_BUILD_REF_NAME"
paths:
- node_modules/
stages:
- setup
- test
setup:
stage: setup
script:
- npm install
test:
stage: test
script:
- npm test
---
kind: pipeline
name: setup
platform:
os: linux
arch: amd64
steps:
- name: setup
commands:
- npm install
- name: test
commands:
- npm test
depends_on:
- setup
...
Bitbucket Pipelines
pipelines:
default:
- step:
name: Build and test
image: node:8.5.0
script:
- npm install
- npm test
- npm build
definitions:
services:
postgres:
image: postgres:9.6.4
---
kind: pipeline
name: default
platform:
os: linux
arch: amd64
steps:
- name: Build and test
image: node:8.5.0
commands:
- npm install
- npm test
- npm build
services:
- name: postgres
image: postgres:9.6.4
...
$ drone convert bitbucket-pipelines.yml
automatic runtime conversion
Bitbucket cache
pipelines:
default:
- step:
caches:
- node
script:
- npm install
- npm test
kind: pipeline
name: default
steps:
- name: restore
image: plugins/s3-cache
settings:
restore: true
mount:
- node_modules
- name: build
image: node
commands:
- npm install
- npm test
- name: rebuild
image: plugins/s3-cache
settings:
rebuild: true
mount:
- node_modules
Autoscale in Drone
https://autoscale.drone.io/
Agent
Server
Agent
Agent Agent
autoscaler
https://github.com/drone/autoscaler
Task - Agent
drone_server=server:9000
Task - Server
port: 80/9000
ECS - Fargate ECS - Service
Target Group
Port: 80
Route 53 Service Discovery
ALB / SSL
Cloud Watch
https://github.com/appleboy/drone-terraform-in-aws
Drone CI
Infrastructure
Drone CI Infrastructure
Agent
Server
Step 1
git clone
Step 2
make build
Step 3
deploy app
work space
extra service
Agent
Drone Server
• Support SSL
• Custom SSL
• Let’s Encrypt
• Database
• SQLite
• MySQL
• Postgres
• S3 Storage: Store Large Text Files (build logs)
• Log to stderr in joss-format by default
Drone + Prometheus
global:
scrape_interval: 60s
scrape_configs:
- job_name: 'drone'
bearer_token: your_token
static_configs:
- targets: ['domain.com']
Drone Agent
• Linux amd64
• Linux arm
• Linux arm64
• Windows 1803
• Windows 1809
route builds to
specific agents
CPU, Memory, GPUS
kind: pipeline
name: default
steps:
- name: build
image: golang
commands:
- go build
- go test
node:
instance: highmem
Drone Plugin
Any language you want
#!/bin/sh
curl -X POST 
-H 'Content-type: application/json' 
-d '{"text":"hello"}' 
https://hooks.slack.com/services/...
#!/bin/sh
curl -X POST 
-H 'Content-type: application/json' 
-d '{"text":"${PLUGIN_TEXT}"}' 
${PLUGIN_WEBHOOK}
kind: pipeline
name: default
steps:
- name: webhook
image: janecitizen/slack
settings:
webhook: https://hooks.slack.com/...
text: hello
http://plugins.drone.io
http://bit.ly/drone-2019

More Related Content

PDF
Drone CI/CD Platform
PPTX
drone continuous Integration
PDF
Drone CI/CD 自動化測試及部署
PDF
Golang Project Layout and Practice
PDF
Rest, sockets em golang
PDF
GraphQL IN Golang
PDF
Docker 導入:障礙與對策
PDF
Docker 初探,實驗室中的運貨鯨
Drone CI/CD Platform
drone continuous Integration
Drone CI/CD 自動化測試及部署
Golang Project Layout and Practice
Rest, sockets em golang
GraphQL IN Golang
Docker 導入:障礙與對策
Docker 初探,實驗室中的運貨鯨

What's hot (20)

PDF
Gitlab - Creating C++ applications with Gitlab CI
PDF
Golang workshop
PDF
Conan a C/C++ Package Manager
PDF
How to integrate front end tool via gruntjs
PDF
Conan.io - The C/C++ package manager for Developers
PDF
TDC2018SP | Trilha Containers - CI/CD com Docker e Drone
PDF
Build microservice with gRPC in golang
PDF
Gearman work queue in php
PDF
JCConf 2015 workshop 動手玩 Java 專案建置工具
PDF
Using docker to develop NAS applications
PDF
Workshop - Golang language
PDF
GDGSCL - Docker a jeho provoz v Heroku a AWS
PDF
手把手帶你學Docker 03042017
PDF
DCSF19 Tips and Tricks of the Docker Captains
PDF
DCSF 19 Deploying Rootless buildkit on Kubernetes
PDF
Docker introduction in Hardware Company
PDF
sed.pdf
PDF
Puppeteerのお話
PPTX
JFrog container registry - DevOps extravaganza
PDF
DCEU 18: Dockerfile Best Practices
Gitlab - Creating C++ applications with Gitlab CI
Golang workshop
Conan a C/C++ Package Manager
How to integrate front end tool via gruntjs
Conan.io - The C/C++ package manager for Developers
TDC2018SP | Trilha Containers - CI/CD com Docker e Drone
Build microservice with gRPC in golang
Gearman work queue in php
JCConf 2015 workshop 動手玩 Java 專案建置工具
Using docker to develop NAS applications
Workshop - Golang language
GDGSCL - Docker a jeho provoz v Heroku a AWS
手把手帶你學Docker 03042017
DCSF19 Tips and Tricks of the Docker Captains
DCSF 19 Deploying Rootless buildkit on Kubernetes
Docker introduction in Hardware Company
sed.pdf
Puppeteerのお話
JFrog container registry - DevOps extravaganza
DCEU 18: Dockerfile Best Practices
Ad

Similar to Drone 1.0 Feature (20)

PDF
Drone CI - Container native continuous Integration / Delivery
PDF
HOW TO DRONE.IO IN CI/CD WORLD
PDF
Bring Continuous Integration to Your Laptop With the Drone CI Docker Extensio...
PDF
Drone Continuous Integration
PDF
Bring Continuous Integration to Your Laptop With the Drone CI Docker Extensio...
PDF
Drone presentation
PDF
KubeCI - Cloud Native Continuous Delivery for Kubernetes
PDF
Drone CI
PDF
Automating the CI / CD pipeline of your containerized applications
PPTX
Infra@LINE_Chris
PDF
How we scale DroneCi on demand
PPTX
GCP - Continuous Integration and Delivery into Kubernetes with GitHub, Travis...
PPTX
Consuming Cinder from Docker
PPTX
Building a Scalable CI Platform using Docker, Drone and Rancher
PDF
Haibu: dev deployment is fast and easy again
PDF
Drone your Ansible
PDF
Continuous Delivery of Containers with Drone & Kontena
PDF
Google Cloud Platform for Python Developer - Beginner Guide.pdf
PPTX
On Docker and its use for LHC at CERN
PDF
Consuming Cinder from Docker
Drone CI - Container native continuous Integration / Delivery
HOW TO DRONE.IO IN CI/CD WORLD
Bring Continuous Integration to Your Laptop With the Drone CI Docker Extensio...
Drone Continuous Integration
Bring Continuous Integration to Your Laptop With the Drone CI Docker Extensio...
Drone presentation
KubeCI - Cloud Native Continuous Delivery for Kubernetes
Drone CI
Automating the CI / CD pipeline of your containerized applications
Infra@LINE_Chris
How we scale DroneCi on demand
GCP - Continuous Integration and Delivery into Kubernetes with GitHub, Travis...
Consuming Cinder from Docker
Building a Scalable CI Platform using Docker, Drone and Rancher
Haibu: dev deployment is fast and easy again
Drone your Ansible
Continuous Delivery of Containers with Drone & Kontena
Google Cloud Platform for Python Developer - Beginner Guide.pdf
On Docker and its use for LHC at CERN
Consuming Cinder from Docker
Ad

More from Bo-Yi Wu (20)

PDF
用 Go 語言打造多台機器 Scale 架構
PDF
Job Queue in Golang
PDF
Introduction to GitHub Actions
PPTX
Go 語言基礎簡介
PPTX
Gorush: A push notification server written in Go
PPTX
用 Drone 打造 輕量級容器持續交付平台
PPTX
用 Go 語言 打造微服務架構
PPTX
Introduction to Gitea with Drone
PDF
運用 Docker 整合 Laravel 提升團隊開發效率
PDF
用 Go 語言實戰 Push Notification 服務
PPTX
用 Go 語言打造 DevOps Bot
PPTX
A painless self-hosted Git service: Gitea
PPTX
Write microservice in golang
PPTX
用 Docker 改善團隊合作模式
PPTX
Git flow 與團隊合作
PPTX
PHP & JavaScript & CSS Coding style
PPTX
Docker 基礎介紹與實戰
PPTX
Why to choose laravel framework
PPTX
How to choose web framework
PPTX
Git Flow and JavaScript Coding Style
用 Go 語言打造多台機器 Scale 架構
Job Queue in Golang
Introduction to GitHub Actions
Go 語言基礎簡介
Gorush: A push notification server written in Go
用 Drone 打造 輕量級容器持續交付平台
用 Go 語言 打造微服務架構
Introduction to Gitea with Drone
運用 Docker 整合 Laravel 提升團隊開發效率
用 Go 語言實戰 Push Notification 服務
用 Go 語言打造 DevOps Bot
A painless self-hosted Git service: Gitea
Write microservice in golang
用 Docker 改善團隊合作模式
Git flow 與團隊合作
PHP & JavaScript & CSS Coding style
Docker 基礎介紹與實戰
Why to choose laravel framework
How to choose web framework
Git Flow and JavaScript Coding Style

Recently uploaded (20)

PDF
Unlocking AI with Model Context Protocol (MCP)
PDF
Encapsulation theory and applications.pdf
PDF
Diabetes mellitus diagnosis method based random forest with bat algorithm
PDF
Network Security Unit 5.pdf for BCA BBA.
PPT
Teaching material agriculture food technology
PDF
Electronic commerce courselecture one. Pdf
PDF
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
PDF
NewMind AI Weekly Chronicles - August'25 Week I
PPTX
Digital-Transformation-Roadmap-for-Companies.pptx
PDF
Chapter 3 Spatial Domain Image Processing.pdf
PDF
How UI/UX Design Impacts User Retention in Mobile Apps.pdf
PDF
cuic standard and advanced reporting.pdf
PPTX
KOM of Painting work and Equipment Insulation REV00 update 25-dec.pptx
PDF
Building Integrated photovoltaic BIPV_UPV.pdf
PPTX
Understanding_Digital_Forensics_Presentation.pptx
PPTX
Big Data Technologies - Introduction.pptx
PDF
Mobile App Security Testing_ A Comprehensive Guide.pdf
PPT
“AI and Expert System Decision Support & Business Intelligence Systems”
PDF
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
PPTX
20250228 LYD VKU AI Blended-Learning.pptx
Unlocking AI with Model Context Protocol (MCP)
Encapsulation theory and applications.pdf
Diabetes mellitus diagnosis method based random forest with bat algorithm
Network Security Unit 5.pdf for BCA BBA.
Teaching material agriculture food technology
Electronic commerce courselecture one. Pdf
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
NewMind AI Weekly Chronicles - August'25 Week I
Digital-Transformation-Roadmap-for-Companies.pptx
Chapter 3 Spatial Domain Image Processing.pdf
How UI/UX Design Impacts User Retention in Mobile Apps.pdf
cuic standard and advanced reporting.pdf
KOM of Painting work and Equipment Insulation REV00 update 25-dec.pptx
Building Integrated photovoltaic BIPV_UPV.pdf
Understanding_Digital_Forensics_Presentation.pptx
Big Data Technologies - Introduction.pptx
Mobile App Security Testing_ A Comprehensive Guide.pdf
“AI and Expert System Decision Support & Business Intelligence Systems”
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
20250228 LYD VKU AI Blended-Learning.pptx

Drone 1.0 Feature