Skip to content

Commit

Permalink
Merge pull request #952 from pwzgorilla/master
Browse files Browse the repository at this point in the history
update example json and docs
  • Loading branch information
cmg authored Jan 29, 2018
2 parents abe3fbb + 47ee2be commit e3568b0
Show file tree
Hide file tree
Showing 2 changed files with 34 additions and 46 deletions.
17 changes: 13 additions & 4 deletions docs/api.md
Original file line number Diff line number Diff line change
Expand Up @@ -197,10 +197,19 @@ Example request:
"consecutiveFailures": 5
},
"proxy": {
"enabled": false,
"alias": "www.example.com",
"listen": 9999,
"sticky": false
"enabled": true,
"proxies": [
{
"alias": "g.cn",
"listen": "7890",
"sticky": false
},
{
"alias": "m.cn",
"listen": "8900",
"sticky": false
}
]
}
}
```
Expand Down
63 changes: 21 additions & 42 deletions example/create.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,17 +3,12 @@
"cmd": null,
"args": null,
"cpus": 0.01,
"mem": 32,
"mem": 5,
"disk": 0,
"runAs": "xcm",
"runAs": "test",
"priority": 0,
"instances": 3,
"instances": 1,
"constraints": [
{
"attribute": "vcluster",
"operator": "==",
"value": "bbklab"
}
],
"container": {
"docker": {
Expand All @@ -22,62 +17,46 @@
"forcePullImage": false,
"privileged": true,
"parameters": [
{
"key": "ipc",
"value": "host"
},
{
"key": "workdir",
"value": "/data"
}
],
"portMappings": [
{
"name": "web",
"protocol": "tcp",
"containerPort": 80,
"hostPort": 80
},
{
"name": "https",
"protocol": "tcp",
"containerPort": 443,
"hostPort": 443
}
]
},
"type": "DOCKER",
"volumes": [
{
"hostPath": "/home",
"containerPath": "/data",
"mode": "RW"
}
]
},
"env": {
"WORDPRESS_DB_HOST": "dbhost",
"WORDPRESS_DB_PASSWORD": "password"
},
"uris": [

],
"label": {
"USER_ID": "1",
"APP": "wordpress"
},
"healthCheck": {
"protocol": "http",
"path": "/",
"delaySeconds": 2,
"gracePeriodSeconds": 5,
"intervalSeconds": 1,
"portName": "web",
"timeoutSeconds": 1,
"consecutiveFailures": 5
},
"proxy": {
"enabled": true,
"alias": "g.cn",
"listen": 99,
"sticky": false
},
"deploy": {
"step": 10,
"onfailure": "stop"
"proxies": [
{
"alias": "g.cn",
"listen": "7890",
"sticky": false
},
{
"alias": "m.cn",
"listen": "8900",
"sticky": false
}
]
}
}

0 comments on commit e3568b0

Please sign in to comment.