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

instance: Add OCI container support #111

Merged
merged 2 commits into from
Aug 5, 2024

Conversation

maveonair
Copy link
Member

@maveonair maveonair commented Aug 5, 2024

This pull requests adds an initial support to create a OCI container with this provider.

Example

resource "incus_instance" "redis" {
  project = "default"
  name    = "redis"
  image   = "docker:redis"
}

What's been done

  • Added support for OCI protocol
  • Added environment. to the computed keys list in resource_instance.go
  • Added test to run an OCI image
  • Added DockerHub as remote for test environment

@maveonair maveonair requested a review from stgraber August 5, 2024 20:49
@maveonair
Copy link
Member Author

@stgraber I'm assuming we need to add DockerHub as a new remote in the test environment(s) to run a test to create an OCI container. According to https://github.com/lxc/terraform-provider-incus/blob/main/.github/workflows/test.yml#L62:

...
incus remote add docker https://docker.io --protocol=oci
...

@stgraber
Copy link
Member

stgraber commented Aug 5, 2024

Yep!

Signed-off-by: Fabian Mettler <[email protected]>
@stgraber stgraber merged commit d7d2eb0 into lxc:main Aug 5, 2024
10 checks passed
@maveonair maveonair deleted the instance-resource-docker branch August 6, 2024 06:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants