Last active
October 25, 2019 15:25
-
-
Save embano1/2b0c7f99af839b2097598446e61ececc to your computer and use it in GitHub Desktop.
VEBA Contour Deployment
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
# examples/contour/03-envoy.yaml | |
apiVersion: apps/v1 | |
kind: DaemonSet | |
metadata: | |
labels: | |
app: envoy | |
name: envoy | |
namespace: projectcontour | |
spec: | |
[...] | |
template: | |
[...] | |
spec: | |
### add these lines ### | |
dnsPolicy: ClusterFirstWithHostNet | |
hostNetwork: true | |
################### | |
containers: | |
[...] |
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
## Create SSL Certificate & Secret | |
KEY_FILE=/root/openfaas-gw.key | |
CERT_FILE=/root/openfaas-gw.crt | |
CN_NAME=$(hostname) | |
CERT_NAME=openfaas-gw-tls | |
openssl req -x509 -nodes -days 365 -newkey rsa:2048 -keyout ${KEY_FILE} -out ${CERT_FILE} -subj "/CN=${CN_NAME}/O=${CN_NAME}" |
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
kubectl -n openfaas create secret tls ${CERT_NAME} --key ${KEY_FILE} --cert ${CERT_FILE} |
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
kubectl create -f examples/contour/ |
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
git clone https://github.com/projectcontour/contour | |
cd contour | |
git checkout TODO: |
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
apiVersion: contour.heptio.com/v1beta1 | |
kind: IngressRoute | |
metadata: | |
labels: | |
app: openfaas | |
name: ingressroute-gateway | |
namespace: openfaas | |
spec: | |
virtualhost: | |
fqdn: ${HOSTNAME} | |
tls: | |
secretName: ${CERT_NAME} | |
minimumProtocolVersion: "1.2" | |
routes: | |
- match: /status | |
prefixRewrite: /status | |
services: | |
- name: tinywww | |
port: 8100 | |
- match: /bootstrap | |
prefixRewrite: /bootstrap | |
services: | |
- name: tinywww | |
port: 8100 | |
- match: / | |
services: | |
- name: gateway | |
port: 8080 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment