Shape up README and fix typo
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
parent
04ca2779ae
commit
c7835f8a73
@ -26,7 +26,7 @@ steps:
|
|||||||
image: python:3.8-buster
|
image: python:3.8-buster
|
||||||
commands:
|
commands:
|
||||||
- pip install tox==3.14.6
|
- pip install tox==3.14.6
|
||||||
- tox -e py38---
|
- tox -e py38
|
||||||
|
|
||||||
---
|
---
|
||||||
kind: pipeline
|
kind: pipeline
|
||||||
|
74
README.md
74
README.md
@ -4,16 +4,78 @@
|
|||||||
[![PyPI Package](https://badge.fury.io/py/molecule-hetznercloud.svg)](https://badge.fury.io/py/molecule-hetznercloud)
|
[![PyPI Package](https://badge.fury.io/py/molecule-hetznercloud.svg)](https://badge.fury.io/py/molecule-hetznercloud)
|
||||||
[![Repository License](https://img.shields.io/badge/license-LGPL-brightgreen.svg)](LICENSE)
|
[![Repository License](https://img.shields.io/badge/license-LGPL-brightgreen.svg)](LICENSE)
|
||||||
|
|
||||||
Molecule Hetzner Cloud driver plugin.
|
A [Hetzner Cloud](https://www.hetzner.com/cloud) plugin for [Molecule](https://molecule.readthedocs.io/en/latest/).
|
||||||
|
|
||||||
|
This plugin allows you to do `molecule init role myrolename -d hetznercloud`
|
||||||
|
and have Molecule provision on-demand Hetzner Cloud VPSes of your choice for
|
||||||
|
your integration testing. New VPSes will be automagically created and
|
||||||
|
provisioned on each `molecule test` run, SSH keys are generated and managed
|
||||||
|
internally and all resources are cleaned regardless whether the role under test
|
||||||
|
succeeds or fails.
|
||||||
|
|
||||||
|
## Support
|
||||||
|
|
||||||
|
If you use this plugin and find it useful, please consider supporting my
|
||||||
|
maintenance work financially through [Liberapay](https://liberapay.com/decentral1se/) or my
|
||||||
|
[Github Sponsor profile](https://github.com/sponsors/decentral1se). I do not receive any
|
||||||
|
financial support from RedHat or Hetzner Cloud for this work.
|
||||||
|
|
||||||
## Usage
|
## Usage
|
||||||
|
|
||||||
TODO.
|
You need to expose a `HCLOUD_TOKEN` environment variable in your environment.
|
||||||
|
Find out more about how to get one of those [over here](https://docs.hetzner.cloud/#overview-authentication)
|
||||||
|
|
||||||
|
```bash
|
||||||
|
$ export HCLOUD_TOKEN=mycoolapitoken
|
||||||
|
```
|
||||||
|
|
||||||
|
Then install the required Python package.
|
||||||
|
|
||||||
|
```bash
|
||||||
|
$ pip install molecule-hetznercloud
|
||||||
|
$ molecule init role myrolename -d hetznercloud
|
||||||
|
```
|
||||||
|
|
||||||
|
Your `myrolename/molecule/default/molecule.yml` should then look like the following.
|
||||||
|
|
||||||
|
```yaml
|
||||||
|
---
|
||||||
|
dependency:
|
||||||
|
name: galaxy
|
||||||
|
driver:
|
||||||
|
name: hetznercloud
|
||||||
|
platforms:
|
||||||
|
- name: my-instance-name
|
||||||
|
server_type: cx11
|
||||||
|
image: debian-10
|
||||||
|
provisioner:
|
||||||
|
name: ansible
|
||||||
|
verifier:
|
||||||
|
name: ansible
|
||||||
|
```
|
||||||
|
|
||||||
|
Please see [docs.hetzner.cloud](https://docs.hetzner.cloud/) for information regarding images and server types.
|
||||||
|
|
||||||
|
Then just run the role.
|
||||||
|
|
||||||
|
```bash
|
||||||
|
$ cd myrolename && molecule test
|
||||||
|
```
|
||||||
|
|
||||||
|
To ease initial debugging for getting thing started, also expose the following
|
||||||
|
environment variables.
|
||||||
|
|
||||||
|
```bash
|
||||||
|
$ export MOLECULE_NO_LOG=False # not so verbose, helpful
|
||||||
|
$ export MOLECULE_DEBUG=True # very verbose, last ditch effort
|
||||||
|
```
|
||||||
|
|
||||||
## Mirroring
|
## Mirroring
|
||||||
|
|
||||||
- [Primary](https://git.autonomic.zone/autonomic-cooperative/molecule-hetznercloud) @ git.autonomic.zone (because independent cooperatively run infrastructure, yay!)
|
Issues will be responded to on both issue trackers.
|
||||||
- [Mirror](https://github.com/ansible-community/molecule-hetznercloud) @ github.com (because centralised commerically owned infrastructure, sigh!)
|
|
||||||
|
- [git.autonomic.zone](https://git.autonomic.zone/autonomic-cooperative/molecule-hetznercloud) (primary)
|
||||||
|
- [github.com](https://github.com/ansible-community/molecule-hetznercloud) (mirror)
|
||||||
|
|
||||||
## Molecule Documentation
|
## Molecule Documentation
|
||||||
|
|
||||||
@ -21,7 +83,7 @@ TODO.
|
|||||||
|
|
||||||
## Contact
|
## Contact
|
||||||
|
|
||||||
- Ping @decentral1se on the `#ansible-molecule` channel on [Freenode](https://freenode.net).
|
- Ping @decentral1se on the `#ansible-molecule` channel on [Freenode](https://webchat.freenode.net).
|
||||||
|
|
||||||
## License
|
## License
|
||||||
|
|
||||||
@ -29,6 +91,8 @@ The [LGPL](https://www.gnu.org/licenses/lgpl-3.0.en.html) license.
|
|||||||
|
|
||||||
## Testing
|
## Testing
|
||||||
|
|
||||||
|
This is all done on our [drone.autonomic.zone](https://drone.autonomic.zone/autonomic-cooperative/molecule-hetznercloud) setup.
|
||||||
|
|
||||||
Unit tests and such.
|
Unit tests and such.
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
|
Loading…
Reference in New Issue
Block a user