ahelal / kitchen-ansiblepush

test-kitchen plugin to use ansible in push mode
41 stars 22 forks source link

Add `environment_vars` config #51

Closed syndbg closed 5 years ago

syndbg commented 5 years ago

Adds environment_vars config.

Why

This is very much needed when using an inventory source script such as ec2.py, proxmox.py and similar since you have to pass your authentication credentials via environment variables and/or files. Files are obviously not sufficient enough for dynamic test suites.

So with this change usage is

provisioner:
  name: ansible_push
  extra_vars:
    FOO: bar

Anything other than a Hash will be marked as invalid configuration. E.g

provisioner:
  name: ansible_push
  extra_vars: []

Also changed

Bumped version to minor version 0.10.0, since we're introducing new functionality.

@ahelal

ahelal commented 5 years ago

Hi @syndbg, thank you for the PR, I am currently with limited internet. I will have a look in mid Jan.

Happy new year 🎆

ahelal commented 5 years ago

Hi i @syndbg, Sorry for the delay can you rebase the pr ? so i can merge

syndbg commented 5 years ago

@ahelal Yes, sure. Rebased.

Also noticed that I didn't add any documentation about the existence of environment_vars. Added in bbd5f88cfc90066c4a4032085fba1909101b53f9

Imo it's good to merge.

syndbg commented 5 years ago

Ping @ahelal :)