script atuomatico windows

This commit is contained in:
SAMBA\vfalco 2016-11-10 09:58:27 +01:00
parent dcd26992c2
commit 379521e3d2
4 changed files with 80 additions and 0 deletions

12
myToken.json Normal file
View File

@ -0,0 +1,12 @@
{
"ids": {
"User": 2,
"AccessToken": 1
},
"models": {
"User": {
"1": "{\"password\":\"$2a$10$ktoGSPHvrhUPSEytSIRoQuQbq9HRGXEYhrIjP7f4Xx9LXwxeU7vHG\",\"email\":\"admin@admin.com\",\"id\":1}"
},
"AccessToken": {}
}
}

45
nginx/nginx.conf Normal file
View File

@ -0,0 +1,45 @@
worker_processes 1;
error_log build/nginx/error.log;
pid build/nginx/nginx.pid;
events {
worker_connections 1024;
}
http {
sendfile on;
default_type application/octet-stream;
access_log build/nginx/access.log;
client_body_temp_path build/nginx/client-body;
proxy_temp_path build/nginx/proxy;
fastcgi_temp_path build/nginx/fastcgi;
uwsgi_temp_path build/nginx/uwsgi;
scgi_temp_path build/nginx/scgi;
server {
listen 8080;
server_name localhost;
autoindex off;
location /static {
alias build/public/;
autoindex on;
}
location ~ ^/account(?:/(.*))?$ {
proxy_pass http://127.0.0.1:3000/$1$is_args$args;
}
location ~ ^/salix(?:/(.*))?$ {
proxy_pass http://127.0.0.1:3001/$1$is_args$args;
}
location ~ ^/customer(?:/(.*))?$ {
proxy_pass http://127.0.0.1:3002/$1$is_args$args;
}
}
}

15
start.cmd Normal file
View File

@ -0,0 +1,15 @@
@echo off
echo ######################
echo "Arrancando Servicios"
echo ######################
echo.
call forever start forever.json
call forever list
IF NOT EXIST @salix\build\nginx (
echo.
echo.
echo "Creando carpeta @salix\build\nginx...."
mkdir @salix\build\nginx
)
call nginx -c nginx.conf -p @salix

8
stop.cmd Normal file
View File

@ -0,0 +1,8 @@
@echo off
echo ######################
echo "Parando Servicios"
echo ######################
echo.
call forever stopall
call forever list
call nginx -c nginx.conf -p @salix -s stop