hashicorp / hashicorp/packer-plugin-googlecompute

GCS Data Source

Open
#109 0 comments 4 reactions 0 assignees View on GitHub
enhancement
Dominant language
Go
Stars
33
Forks
72
Avg merge
6h 47m
Merged PRs (30d)
3

Description

#### Community Note

Please vote on this issue by adding a 👍 [reaction](https://blog.github.com/2016-03-10-add-reactions-to-pull-requests-issues-and-comments/) to the original issue to help the community and maintainers prioritize this request.
Please do not leave "+1" or "me too" comments, they generate extra noise for issue followers and do not help prioritize the request.
If you are interested in working on this issue or have submitted a pull request, please leave a comment.

#### Description

It would be nice if a GCS data source existed that would allow one to download GCS objects during packer builds. These could then be referenced in `file` provisioners for upload to the build instance.

#### Use Case(s)

This would be useful when using non-GCP builders that need access to private data stored in a GCS bucket.

#### Potential configuration

```hcl
data "googlestorage" "my_file" {
bucket = "a-bucket"
object = "path/to/a.file"
}

...

build {
...
provisioner "file" {
sources = data.googlestorage.my_file.local_path
destination = "/tmp/a.file"
}
}
```

---

If there isn't already an accepted solution for this, and there is also interest, I am happy to work on a PR for this feature.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.