1
0
mirror of https://github.com/vimagick/dockerfiles.git synced 2024-12-14 11:23:02 +02:00
dockerfiles/drone/README.md

94 lines
2.0 KiB
Markdown
Raw Normal View History

2016-01-11 17:21:41 +02:00
drone
=====
[Drone][1] is a Continuous Integration platform built on Docker, written in Go.
## github
```yaml
#
# Github » Settings » Applications » Developer applications » Register new application
#
Application name: drone
2016-05-01 03:06:20 +02:00
Homepage URL: http://drone.easypi.info/
2016-01-11 17:21:41 +02:00
Application description: Drone is a Continuous Integration platform built on Docker, written in Go
2016-05-01 03:06:20 +02:00
Authorization callback URL: http://drone.easypi.info/authorize
2016-01-11 17:21:41 +02:00
Client ID: ... (generated by github)
Client Secret: ... (generated by github)
```
## docker-compose.yml
```yaml
drone:
2016-05-31 17:16:56 +02:00
image: drone/drone
2016-01-11 17:21:41 +02:00
ports:
- "8000:8000"
volumes:
- ./drone:/var/lib/drone
- /var/run/docker.sock:/var/run/docker.sock
2016-05-31 17:16:56 +02:00
environment:
- REMOTE_DRIVER=github
- REMOTE_CONFIG=https://github.com?client_id=...&client_secret=...
# - REMOTE_DRIVER=gogs
# - REMOTE_CONFIG=https://git.easypi.info/?open=false
- DEBUG=false
2016-01-11 17:21:41 +02:00
restart: always
2016-05-31 17:16:56 +02:00
wall:
image: drone/drone-wall
ports:
- "8080:80"
restart: always
2016-01-11 17:21:41 +02:00
```
2016-05-31 17:16:56 +02:00
> Drone will register gogs webhooks automatically, you don't need to do it manually.
2016-01-11 17:21:41 +02:00
## nginx/sites-enabled/drone
```
server {
listen 80;
2016-05-01 03:06:20 +02:00
server_name drone.easypi.info;
2016-01-11 17:21:41 +02:00
location / {
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $remote_addr;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_set_header Host $http_host;
proxy_set_header Origin "";
proxy_pass http://127.0.0.1:8000;
proxy_redirect off;
proxy_http_version 1.1;
proxy_buffering off;
chunked_transfer_encoding off;
}
}
2016-05-31 17:16:56 +02:00
server {
listen 80;
server_name wall.easypi.info;
location / {
proxy_pass http://127.0.0.1:8080;
}
}
2016-01-11 17:21:41 +02:00
```
## up and running
2016-05-31 17:16:56 +02:00
```bash
2016-01-11 17:21:41 +02:00
# server
$ cd ~/fig/drone/
$ docker-compose up -d
$ docker-compose logs
2016-05-31 17:16:56 +02:00
# client (login with remote driver credential)
$ firefox http://drone.easypi.info/
# dashboard
$ firefox http://wall.easypi.info/
2016-01-11 17:21:41 +02:00
```
[1]: http://readme.drone.io/usage/overview/