nodedock / nodedock

📦🚢 Docker Node.js development environment
https://nodedock.io/
MIT License
194 stars 35 forks source link

Nodedock multiple projects #18

Open bangsyir opened 4 years ago

bangsyir commented 4 years ago

Any idea for multiple project inside a nodedock.

Can i run both projects on nodedock as laradock did?

viatsko commented 4 years ago

Nodedock is based on Laradock, so we can, in theory, inherit any features Laradock has.

As an idea - you can specify different ports for different projects in env file / docker compose.

Nevertheless, can you point at laradock's multiple project support documentation/implementation? Maybe it's a 10 mins work to replicate it?

bangsyir commented 4 years ago

i have 2 nodejs project on 1 nodedock. +nodedock +project1 +project2

.env APP_CODE_PATH_HOST=../

inside the nodedock->nginx->sites, i create 2 .conf files, project1.conf

server_name project1.test;
root /var/www/project1;

and project2.conf

server_name project2.test;
root /var/www/project2;

/etc/hosts

127.0.0.1 project1.test
127.0.0.1 project2.test

after i run docker-compose up -d nginx and i check docker-compose ps nodedock_nginx_1 state is exit 1 nodedock_node_1 state is exit 245

on logs error show like this 2020/05/12 15:53:09 [emerg] 1#1: host not found in upstream "node:9000" in /etc/nginx/conf.d/upstream.conf:1

bangsyir commented 4 years ago

I try on laradock +laradock +project1 +project2

just setup the laradock->nginx->sites project1.conf

server_name project1.test;
root /var/www/project1/public;

project2.conf

server_name project2.test;
root /var/www/project2/public;

and running smoothly i hope you can help

maheshbhattaraai commented 3 years ago

I also need help in multi-project setup with single nodedock .