OlivierGaland / CashFactory

Lightweight docker image running many passive income applications (proxy and bandwidth share) : Honeygain , EarnApp , IPRoyal Pawns , PacketStream , Peer2Profit
GNU General Public License v3.0
305 stars 55 forks source link

Cannot start service Webserver on Digital Ocean Droplet #12

Closed philiporlando closed 2 years ago

philiporlando commented 2 years ago

I am trying to get CashFactory to run on a Digital Ocean Droplet. I have followed the README and was able to complete all of the setup/install steps without any issues. However, when I try to spin up the docker container I am getting the following error:

sudo docker-compose up -d
# Status: Downloaded newer image for containrrr/watchtower:latest
# Creating cashfactory_Portainer_1 ... 
# Creating cashfactory_Webserver_1 ... 
# Creating cashfactory_Portainer_1
# Creating cashfactory_Webserver_1 ... error
# ERROR: for cashfactory_Webserver_1  Cannot start service Webserver: driver failed programming external connectivity on endpoint cashfactory_Webserver_1 (394cc2041f4a08141efdd22a3a1286e21135b539caba37a13c2c1ecCreating cashfactory_Portainer_1 ... done
# ERROR: for Webserver  Cannot start service Webserver: driver failed programming external connectivity on endpoint cashfactory_Webserver_1 (394cc2041f4a08141efdd22a3a1286e21135b539caba37a13c2c1eccacc8b18e): Error starting userland proxy: listen tcp4 0.0.0.0:80: bind: address already in use
# ERROR: Encountered errors while bringing up the project.

Any troubleshooting to get this running on a Digital Ocean Droplet is appreciated! Here is some info about the droplet:

uname -a 
# Linux ubuntu-s-1vcpu-1gb-sfo2-01 4.15.0-159-generic #167-Ubuntu SMP Tue Sep 21 08:55:05 UTC 2021 x86_64 x86_64 x86_64 GNU/Linux
HeroCC commented 2 years ago

This part listen tcp4 0.0.0.0:80: bind: address already in use makes me think you're already running a webserver. Are you running apache or nginx on that server? What does curl localhost print? Shutting down that webserver or changing the port inside the compose file should fix it.

philiporlando commented 2 years ago

Thanks for calling this out. I was indeed running an Apache webserver on this droplet.

The following commands solved this issue:

sudo service apache2 stop
sudo docker-compose up -d
# cashfactory_Portainer_1 is up-to-date
# Starting cashfactory_Webserver_1 ... 
# Starting cashfactory_Webserver_1 ... done
# Creating cashfactory_Peer2profit_1 ... 
# Creating cashfactory_Earnapp_1 ... 
# Creating cashfactory_Packetstream_PsClient_1 ... 
# Creating cashfactory_IproyalPawns_1 ... 
# Creating cashfactory_Honeygain_1 ... 
# Creating cashfactory_Packetstream_PsClient_1
# Creating cashfactory_Peer2profit_1
# Creating cashfactory_Earnapp_1
# Creating cashfactory_Honeygain_1
# Creating cashfactory_Packetstream_PsClient_1 ... done
# Creating cashfactory_Packetstream_Watchtower_1 ... 
# Creating cashfactory_Earnapp_1 ... done

Thank you for the help!

OlivierGaland commented 2 years ago

Thanks for you diagnostic,

Indeed it may not have been a great idea from me to set up the webserver on port 80 in my initial delivery, any install on a computer already running a webserver on std port will face this issue.

Olivier.