Conversation
----- | ||
|
||
Installing | ||
~~~~~~~~~~ |
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.
not markdown
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.
Argh, RST.
f88c817
to
1dbaa87
Compare
@@ -0,0 +1,4 @@ | |||
--- | |||
vhost: |
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.
It isn't obvious to me that this (and correct me if I'm wrong here) is actually a configurable key. I suggest that Yaml like this might be a better example:
---
frontend_webservers:
production:
service_id: a1b2c3d4e5f6g7
staging:
service_id: a2b3c4d5e6f7g8
backend_api_requests:
production:
service_id: a3b4c5d6e7f8g9
I'd also drop the term vhost
and refer instead to services, pools, environments or something else everywhere it's used.
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.
vhost
is a term we've inherited from the script, so that's why we kept it. We might be able to do something about that, if the need is there.
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.
But, you're right re: this example file. I'll put the current content in comments and provide a more specific example below.
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.
I know you've inherited vhost
from the existing script, but since this is PR#1 that could quickly be changed to something else before it's in use by anyone else... ;)
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.
Fair enough. How about service
? A service can belong to an environment?
On 9 July 2015 at 16:12, Sam J Sharpe notifications@github.com wrote:
In fastly.yaml
#1 (comment)
:@@ -0,0 +1,4 @@
+---
+vhost:I know you've inherited vhost from the existing script, but since this is
PR#1 that could quickly be changed to something else before it's in use by
anyone else... ;)—
Reply to this email directly or view it on GitHub
https://github.com/alphagov/fastly-configure/pull/1/files#r34265811.
Andrew Langhorn
Web Operations
Government Digital Service
e: andrew.langhorn@digital.cabinet-office.gov.uk
t: +44 (0)7810 737375
a: 6th Floor, Aviation House, 125 Kingsway, London, WC2B 6NH
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.
Tricky one. I couldn't think of the right language so I was deliberately vague. The issue with service
is that's a name Fastly uses for a specific CDN configuration. What we want is something larger than a service - a configuration
?
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.
Yep, okay. A configuration works well.
13df4b2
to
650feb3
Compare
@samjsharpe I addressed your naming comment by swapping out |
Adds: - deploy_vcl - Gemfile(.lock) - README - fastly.yaml - vcl_templates/ directory vcl_templates/ directory is kept because this is where deploy_vcl expects your VCL to live.
650feb3
to
1c272cf
Compare
LGTM 👍 |
I recently watched a talk from Target about how they migrated to use Fastly. One of the things that was mentioned was that they have no way to deploy VCL in CI jobs, whereas - well - we do. We currently deploy our Fastly configuration using this script, but it's unfortunately kept internally on GitHub Enterprise and never sees the light of day. We should open this up to the world so that everyone can use it.
The script reads in from a YAML file to generate a hash which the rest of the script uses, which means that configuration can be kept separate from code, which is a good idea. There's a README, and an example of
fastly.yaml
, which is required to set parameters to pass to the Fastly API.