Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
tingweiwang
/
configmap-kpl
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
1
Pipelines
Wiki
Snippets
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 67564cf3
authored
Jan 21, 2021
by
tingweiwang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
增加{{ K8S_DNS_SVC }}字段,默认值为kube-dns.kube-system.svc.cluster.local
1 parent
cf25795a
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
4 deletions
kpl/cfg-kpl-nginx.yaml.j2
kpl/cfg-kpl-nginx.yaml.j2
View file @
67564cf
...
...
@@ -29,7 +29,7 @@ data:
}
location ^~ /api/v1 {
resolver
kube-dns.kube-system.svc.cluster.local valid=5s;
resolver
{{ K8S_DNS_SVC }} valid=5s; #默认值为kube-dns.kube-system.svc.cluster.local
proxy_pass http://kpl--backend.kpl.svc.cluster.local:8919$request_uri;
proxy_set_header Host $host;
proxy_connect_timeout 10s;
...
...
@@ -42,7 +42,7 @@ data:
}
location ~ /jupyterlab/proxy/([-_.:\w]+)/(.*) {
resolver
kube-dns.kube-system.svc.cluster.local
valid=5s; #修改成自己环境dns组件service名字
resolver
{{ K8S_DNS_SVC }}
valid=5s; #修改成自己环境dns组件service名字
rewrite_log on;
rewrite ^/jupyterlab/proxy/([-_.:\w]+)/(.*) /jupyterlab/proxy/$1/$2 break;
proxy_pass http://$1.autodl.svc.cluster.local:8888;
...
...
@@ -91,7 +91,7 @@ data:
proxy_set_header Connection "upgrade";
}
location ^~ /api/v1 {
resolver
kube-dns.kube-system.svc.cluster.local
valid=5s;
resolver
{{ K8S_DNS_SVC }}
valid=5s;
proxy_pass http://kpl--backend.kpl.svc.cluster.local:8919$request_uri;
proxy_set_header Host $host;
proxy_connect_timeout 10s;
...
...
@@ -104,7 +104,7 @@ data:
}
location ~ /jupyterlab/proxy/([-_.:\w]+)/(.*) {
resolver
kube-dns.kube-system.svc.cluster.local
valid=5s; #修改成自己环境dns组件service名字
resolver
{{ K8S_DNS_SVC }}
valid=5s; #修改成自己环境dns组件service名字
rewrite_log on;
rewrite ^/jupyterlab/proxy/([-_.:\w]+)/(.*) /jupyterlab/proxy/$1/$2 break;
proxy_pass http://$1.autodl.svc.cluster.local:8888;
...
...
Write
Preview
Markdown
is supported
Attach a file
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to post a comment