-
Notifications
You must be signed in to change notification settings - Fork 9.6k
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
provider/fastly: add support for custom VCL configuration #6587
Conversation
I originally had this implemented on top of #6508 ( |
|
||
remove := oldVCLSet.Difference(newVCLSet).List() | ||
add := newVCLSet.Difference(oldVCLSet).List() | ||
_ = add |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this leftover from debugging, or doing something I don't yet understand?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oops, that was just debugging cruft left over. Assigning to _
lets you get around add declared and not used
errors while you're in the middle of things.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yup, thought so, thanks!
Wonderful! This was on my very short list of things to do, thanks! The code looks good otherwise so I may just merge today anyway. Thanks! |
@catsby sounds great. I just rebased some of those little fixes so I think this should be fine to merge whenever you're ready. |
Fastly already got back to me and enabled VCL support on our test account ❤️ I'll work on some tests and try to get this in today. Thanks again! |
…equire_full_window_and_locked * upstream/master: (665 commits) merged createVirtualMachine and deployVirtualMachine to setupVirtualMachine (hashicorp#6659) Update CHANGELOG.md provider/fastly: add support for custom VCL configuration (supersedes hashicorp#6587) (hashicorp#6662) Remove CHANGELOG entry for backported 0.6.17 feature Update CHANGELOG.md provider/vsphere: wait for network enhanced (hashicorp#6377) Update CHANGELOG.md Update CHANGELOG.md Update CHANGELOG.md docs: clarify an internal-plugins header Fixes an vet error. Update CHANGELOG.md provider/aws: Support for Redshift Cluster encryption using a KMS key (hashicorp#6712) provider/aws: Randomize key names in KMS alias test Include the list of allowed values for AWS auto scaling group termination policies (hashicorp#6710) website: docs for azurerm custom images Update CHANGELOG.md Godeps: rm dup github.com/ryanuber/columnize Add note about paid training provider/aws: Fix crash in ElastiCache param group ...
…ashicorp#6587) (hashicorp#6662) * provider/fastly: add support for custom VCL configuration
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. |
This PR adds a new
vcl
configuration block to support Fastly custom VCL. VCL is the Varnish Configuration Language, which is a compiled C-like DSL.Fastly's API model for custom VCL is that you have zero or more VCL files associated with your service, with one of them set as the "main" block. The main block needs to define some entrypoints that are invoked directly by the Varnish request handling flow, the other non-main blocks are available to include as libraries in the main block.
Usage
Caveats
Fastly does not allow custom VCL by default on new accounts. I think it is only available on paid accounts if you request access and describe your planned use case. I noted this in the documentation, but because of this I didn't (yet) write any acceptance tests for this functionality.
I'm open to any other ideas about how to represent VCL in this provider.