Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add image_name, add more lifecycle_state and the boot_volume_id of the machine in the inventory #273

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

valkiriaaquatica
Copy link

@valkiriaaquatica valkiriaaquatica commented Mar 19, 2024

SUMMARY
now besides the image_id it also returns the image_name and also by default now the inventory also picks up the machines (not db) that are in the following states: "PROVISIONING", "RUNNING", "STOPPING", "STOPPED", "STARTING"] that before only RUNNING was picked up.
Also no data of the boot volumes of the machines is returned so added a way to return wht boot_volume_id.

ISSUE TYPE

  • Inventory module feature request

COMPONENT NAME
oci (oci.py)

ADDITIONAL INFORMATION
With this change is easier to make groups based on the OS running the machines, normally the image name in windows includes some text like "Win..." so is easier to make linux and windows groups. Also now the inventory returns instances that are not just running, also stopped, stopping, provisioning or starting.

Before the change the information return (just a part)

                    },
                    "display_name": "server_name",
                    "extended_metadata": {},
                    "fault_domain": ",
                    "freeform_tags": {},
                    "id": "ocid123456q",
                    "image_id": "ocid1.image.oc1..223243434",
                    "instance_configuration_id": null,
                    "instance_options": {
                        "are_legacy_imds_endpoints_disabled": false
                    },

After the change

                    },
                    "display_name": "server_name",
                    "extended_metadata": {},
                    "fault_domain": ",
                    "freeform_tags": {},
                    "id": "ocid123456q",
                    "image_id": "ocid1.image.oc1..223243434",
                    "image_name": "Oracle-linux..",
                    "instance_configuration_id": null,
                    "instance_options": {
                        "are_legacy_imds_endpoints_disabled": false
                    },
               # this is for the boot_volume_id
                    "availability_domain": ":EU-FRANKFURT-1",
                    "boot_volume_id": [
                        "ocid1.bootvolume.oc1.eu-frankfurt-1"
                    ],

Copy link

Thank you for your pull request and welcome to our community! To contribute, please sign the Oracle Contributor Agreement (OCA).
The following contributors of this PR have not signed the OCA:

To sign the OCA, please create an Oracle account and sign the OCA in Oracle's Contributor Agreement Application.

When signing the OCA, please provide your GitHub username. After signing the OCA and getting an OCA approval from Oracle, this PR will be automatically updated.

If you are an Oracle employee, please make sure that you are a member of the main Oracle GitHub organization, and your membership in this organization is public.

@oracle-contributor-agreement oracle-contributor-agreement bot added the OCA Required At least one contributor does not have an approved Oracle Contributor Agreement. label Mar 19, 2024
@valkiriaaquatica valkiriaaquatica changed the title add image_name and all states in vm filtered add image_name and all more lifecycle_state in vm filtered Mar 19, 2024
Copy link

Thank you for signing the OCA.

@oracle-contributor-agreement oracle-contributor-agreement bot added OCA Verified All contributors have signed the Oracle Contributor Agreement. and removed OCA Required At least one contributor does not have an approved Oracle Contributor Agreement. labels Mar 21, 2024
@valkiriaaquatica valkiriaaquatica changed the title add image_name and all more lifecycle_state in vm filtered add image_name, add more lifecycle_state and the boot_volume_id of the machine in the inventory Apr 11, 2024
Before was just taking some of the boot_volumes of the machines, not all, with this changes, is takign boot_volume(s) of all machines
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
OCA Verified All contributors have signed the Oracle Contributor Agreement.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant