how to launch instance with vnic type 'pv' using oci_instance?
vburamdo opened this issue · 5 comments
how to launch instance with vnic type 'pv' using oci_instance?
Hello @vburamdo , this feature is not supported in our old oci-ansible-modules but this feature is supported in our new oci-ansible-collection modules. An instance with vnic type ParaVirtualized can be launched using the module oci_compute_instance
module with the parameter launch_options
like the following:
oci_compute_instance:
display_name: myinstance1
availability_domain: Uocm:PHX-AD-1
compartment_id: ocid1.compartment.oc1..xxxxxEXAMPLExxxxx...vm62xq
shape: VM.Standard2.1
.
.
launch_options:
network_type: "PARAVIRTUALIZED"
Use the command ansible-doc oracle.oci.oci_compute_instance
to have a more detailed look at the available parameter options
The old oci-ansible-modules are getting replaced and is now only in maintenance mode. These will be deprecated by mid-2021 and we would recommend you to use the new oci-ansible-collections. New features will be supported faster in the new oci-ansible-collections.
Refer to the Migration Guide for best migration practices.
@AmeyaLokre it has failed with new ansible collections, here is the error.
Error:
"msg": "Unsupported parameters for (oci_compute_instance) module: launch_options Supported parameters include: agent_config, api_user, api_user_fingerprint, api_user_key_file, api_user_key_pass_phrase, auth_type, availability_domain, compartment_id, config_file_location, config_profile_name, create_vnic_details, dedicated_vm_host_id, defined_tags, display_name, extended_metadata, fault_domain, force_create, freeform_tags, hostname_label, image_id, instance_id, ipxe_script, is_pv_encryption_in_transit_enabled, key_by, metadata, preserve_boot_volume, region, shape, shape_config, source_details, state, subnet_id, tenancy, wait, wait_timeout"}
I am using Latest SDK.
oci (2.21.5) - Oracle Cloud Infrastructure Python SDK
INSTALLED: 2.21.5 (latest)
it worked on 2.5.0 version.
Hello @vburamdo , can you please share the version of the oracle's ansible collection version ? Please use the command ansible-galaxy collection list
to view the version of the collection.