Skip to content

Provide Oracle instances with a subnet id to use and provide metadata to instance launch. #479

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

Merged
merged 2 commits into from
Mar 6, 2025

Conversation

uhryniuk
Copy link
Contributor

@uhryniuk uhryniuk commented Mar 4, 2025

PR Checklist

To ease the process of reviewing your PR, do make sure to complete the following checklist before submitting a pull
request.

  • I have added unit tests to cover the new behavior under ``tests/unit_tests/```
  • I have run tox -e format locally to automatically format my code before submitting
  • I have run tox locally ensuring that it passes before submitting
  • (if applicable) I have added a reference to issues that this PR relates to in the PR message (Refs GH-1234, Fixes GH-1234)
  • My commits are atomic and follow the convetional commit message format (https://www.conventionalcommits.org/en/v1.0.0/)

Otherwise, please leave the PR as a draft to indicate that it is still a work in progress.

Description

The following changes allow Oracle instances to be created on a specific subnet by providing the OCID for that subnet ahead of time. This is in contrast to the existing ways of finding the subnet by name or using related objects (vcn, network client, etc).

Additionally, this PR allows for users to provide a metadata dictionary directly to the instance launch. Previously, this was limited to providing the authorized ssh keys or user data to a default metadata dictionary. The default dictionary and provided dictionary are combined to ensure backwards compatibility.

Additional Context and Relevant Issues

Often in OCI scripts, the subnet OCID is previously known and being able to directly supply it would be advantageous. While providing metadata directly is required when using other services such as OKE, where metadata must be passed to instances based on cluster configuration.

Test Steps

N/A

@uhryniuk uhryniuk requested a review from a-dubs March 4, 2025 15:58
@uhryniuk uhryniuk force-pushed the add-subnet-id branch 2 times, most recently from dc882b7 to 51c614d Compare March 4, 2025 16:39
@uhryniuk
Copy link
Contributor Author

uhryniuk commented Mar 4, 2025

Ran tox locally, and 3.8 passed. 🖖

Copy link
Contributor

@a-dubs a-dubs left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@uhryniuk uhryniuk merged commit f85d617 into canonical:main Mar 6, 2025
8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants