Skip to content

Test #35

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 13 commits into
base: ci
Choose a base branch
from
150 changes: 75 additions & 75 deletions docker-compose.uffizzi.yml
Original file line number Diff line number Diff line change
@@ -1,75 +1,75 @@
version: '3'

# uffizzi integration
x-uffizzi:
ingress:
service: nginx
port: 8081
continuous_previews:
deploy_preview_when_pull_request_is_opened: true
delete_preview_when_pull_request_is_closed: true
share_to_github: true
services:

postgres:
image: postgres
environment:
- POSTGRES_USER=postgres
- POSTGRES_PASSWORD=password
- POSTGRES_DB=postgres
ports:
- "5432:5432"
deploy:
resources:
limits:
memory: 1000M
volumes:
- postgres_data:/var/lib/postgresql

parse:
image: parseplatform/parse-server:latest
environment:
- PARSE_SERVER_APPLICATION_ID=parse
- PARSE_SERVER_MASTER_KEY=parse@master123!
- PARSE_SERVER_DATABASE_URI=postgresql://postgres:password@localhost:5432/postgres
- PARSE_SERVER_MOUNT_PATH=/parse
- PORT=1337
ports:
- '1337:1337'
deploy:
resources:
limits:
memory: 1000M

dashboard:
build:
context: .
dockerfile: ./Dockerfile
ports:
- "4040:4040"
environment:
- PARSE_DASHBOARD_MASTER_KEY=parse@master123!
- PARSE_DASHBOARD_APP_ID=parse
- PARSE_DASHBOARD_APP_NAME=MyParseApp
- PARSE_DASHBOARD_USER_ID=admin
- PARSE_DASHBOARD_USER_PASSWORD=password
- MOUNT_PATH=/dashboard
- PARSE_DASHBOARD_ALLOW_INSECURE_HTTP=1
entrypoint: /bin/sh
command:
- "-c"
- "PARSE_DASHBOARD_SERVER_URL=$$UFFIZZI_URL/parse node Parse-Dashboard/index.js"
#- PARSE_DASHBOARD_COOKIE_SESSION_SECRET=AB8849B6-D725-4A75-AA73-AB7103F0363F
deploy:
resources:
limits:
memory: 1000M

nginx:
image: nginx:alpine
volumes:
- ./nginx-uffizzi:/etc/nginx
- ./nginx-uffizzi/html:/usr/share/nginx/html

volumes:
postgres_data:
version: '3'
# # uffizzi integration
# x-uffizzi:
# ingress:
# service: nginx
# port: 8081
# continuous_previews:
# deploy_preview_when_pull_request_is_opened: true
# delete_preview_when_pull_request_is_closed: true
# share_to_github: true
services:
postgres:
image: postgres
environment:
- POSTGRES_USER=postgres
- POSTGRES_PASSWORD=password
- POSTGRES_DB=postgres
ports:
- "5432:5432"
deploy:
resources:
limits:
memory: 1000M
volumes:
- postgres_data:/var/lib/postgresql
parse:
image: parseplatform/parse-server:latest
environment:
- PARSE_SERVER_APPLICATION_ID=parse
- PARSE_SERVER_MASTER_KEY=parse@master123!
- PARSE_SERVER_DATABASE_URI=postgresql://postgres:password@localhost:5432/postgres
- PARSE_SERVER_MOUNT_PATH=/parse
- PORT=1337
ports:
- '1337:1337'
deploy:
resources:
limits:
memory: 1000M
dashboard:
build:
context: .
dockerfile: ./ci/Dockerfile
ports:
- "4040:4040"
environment:
- PARSE_DASHBOARD_MASTER_KEY=parse@master123!
- PARSE_DASHBOARD_APP_ID=parse
- PARSE_DASHBOARD_APP_NAME=MyParseApp
- PARSE_DASHBOARD_USER_ID=admin
- PARSE_DASHBOARD_USER_PASSWORD=password
- MOUNT_PATH=/dashboard
- PARSE_DASHBOARD_ALLOW_INSECURE_HTTP=1
entrypoint: /bin/sh
command:
- "-c"
- "PARSE_DASHBOARD_SERVER_URL=$$UFFIZZI_URL/parse node Parse-Dashboard/index.js"
deploy:
resources:
limits:
memory: 1000M
nginx:
image: nginx:alpine
volumes:
- ./nginx-uffizzi:/etc/nginx
- ./nginx-uffizzi/html:/usr/share/nginx/html
volumes:
postgres_data:
41 changes: 21 additions & 20 deletions nginx-uffizzi/html/index.html
Original file line number Diff line number Diff line change
@@ -1,20 +1,21 @@
<!doctype html>

<html>

<head>

<title>Parse Dashboard Preview</title>

</head>

<body>

<h1>Endpoint:</h1>

<a href="/dashboard/"><b>Click to Visit Parse Dashboard</b></a>


</body>

</html>

<!doctype html>

<html>

<head>

<title>Parse Dashboard Preview</title>

</head>

<body>

<h1>Endpoint:</h1>

<a href="/dashboard/"><b>Click to Visit Parse Dashboard</b></a>


</body>

</html>
73 changes: 37 additions & 36 deletions nginx-uffizzi/nginx.conf
Original file line number Diff line number Diff line change
@@ -1,36 +1,37 @@
events {
worker_connections 1024; #default
}

http {

server {

listen 8081;

location / {
root /usr/share/nginx/html;
index index.html index.htm;
}

location /dashboard {
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-NginX-Proxy true;
proxy_pass http://localhost:4040/dashboard/;
proxy_ssl_session_reuse off;
proxy_set_header Host $http_host;
proxy_redirect off;
}

location /parse {
proxy_set_header X-Forwarded-For $remote_addr;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
keepalive_requests 10;
keepalive_timeout 75s;
proxy_pass http://localhost:1337/parse/;
proxy_http_version 1.1;
}
}
}

events {
worker_connections 1024; #default
}
http {

server {

listen 8081;

location / {
root /usr/share/nginx/html;
index index.html index.htm;
}

location /dashboard {
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-NginX-Proxy true;
proxy_pass http://localhost:4040/dashboard/;
proxy_ssl_session_reuse off;
proxy_set_header Host $http_host;
proxy_redirect off;
}

location /parse {
proxy_set_header X-Forwarded-For $remote_addr;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
keepalive_requests 10;
keepalive_timeout 75s;
proxy_pass http://localhost:1337/parse/;
proxy_http_version 1.1;
}
}
}