create server - phozzy/ansible4openstack GitHub Wiki

to create server you should run:

$ ansible-playbook create_server.yml --extra-vars '{"sname": "<server_name>", \
                                                    "sflavor": "<server_flavor_id>", \
                                                    "keys": "<ssh_key_pair_id>", \
                                                    "sdomain": "<domain>", \
                                                    "spassword": "<otp2join_ipa>", \
                                                    "snet": "<subnet>", \
                                                    "security": ["security_group0_id", "security_group1_id", ...], \
                                                    "simage": "<source_image_id>", \
                                                    "vsize": "<size_in_gb>"}'
  • server_name - name you have chosen
  • server_flavor_id - id of flavor you have chosen
  • ssh_key_pair_id - id of ssh key pair
  • domain - your network domain
  • otp2join_ipa - one time password randomly generated by
    $ ipa host-add --force --random <server_name>.<domain>
    
    or via web_ui
  • subnet - name of subnet where you create server
  • security_groupX_id - id of security groups to use, at minimum they are default and Allow_SSH
  • source_image_id - id of image from which you create volume
  • size_in_gb - desired size of volume you create
⚠️ **GitHub.com Fallback** ⚠️