Compare commits

...

2 Commits

Author SHA1 Message Date
a4d8a46360 2.0.28 2019-01-19 15:57:50 +01:00
84e5c10129 fix(core): update 2019-01-19 15:57:49 +01:00
3 changed files with 4 additions and 4 deletions

2
package-lock.json generated
View File

@ -1,6 +1,6 @@
{ {
"name": "@pushrocks/smartnginx", "name": "@pushrocks/smartnginx",
"version": "2.0.27", "version": "2.0.28",
"lockfileVersion": 1, "lockfileVersion": 1,
"requires": true, "requires": true,
"dependencies": { "dependencies": {

View File

@ -1,6 +1,6 @@
{ {
"name": "@pushrocks/smartnginx", "name": "@pushrocks/smartnginx",
"version": "2.0.27", "version": "2.0.28",
"private": false, "private": false,
"description": "control nginx from node, TypeScript ready", "description": "control nginx from node, TypeScript ready",
"main": "dist/index.js", "main": "dist/index.js",

View File

@ -75,7 +75,7 @@ export let getHostConfigString = (hostNameArg: string, destinationIpArg: string,
const hostConfig = plugins.smartstring.indent.normalize(` const hostConfig = plugins.smartstring.indent.normalize(`
upstream ${hostNameArg} { upstream ${hostNameArg} {
keepalive 100; keepalive 100;
server ${destinationIpArg}; server ${destinationIpArg}:${destinationPortArg};
} }
server { server {
@ -101,7 +101,7 @@ export let getHostConfigString = (hostNameArg: string, destinationIpArg: string,
proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme; proxy_set_header X-Forwarded-Proto $scheme;
proxy_pass http://${hostNameArg}:${destinationPortArg}; proxy_pass http://${hostNameArg};
} }
} }
`); `);