Last active
September 5, 2017 14:19
-
-
Save sjparkinson/73e32737c463e5ac42af6d881a7d1442 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
condition { | |
name = "request_is_us" | |
statement = "req.http.X-Geoip-Continent ~ \"(NA|SA|OC|AS)\" || (!F_eu_origin.healthy && F_us_origin.healthy)" | |
type = "REQUEST" | |
priority = 100 | |
} | |
condition { | |
name = "request_is_eu" | |
statement = "req.http.X-Geoip-Continent !~ \"(NA|SA|OC|AS)\" || (!F_us_origin.healthy && F_eu_origin.healthy)" | |
type = "REQUEST" | |
priority = 100 | |
} | |
backend { | |
name = "us_origin" | |
request_condition = "request_is_us" | |
healthcheck = "us_healthcheck" | |
} | |
backend { | |
name = "eu_origin" | |
request_condition = "request_is_eu" | |
healthcheck = "eu_healthcheck" | |
} | |
healthcheck { | |
name = "eu_healthcheck" | |
host = "example-eu-app.herokuapp.com" | |
path = "/__gtg" | |
} | |
healthcheck { | |
name = "us_healthcheck" | |
host = "example-us-app.herokuapp.com" | |
path = "/__gtg" | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment