I have a single solution with 2 projects - https://github.com/vickyrathee/dotnet-test-app
- My Website: dotnet-test-website (domain.com)
- My API: dotnet-test-api (api.domain.com)
How can I configure my projects to be deployed on single Ubuntu/Amazon linux server?
I already tried using the Urls
option on appsettings.json
to set port 5001
for API project and 5002
for website project as mentioned here
https://github.com/vickyrathee/dotnet-test-app/blob/master/dotnet-test-app/appsettings.json
{
"Urls" : "http://localhost:5001"
}
But as per the EB logs, it seems to trying port 5000
instead what I defined in appsettings.json
----------------------------------------
/var/log/nginx/error.log
----------------------------------------
2021/02/14 09:11:24 [error] 3583#0: *1 connect() failed (111: Connection refused) while connecting to upstream, client: 172.31.10.146, server: , request: "GET / HTTP/1.1", upstream: "http://127.0.0.1:5000/", host: "172.31.26.188"
2021/02/14 09:11:39 [error] 3583#0: *3 connect() failed (111: Connection refused) while connecting to upstream, client: 172.31.10.146, server: , request: "GET / HTTP/1.1", upstream: "http://127.0.0.1:5000/", host: "172.31.26.188"
2021/02/14 09:11:54 [error] 3583#0: *5 connect() failed (111: Connection refused) while connecting to upstream, client: 172.31.10.146, server: , request: "GET / HTTP/1.1", upstream: "http://127.0.0.1:5000/", host: "172.31.26.188"
Additionally, how to publish it correctly in separate folders, So that there are no conflict between them. EB allow single zip
file upload with appsettings.json
on root, while I have two with some other files as well in common and can't just put them on single directory to zip. Any help will be appreciated.