Skip to content
This repository has been archived by the owner on Jun 12, 2021. It is now read-only.

Workspace management #146

Open
ncapeyron opened this issue Nov 13, 2019 · 0 comments
Open

Workspace management #146

ncapeyron opened this issue Nov 13, 2019 · 0 comments

Comments

@ncapeyron
Copy link

Hello,

There is a way to use workspaces like environments ?

Actual behavior

Actually, I'm used to manipulate environments with ansible like this :

ansible/
  |- staging/
      |- inventory
      |- hosts_vars/
           |- host1.yml
           |- host2.yml
           |- ...
      |- groups_vars/
           |- all.yml
           |- group1.yml
           |- ...
  |- production/
      |- inventory
      |- hosts_vars/
           |- ...
      |- groups_vars/
           |- ...
  |- roles/
      |- role1/
      |- role2/
      |- ... 
  |- playbook.yml

When I run the playbook on env staging, I do :

$ ansible-playbook -i staging/inventory playbook.yml

And it works like a charm...

Since a few months, I'm working with terraform and make a large use of workspaces like environments :

$ terraform workspace new staging
$ terraform workspace select staging
$ terraform apply 

Expected behavior

But i'd love to combine workspaces with the ansible environments directories. So, when I run "terraform apply" in the workspace "staging", It could be really nice to run ansible with the directory of vars "staging" in ansible.
Do you think that is possible ?

I hope i'm enough clear...

Thx a lot and sorry for my poor english :)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant