A template that deploys open source Drone.io onto a single Linux server. Requires you provide a Github Application Client ID and Secret.
- A Heat provider that supports the following:
- OS::Nova::KeyPair
- Rackspace::Cloud::Server
- An OpenStack username, password, and tenant id.
- python-heatclient
>= v0.2.8
:
pip install python-heatclient
We recommend installing the client within a Python virtual environment.
Parameters can be replaced with your own values when standing up a stack. Use
the -P
flag to specify a custom parameter.
github_client_secret
: Required: The Github Application Client Secret. See Creating a new Github application (Default: '')drone_deb_location
: Location of the Drone Deb File. (Default: http://downloads.drone.io/master/drone.deb)server_name
: The instance name (Default: drone)image
: Server image used for all servers that are created as a part of this deployment (Default: Ubuntu 14.04 LTS (Trusty Tahr))flavor
: Rackspace Cloud Server flavor to use. The size is based on the amount of RAM for the provisioned server. (Default: 1 GB Performance)github_client_id
: Rerquired: The Github Application Client ID. See Creating a new Github application (Default: '')
Once a stack comes online, use heat output-list
to see all available outputs.
Use heat output-show <OUTPUT NAME>
to get the value of a specific output.
drone_url
: Drone URLprivate_key
: SSH Private Keyserver_ip
: Server IP
For multi-line values, the response will come in an escaped form. To get rid of
the escapes, use echo -e '<STRING>' > file.txt
. For vim users, a substitution
can be done within a file using %s/\\n/\r/g
.
Drone is configured to authenticate using Github. To allow this, you will need to register a new application at github.com for this deployment. Follow these steps:
- Go to Github's New OAuth Application form.
- Enter a name into the Application name field. This is an arbitrary string.
You may wish to use
drone
. - Enter a valid URL into the Homepage URL field, such as
http://example.com
. - Enter another valid URL into the Application callback URL field, such as
http://example.com
- Click the Register application button. You will come to the OAuth Application Settings page for your new application.
- Note the values at the top of the page: Client ID and Client Secret
- Use these two values to populate the
github_client_id
&github_client_secret
parameters.
Once the deployment is created, edit the Github Application you created before your deployment to reference the Homepage URL and Authorization callback URL for your newly deployed Drone server.
Collect the server_ip
output from the deployment and follow these steps:
- Go to https://github.com/settings/applications
- Select the registered application you created before the deployment
- Change the Homepage URL field to
https://{your_server_ip}/
- Change the Authorization callback URL field to:
https://{your_server_ip}/api/auth/github.com
- Click the Update application button.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.