Skip to content

Instantly share code, notes, and snippets.

@qtopie
Last active June 9, 2019 16:07
Show Gist options
  • Save qtopie/65daf66dd4ce196b67771d45d95b9a3d to your computer and use it in GitHub Desktop.
Save qtopie/65daf66dd4ce196b67771d45d95b9a3d to your computer and use it in GitHub Desktop.
Drone CI deployment with docker
version: "3.5"
services:
drone-server:
image: drone/drone
ports:
- 8080:80
# - 443:443
volumes:
- ./drone:/var/lib/drone
environment:
- DRONE_GITHUB_SERVER=https://github.com
- DRONE_GITHUB_CLIENT_ID=${github_client_id}
- DRONE_GITHUB_CLIENT_SECRET=${github_client_secret}
- DRONE_AGENTS_ENABLED=true
- DRONE_RPC_SECRET=${drone_rpc_secret}
drone-agent:
image: drone/agent
volumes:
- /var/run/docker.sock:/var/run/docker.sock
depends_on:
- drone-server
environment:
- DRONE_RPC_SERVER=http://drone-server
- DRONE_RPC_SECRET=${drone_rpc_secret}
#!/bin/bash
# Run `source github_env.sh` before `docker-compose up -d` command
export github_client_id="your-github-client-id"
export github_client_secret="your-github-client-secret"
export drone_rpc_secret="your-rpc-secret"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment