-
Notifications
You must be signed in to change notification settings - Fork 19
Conversation
------------------------ | ||
|
||
You can take advantage of an [Ansible dynamic inventory script for OpenStack (`openstack.py`)](http://docs.ansible.com/ansible/intro_dynamic_inventory.html#example-openstack-external-inventory-script) instead of having to manage an inventory file when using Ansible to push out changes. | ||
This direectory takes advantage of an |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
directory
|
||
ansible-playbook idr-os-playbook.yml -e "omero_vm_key_name='My Keypair'" | ||
ansible-playbook os-create.yml -e omero_vm_name=FOO -e omero_vm_key_name=YOURKEY \ | ||
-e "omero_vm_flavour='My Keypair'" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
omero_vm_flavour='My Keypair'
: change the param value to an example flavour (m1.*
are standard)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
...ok, but this is from you! 😄
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nope. I'm just wrong.
To delete the VM and related security group: | ||
|
||
ansible-playbook idr-os-playbook-delete.yml | ||
ansible-playbook os-delete.yml |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since you're editing this doc, worth mentioning that deleting the security group will fail (and can be ignored) if anything else is using that group?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, I looked into: "if unused" but didn't find anything. Will push.
👍, a few small comments inline. FYI I was thinking of an all-in-one playbook for the IDR to spin up one or more VMs (e.g. separate postgres, I think this is needed to avoid future performance/debugging issues), and to run the required playbook roles- I think it's possible with the add_host. But that's for a future PR |
One more, fix the playbook name at the at the top of |
Pushed a first round of fixes. Need to discuss groups first. |
Pushed better group names. Done unless you have suggestions. |
Same here. I was assuming with an include an add_host wouldn't be necessary, but isn't so bad if it is. |
Using `git format-patch --root $SHA HEAD`
|
|
Style fixes in joshmoore#1 |
Suggested minor changes to PR70
@joshmoore Are you planning anything else? |
I don't have anything in flight. My top hope was to get the volumes auto-mounted but I failed to cleanly get the device name from os_server_volume (i.e. whether it already exists or not). We could go for a map of device names to volume names, but I haven't started on that. |
Another strange problem: limiting to
|
Install mount.nfs helper
@manics : pushed my latest fixes and the proposed |
One nit-picky comment: You've got a mix of long (multiline) and short form YAML in some playbooks. If it's easier I can fix it in my pending commits. |
(Sorry, accidentally clicked close instead of comment) |
https://github.com/joshmoore/infrastructure/compare/os-playbooks...manics:pr70?expand=1 Main changes (you should be able to fast forward):
Still more to come |
Forgot to say so far I've mostly been testing with E.g. |
Merging this as is since things are getting complicated. Leaving @manics to figure out the next phase. |
Refactored my non-openstack changes into two separate PRs: |
openstack playbooks
This removes the requirement on checking out a branch from @manics as well as the bootstrap script. This means the benefits described in the README are no longer possible, but with the introduction of the dynamic inventory I think this is balanced out. The general workflow is actually quite nice:
ansible-playbook ... os-create.yml
ansible-playbook ... os-omero.yml
ansible-playbook ... os-delete.yml
I'd even like to see this runnable by devspace in a "ci" tenancy.
Questions:
openstack/*.md
moves todocs
andopenstack/examples/*.yml
move toansible
?omero
usage from theos-*.yml
files?