wger-project / docker

Production...ish docker-compose image for wger

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Something happened that caused an error

h0mesmart opened this issue · comments

Hi there,

After updating the image to the latest verssion of wger server and redis, now I'm unable to access the application. A message saying : " An error occurred Something happened that caused an error." appear on screen. I've checked the log but there is nothing I put it in here anyway.

###Redis

1:C 23 Apr 2022 06:45:08.013 # oO0OoO0OoO0Oo Redis is starting oO0OoO0OoO0Oo
1:C 23 Apr 2022 06:45:08.013 # Redis version=6.2.6, bits=64, commit=00000000, modified=0, pid=1, just started
1:C 23 Apr 2022 06:45:08.014 # Warning: no config file specified, using the default config. In order to specify a config file use redis-server /path/to/redis.conf
1:M 23 Apr 2022 06:45:08.016 * monotonic clock: POSIX clock_gettime
1:M 23 Apr 2022 06:45:08.020 * Running mode=standalone, port=6379.
1:M 23 Apr 2022 06:45:08.024 # Server initialized
1:M 23 Apr 2022 06:45:08.024 # WARNING overcommit_memory is set to 0! Background save may fail under low memory condition. To fix this issue add 'vm.overcommit_memory = 1' to /etc/sysctl.conf and then reboot or run the command 'sysctl vm.overcommit_memory=1' for this to take effect.
1:M 23 Apr 2022 06:45:08.031 * Loading RDB produced by version 6.2.6
1:M 23 Apr 2022 06:45:08.031 * RDB age 12 seconds
1:M 23 Apr 2022 06:45:08.031 * RDB memory usage when created 0.83 Mb
1:M 23 Apr 2022 06:45:08.032 # Done loading RDB, keys loaded: 82, keys expired: 0.
1:M 23 Apr 2022 06:45:08.032 * DB loaded from disk: 0.001 seconds
1:M 23 Apr 2022 06:45:08.032 * Ready to accept connections

####Server

Waiting for postgres...
PostgreSQL started :)
yarn install v1.22.18
[1/5] Validating package.json...
[2/5] Resolving packages...
[3/5] Fetching packages...
[4/5] Linking dependencies...
[5/5] Building fresh packages...
Done in 71.81s.
yarn run v1.22.18
$ sass wger/core/static/scss/main.scss:wger/core/static/yarn/bootstrap-compiled.css
Done in 10.00s.
Running in production mode, running collectstatic now

5723 static files copied to '/home/wger/static', 295 unmodified.
Using gunicorn...
[2022-04-23 06:37:47 +0000] [58] [INFO] Starting gunicorn 20.1.0
[2022-04-23 06:37:47 +0000] [58] [INFO] Listening at: http://0.0.0.0:8000 (58)
[2022-04-23 06:37:47 +0000] [58] [INFO] Using worker: sync
[2022-04-23 06:37:50 +0000] [59] [INFO] Booting worker with pid: 59
Waiting for postgres...
PostgreSQL started :)
yarn install v1.22.18
[1/5] Validating package.json...
[2/5] Resolving packages...
success Already up-to-date.
Done in 0.75s.
yarn run v1.22.18
$ sass wger/core/static/scss/main.scss:wger/core/static/yarn/bootstrap-compiled.css
Done in 9.37s.
Running in production mode, running collectstatic now

2 static files copied to '/home/wger/static', 6016 unmodified.
Using gunicorn...
[2022-04-23 06:45:30 +0000] [50] [INFO] Starting gunicorn 20.1.0
[2022-04-23 06:45:30 +0000] [50] [INFO] Listening at: http://0.0.0.0:8000 (50)
[2022-04-23 06:45:30 +0000] [50] [INFO] Using worker: sync
[2022-04-23 06:45:30 +0000] [51] [INFO] Booting worker with pid: 51

######DB

PostgreSQL Database directory appears to contain a database; Skipping initialization

2022-04-23 06:45:08.305 UTC [1] LOG:  starting PostgreSQL 12.10 on aarch64-unknown-linux-musl, compiled by gcc (Alpine 10.3.1_git20211027) 10.3.1 20211027, 64-bit
2022-04-23 06:45:08.305 UTC [1] LOG:  listening on IPv4 address "0.0.0.0", port 5432
2022-04-23 06:45:08.305 UTC [1] LOG:  listening on IPv6 address "::", port 5432
2022-04-23 06:45:08.428 UTC [1] LOG:  listening on Unix socket "/var/run/postgresql/.s.PGSQL.5432"
2022-04-23 06:45:08.689 UTC [22] LOG:  database system was shut down at 2022-04-23 06:44:56 UTC
2022-04-23 06:45:08.737 UTC [1] LOG:  database system is ready to accept connections

Thanks for any help.

Hi! Those logs seem fine, does nothing appear when you access the application and the error message pops up?

Alternatively, you can set DJANGO_DEBUG=True and restart everything, then you should get the error message

Hi! Those logs seem fine, does nothing appear when you access the application and the error message pops up?

Just after entering the url, there is no pop up, it's directly display this page

I meant in the logs when you open the application, it should log something

Alternatively, you can set DJANGO_DEBUG=True and restart everything, then you should get the error message

So I did set this variable to true and I've updated my prod.env with the latest version from here. And guess what it's working now. I think because of this DJANGO_PERFORM_MIGRATIONS=True

great! yes, that could have been the issue. If you find anything else, just open another issue