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 DigitalOcean snapshot Data Source. #12873

Conversation

andrewsomething
Copy link
Contributor

@andrewsomething andrewsomething commented Mar 20, 2017

This PR adds a data source for DigitalOcean snapshots similar to the aws_ami data source. This allows for referencing user created snapshots when creating a new Droplet or volume.

@andrewsomething andrewsomething force-pushed the do-snapshot-datasource branch from 6ef465f to 9011654 Compare March 21, 2017 03:35
@andrewsomething
Copy link
Contributor Author

I'm realizing I'm a bit unclear on the acceptance tests for data sources. I can run them locally, but they're looking at resources on my account. Is there some way I should be creating the resources first, or will the values be updated to reflect resources on the testing account?

@stack72
Copy link
Contributor

stack72 commented Mar 21, 2017

Hi @andrewsomething

Yes, the way we usually do it is like this:

https://github.com/hashicorp/terraform/blob/master/builtin/providers/aws/data_source_aws_autoscaling_groups_test.go#L15

Notice i have a config that rolls out the actual resources as a first step, then a follow up that adds the datasource

Paul

@andrewsomething
Copy link
Contributor Author

@stack72 thanks for the pointer! Though, I guess I'll have to withdraw this for now. Looks like I need to implement a resource to take snapshots before I can implement the data source.

@ghost
Copy link

ghost commented Apr 15, 2020

I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.

If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@ghost ghost locked and limited conversation to collaborators Apr 15, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants