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 a9b9c7f3
authored
Mar 27, 2020
by
tingweiwang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
增加配置文件注释,优化目录层级,公共组件 autodl-core抽离
1 parent
ba0c190a
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
5 additions
and
120 deletions
autodl/cfg-autodl-core.yaml → autodl-core/cfg-autodl-core.yaml
autodl/autodl-nginx/cfg-autodl-nginx.yaml → autodl-core/cfg-autodl-nginx.yaml
autodl/autodl-core-nginx/cfg-core-nginx.yaml
kpl/cfg-autodl-core.yaml
kpl/cfg-kpl-backend.yaml
kpl/kpl-nginx/kpl-seetaas-nginx.yaml → kpl/cfg-kpl-nginx.yaml
autodl/cfg-autodl-core.yaml
→
autodl
-core
/cfg-autodl-core.yaml
View file @
a9b9c7f
...
...
@@ -25,8 +25,8 @@ data:
pvc: adl-pvc
docker:
registry_host: harbor_host
registry_group_name: core
registry_host: harbor_host
#内网镜像仓库,启动任务,autodl-core会先推送镜像到该字段定义的仓库中
registry_group_name: core
#内网仓库推送任务镜像目录(自定义)
host:
nginx_host: core_nginx
...
...
autodl
/autodl-nginx
/cfg-autodl-nginx.yaml
→
autodl
-core
/cfg-autodl-nginx.yaml
View file @
a9b9c7f
File moved
autodl/autodl-core-nginx/cfg-core-nginx.yaml
deleted
100644 → 0
View file @
ba0c190
apiVersion
:
v1
data
:
apiserver.conf
:
|
server {
listen 80;
location ~ /tensorboard/([-_.:\w]+)/(.*) {
resolver kube-dns.kube-system.svc.cluster.local valid=5s; #dns组件service名字,按实际情况修改
rewrite_log on;
rewrite ^/tensorboard/([-_.:\w]+)/(.*) /$2 break;
proxy_pass http://$1;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
proxy_set_header Origin "";
}
location ~ /jupyter/([-_.:\w]+)/(.*) {
resolver kube-dns.kube-system.svc.cluster.local valid=1s; #dns组件service名字,按实际情况修改
rewrite_log on;
rewrite ^/jupyter/([-_.:\w]+)/(.*) /jupyter/$1/$2 break;
proxy_pass http://$1;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
proxy_set_header Origin "";
}
location ~ /standard/([-_.:\w]+)/(.*) {
resolver kube-dns.kube-system.svc.cluster.local valid=5s; #dns组件service名字,按实际情况修改
rewrite_log on;
rewrite ^/standard/([-_.:\w]+)/(.*) /$2 break;
proxy_pass http://$1;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
proxy_set_header Origin "";
}
error_page 404 502 /502.html;
location = /502.html {
root /etc/nginx;
}
}
nginx.conf
:
|
user nginx;
worker_processes 2;
worker_rlimit_nofile 65535;
error_log /var/log/nginx/error.log warn;
pid /var/run/nginx.pid;
events {
worker_connections 4096;
}
http {
include /etc/nginx/mime.types;
default_type application/octet-stream;
log_format main '$remote_addr - $remote_user [$time_local] "$request" '
'$status $body_bytes_sent "$http_referer" '
'"$http_user_agent" "$http_x_forwarded_for"';
access_log /var/log/nginx/access.log main;
sendfile on;
#tcp_nopush on;
keepalive_timeout 65;
#gzip on;
include /etc/nginx/conf.d/*.conf;
}
kind
:
ConfigMap
metadata
:
name
:
cfg-core-nginx
namespace
:
autodl
kpl/cfg-autodl-core.yaml
deleted
100644 → 0
View file @
ba0c190
apiVersion
:
v1
data
:
app.yaml
:
|
app:
rpc_port: ":30100"
mount_path: "/mnt/ceph"
database:
type: "mysql"
host: mysql_host
name: autodl-core
user: mysql_user
password: mysql_password
url: "%s:%s@tcp(%s)/%s?charset=utf8mb4&parseTime=True&loc=Local"
redis:
addr: "redis_host"
password: "redis_password"
mongodb:
addr: "mongo_host"
k8s:
namespace: autodl
pvc: adl-pvc
docker:
registry_host: harbor_host
registry_group_name: core
host:
nginx_host: core_nginx
kind
:
ConfigMap
metadata
:
name
:
cfg-autodl-core
namespace
:
autodl
kpl/cfg-kpl-backend.yaml
View file @
a9b9c7f
...
...
@@ -5,13 +5,13 @@ data:
port: "8919"
# 在autodl core注册的service id, 作为app的唯一标示
service_id: "kpl_service_id" #改成模板,
本地是seetaas3,金山是
kpl3
service_id: "kpl_service_id" #改成模板,
金山云环境该值为
kpl3
# 用于在k8s集群中选择节点所需的namespace
service_namespace: "kpl"
ceph_path: "/mnt/ceph"
kpl_relpath: "kpl_realy_path" #改成模板
,本地是seetaas,金山是kpl,!!!需要修改代码读取为kpl_relpath
kpl_relpath: "kpl_realy_path" #改成模板
,金山云环境为kpl,该值是kpl服务挂载到容器内/存储下的子目录/mnt/ceph/kpl
user_center_relpath: "user_center"
monitor_port: "8920"
deploy_proxy_port: "8921"
...
...
@@ -25,7 +25,7 @@ data:
database:
type: "mysql"
host: mysql_host
name: kpl_db_name
name: kpl_db_name
#kpl服务的数据库名字,抽离为模板,金山云环境为kpl
user: mysql_user
password: mysql_password
url: "%s:%s@tcp(%s)/%s?charset=utf8mb4&parseTime=True&loc=Local"
...
...
kpl/
kpl-nginx/kpl-seetaas
-nginx.yaml
→
kpl/
cfg-kpl
-nginx.yaml
View file @
a9b9c7f
File moved
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