monicahq / monica

Personal CRM. Remember everything about your friends, family and business relationships.
https://beta.monicahq.com
GNU Affero General Public License v3.0
21.6k stars 2.16k forks source link

Docker - Webinterface not accessible #6677

Closed BumbleCast closed 1 year ago

BumbleCast commented 1 year ago

First of all, thank you so much for all the work!

The docker (on Unraid) installs without an issue and monica seems to be running (log file shows - 'is live'). However the webinterface is not reachable. Any help is much appreciated!

Is the issue connected to the domain name? (if so, what do I need to set if I don't have a domain for monica?)

Logs:

`Database ready.AH00558: apache2: Could not reliably determine the server's fully qualified domain name, using 172.17.0.9. Set the 'ServerName' directive globally to suppress this message AH00558: apache2: Could not reliably determine the server's fully qualified domain name, using 172.17.0.9. Set the 'ServerName' directive globally to suppress this message [Mon Jun 12 04:56:12.281504 2023] [mpm_prefork:notice] [pid 1] AH00163: Apache/2.4.56 (Debian) PHP/8.1.20 configured -- resuming normal operations [Mon Jun 12 04:56:12.281607 2023] [core:notice] [pid 1] AH00094: Command line: 'apache2 -D FOREGROUND' settings/subscriptions/success.blade.php .......................... DONE settings/subscriptions/update.blade.php ........................... DONE settings/subscriptions/upgrade.blade.php .......................... DONE settings/tags.blade.php ........................................... DONE settings/users/accept.blade.php ................................... DONE settings/users/add.blade.php ...................................... DONE settings/users/blank.blade.php .................................... DONE settings/users/index.blade.php .................................... DONE

DIR resources/views/vendor/pagination ................................. DONE default.blade.php ................................................. DONE

DIR vendor/laravel/framework/src/Illuminate/Pagination/resources/views DONE bootstrap-4.blade.php ............................................. DONE bootstrap-5.blade.php ............................................. DONE default.blade.php ................................................. DONE semantic-ui.blade.php ............................................. DONE simple-bootstrap-4.blade.php ...................................... DONE simple-bootstrap-5.blade.php ...................................... DONE simple-default.blade.php .......................................... DONE simple-tailwind.blade.php ......................................... DONE tailwind.blade.php ................................................ DONE

DIR resources/views/vendor/notifications .............................. DONE email.blade.php ................................................... DONE

DIR vendor/laravel/framework/src/Illuminate/Notifications/resources/views DONE email.blade.php ................................................... DONE

DIR vendor/asbiin/laravel-webauthn/src/../resources/views/ ............ DONE authenticate.blade.php ............................................ DONE register.blade.php ................................................ DONE

DIR vendor/laravel/cashier/src/../resources/views ..................... DONE checkout.blade.php ................................................ DONE payment.blade.php ................................................. DONE receipt.blade.php ................................................. DONE

DIR resources/views/vendor/passport ................................... DONE authorize.blade.php ............................................... DONE

DIR vendor/laravel/passport/src/../resources/views .................... DONE authorize.blade.php ............................................... DONE

INFO Blade templates cached successfully.

✓ Performing migrations '/usr/local/bin/php' 'artisan' migrate --force

INFO Nothing to migrate.

✓ Check for encryption keys '/usr/local/bin/php' 'artisan' monica:passport --force Checking encryption keys... ✓ Files storage/oauth-private.key and storage/oauth-public.key detected. Checking Personal Access Client... ✓ Personal Access Client already created.

✓ Ping for new version '/usr/local/bin/php' 'artisan' monica:ping --force Call url: https://version.monicahq.com/ping instance version: 4.0.0 current version: 4.0.0

✓ Cache configuraton '/usr/local/bin/php' 'artisan' config:cache

INFO Configuration cached successfully.

✓ Maintenance mode: off '/usr/local/bin/php' 'artisan' up

INFO Application is now live.

Monica v4.0.0 is set up, enjoy. 192.168.1.85 - - [12/Jun/2023:06:43:12 +0200] "\x16\x03\x01\x02" 400 484 "-" "-" 192.168.1.85 - - [12/Jun/2023:06:43:12 +0200] "\x16\x03\x01\x02" 400 484 "-" "-" 192.168.1.85 - - [12/Jun/2023:06:43:04 +0200] "GET / HTTP/1.1" 302 1614 "-" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/114.0.0.0 Safari/537.36" 192.168.1.85 - - [13/Jun/2023:11:46:49 +0200] "\x16\x03\x01\x02" 400 484 "-" "-" 192.168.1.85 - - [13/Jun/2023:11:46:49 +0200] "\x16\x03\x01\x02" 400 484 "-" "-" 192.168.1.85 - - [13/Jun/2023:11:46:47 +0200] "GET / HTTP/1.1" 302 1614 "-" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/114.0.0.0 Safari/537.36"`

tamaskan commented 1 year ago

https://stackoverflow.com/questions/60144556/apache-httpd-server-doesnt-accept-get-http-request-from-f5-load-balancer . Did you try to set APP_TRUSTED_PROXIES to * ?

amphyvi commented 1 year ago

having the same issue on unraid, I can't use port 80 due to another docker conflict so that may be the issue. is there maybe a way to use a port other than 80?

(I already made sure APP_TRUSTED_PROXIES is set to * first)

tamaskan commented 1 year ago

it should run on ssl port 443, not port 80

amphyvi commented 1 year ago

even for using it on lan? I'm using 443 as well. the docker template I got from the Community Apps on unraid defaulted the port to 80 which is why I tried it. image

tamaskan commented 1 year ago

maybe something has changed, but the error points to a 80/443-mixup

BumbleCast commented 1 year ago

edit: Ok, I figured it out and my apologies, I am an idiot. if run locally only, I needed to specify http in the Container Variable: APP_URL so instead of localhost http://localhost

Now it works. Thanks for all the help!

even for using it on lan? I'm using 443 as well. the docker template I got from the Community Apps on unraid defaulted the port to 80 which is why I tried it. image

Maybe the above mentioned chnage will also solve your issue!

maybe something has changed, but the error points to a 80/443-mixup

Sorry for not getting back earlier. Thanks, it indeed does.

When accessing (local network) the webgui via http://IP:80/ monica does show some elements, on a white page.

However, even when adding Container Port 443 to my docker template (was missing in the unraid premade one), I still can't access https://IP:443/ and get the following error 192.168.1.85 - - [22/Jul/2023:12:56:06 +0200] "\x16\x03\x01\x02" 400 484 "-" "-" 192.168.1.85 - - [22/Jul/2023:12:56:06 +0200] "\x16\x03\x01\x02" 400 484 "-" "-"

(I also made sure APP_TRUSTED_PROXIES is set to * first)

I am unfortunately a beginner concerning SSL, etc. So sorry if I oversee a trivial error! Thanks for your help!

github-actions[bot] commented 2 months ago

This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.