Skip to content

Commit 7bb3494

Browse files
committed
chore(aws,dns): dns setup for aws
1 parent 4025da0 commit 7bb3494

2 files changed

Lines changed: 66 additions & 5 deletions

File tree

src/quickstart/provider/aws/dns.md

Lines changed: 57 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,61 @@
1-
$ kubectl --namespace=deis describe svc deis-router | grep LoadBalancer
1+
## Find Your Load Balancer Hostname
22

3+
On EC2, Deis Workflow will automatically provision and attach a Google Cloud Loadbalancer to the router copmonent. This
4+
component is responsible for routing HTTP and HTTPS requests from the public internet to applications that are deployed
5+
and managed by Deis Workflow.
36

4-
should exit this doc with `DEIS_HOSTNAME` set
7+
By describing the `deis-router` service, you can see what hostname allocated by Google Cloud for your Deis Workflow
8+
cluster:
9+
10+
```
11+
$ kubectl describe svc deis-router --namespace=deis | egrep LoadBalancer
12+
Type: LoadBalancer
13+
LoadBalancer Ingress: abce0d48217d311e69a470643b4d9062-2074277678.us-west-1.elb.amazonaws.com
14+
```
15+
16+
## Prepare the Hostname
17+
18+
Now that you have the hostname of your load balancer we can use the `nip.io`
19+
DNS service to route arbitrary hostnames to the Deis Workflow edge router. This
20+
lets us point the Workflow CLI at your cluster without having to either use
21+
your own domain or update DNS!
22+
23+
First, pick one of the IP addresses allocated to your ELB:
24+
```
25+
$ host abce0d48217d311e69a470643b4d9062-2074277678.us-west-1.elb.amazonaws.com
26+
abce0d48217d311e69a470643b4d9062-2074277678.us-west-1.elb.amazonaws.com has address 52.8.166.233
27+
abce0d48217d311e69a470643b4d9062-2074277678.us-west-1.elb.amazonaws.com has address 54.193.5.73
28+
```
29+
30+
Note that this is **not** how you should connect to your cluster after the quickstart. Instead you will want to use your
31+
own domain name routed to the ELB CNAME. AWS actively manages the ELB addresses so what may be an ip address associated
32+
with your ELB today will be something else later on.
33+
34+
For now though, grab either address for the next step. We'll use `52.8.166.233` for this example.
35+
36+
To verify the Workflow API server and nip.io, construct your hostname by taking
37+
the ip address for your load balancer and adding `nip.io`. For our example
38+
above, the address would be: `52.8.166.233.nip.io`.
39+
40+
Nip answers with the ip address no matter the hostname:
41+
```
42+
$ host 52.8.166.233.nip.io
43+
52.8.166.233.nip.io has address 52.8.166.233
44+
$ host something-random.52.8.166.233.nip.io
45+
something-random.52.8.166.233.nip.io has address 52.8.166.233
46+
```
47+
48+
By default, any HTTP traffic for the hostname `deis` will be sent to the Workflow API service. To test that everything is connected properly you may validate connectivity using `curl`:
49+
50+
```
51+
$ curl http://deis.52.8.166.233.nip.io/v2/ && echo
52+
{"detail":"Authentication credentials were not provided."}
53+
```
54+
55+
You should see a failed request because we provided no credentials to the API server.
56+
57+
Remember the hostname, we will use it in the next step.
58+
59+
You are now ready to [register an admin user and deploy your first app](../../deploy-an-app.md).
560

661
[next: deploy your first app](../../deploy-an-app.md)

src/quickstart/provider/aws/install-aws.md

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -88,20 +88,26 @@ After installing Workflow on your cluster, you will need to adjust your load bal
8888
By default, the connection timeout for Elastic Load Blancers is 60 seconds. Unfortunately, this timeout is too short for
8989
long running connections when using `git push` functionality of Deis Workflow.
9090

91-
First, find the ELB that was automatically provisioned for the Deis Workflow edge router:
91+
Deis Workflow will automatically provision and attach a Elastic Loadbalancer to the router copmonent. This
92+
component is responsible for routing HTTP and HTTPS requests from the public internet to applications that are deployed
93+
and managed by Deis Workflow.
94+
95+
By describing the `deis-router` service, you can see what IP hostname has been allocated by AWS for your Deis Workflow
96+
cluster:
97+
9298
```
9399
$ kubectl describe svc deis-router --namespace=deis | egrep LoadBalancer
94100
Type: LoadBalancer
95101
LoadBalancer Ingress: abce0d48217d311e69a470643b4d9062-2074277678.us-west-1.elb.amazonaws.com
96102
```
97103

98-
The AWS name for the ELB is the first part of hostname before the `-`. List all of your ELBs by name to confirm:
104+
The AWS name for the ELB is the first part of hostname, before the `-`. List all of your ELBs by name to confirm:
99105
```
100106
$ aws elb describe-load-balancers --query 'LoadBalancerDescriptions[*].LoadBalancerName'
101107
abce0d48217d311e69a470643b4d9062
102108
```
103109

104-
Set the connection timeout to 1200 seconds:
110+
Set the connection timeout to 1200 seconds, make sure you use your load balancer name:
105111
```
106112
$ aws elb modify-load-balancer-attributes \
107113
--load-balancer-name abce0d48217d311e69a470643b4d9062 \

0 commit comments

Comments
 (0)