Drone plugin for automating the creation of servers and cloud infrastructure
1.0K
A plugin for Drone that uses Terraform to automate the provisioning of cloud infrastructure such as servers and DNS records.
This is a simplified replacement for the community Drone plugin.
The plugin first initialises the state by calling terraform init, then applies any configuration (.tf) files found in the working directory by calling terraform apply.
The following parameters are used to configure the plugin:
.tf files (e.g. for staging and production), place each file in a folder called .terraform and use this parameter to specify which one to applyinit command, e.g. to store Terraform state in a remote databaseapply commandkind: pipeline
type: docker
name: default
steps:
- name: provide
image: gendall/drone-terraform
settings:
workspace: ${DRONE_DEPLOY_TO=development}
backend:
- conn_str=$TERRAFORM_CONF
- schema_name=${DRONE_REPO_NAME/-/_}
vars:
- project=${DRONE_REPO_NAME}
- output=.ansible
key:
from_secret: ssh_key
environment:
TERRAFORM_CONF:
from_secret: terraform_conf
This image will be automatically built and deployed to DockerHub when a Semver tag is pushed to the repo.
Content type
Image
Digest
Size
29.2 MB
Last updated
over 6 years ago
docker pull gendall/drone-terraform