7 Commits
1.0.0 ... 1.1.0

4 changed files with 29 additions and 6 deletions
CHANGELOG.mdREADME.md
molecule_hetznercloud/playbooks
setup.cfg

@ -7,6 +7,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
## [Unreleased] ## [Unreleased]
## [1.1.0] - 2021-03-30
## Changed
- Relaxed bounds on Molecule to allow allow all versions < v4 ([#27](https://github.com/ansible-community/molecule-hetznercloud/pull/27))
## [1.0.0] - 2021-01-06 ## [1.0.0] - 2021-01-06
This is a major release with breaking changes for your schema and support for a This is a major release with breaking changes for your schema and support for a

@ -21,6 +21,20 @@ useful, please support my maintenance work financially through my
Sponsor profile](https://github.com/sponsors/decentral1se). I do not receive Sponsor profile](https://github.com/sponsors/decentral1se). I do not receive
any financial support from RedHat or Hetzner Cloud for this work. any financial support from RedHat or Hetzner Cloud for this work.
## Install
```bash
$ pip install molecule-hetznercloud
```
## Upgrade
Please see the [CHANGELOG.md](./CHANGELOG.md) for migration guides.
```bash
$ pip install --upgrade molecule-hetznercloud
```
## Usage ## Usage
You need to expose a `HCLOUD_TOKEN` environment variable in your environment. You need to expose a `HCLOUD_TOKEN` environment variable in your environment.
@ -31,10 +45,9 @@ Find out more about how to get one of those [over here](https://docs.hetzner.clo
$ export HCLOUD_TOKEN=mycoolapitoken $ export HCLOUD_TOKEN=mycoolapitoken
``` ```
Then install the required Python package. Then create a role using the driver plugin.
```bash ```bash
$ pip install molecule-hetznercloud
$ molecule init role myrolename -d hetznercloud $ molecule init role myrolename -d hetznercloud
``` ```
@ -78,12 +91,16 @@ It is possible to have the driver manage volumes during the test run.
You can add the following stanza to your Molecule configuration to have You can add the following stanza to your Molecule configuration to have
Molecule create this volume for the managed VPS. This volume will be cleaned up Molecule create this volume for the managed VPS. This volume will be cleaned up
after use. after use (**Please note**: there is a bug raised against clean-up right now,
see [#24](https://github.com/ansible-community/molecule-hetznercloud/issues/24)
for more).
```yaml ```yaml
volumes: volumes:
- name: "molecule-hetznercloud-volume-1-${INSTANCE_UUID}" - name: "molecule-hetznercloud-volume-1-${INSTANCE_UUID}"
location: /foo/bar
- name: "molecule-hetznercloud-volume-2-${INSTANCE_UUID}" - name: "molecule-hetznercloud-volume-2-${INSTANCE_UUID}"
size: 20
``` ```
Supported keys are: Supported keys are:
@ -145,6 +162,6 @@ Only doable by [Autonomic Cooperative](https://autonomic.zone/) members.
$ sudo apt install -y direnv $ sudo apt install -y direnv
$ cp .envrc.sample .envrc $ cp .envrc.sample .envrc
$ direnv allow $ direnv allow
$ pip install -e . $ pip install -e . ansible
$ cd integration && molecule test $ cd integration && molecule test
``` ```

@ -63,7 +63,7 @@
state: absent state: absent
when: when:
- not skip_instances - not skip_instances
- instance_conf | length # must contain at least one instance - instance_conf | length # must contain at least one instance
- name: Populate instance config - name: Populate instance config
set_fact: set_fact:

@ -56,7 +56,7 @@ setup_requires =
setuptools_scm_git_archive setuptools_scm_git_archive
install_requires = install_requires =
hcloud >= 1.10.0, < 2 hcloud >= 1.10.0, < 2
molecule >= 3.2.1, <= 3.3 molecule >= 3.2.1, < 4
pyyaml >= 5.3.1, < 6 pyyaml >= 5.3.1, < 6
[options.extras_require] [options.extras_require]