linuxserver/docker-bookstack

[BUG] HTTP ERROR 500 occurred while uploading a cover to a shelf or book

rozhkoserhii opened this issue · 3 comments

Is there an existing issue for this?

  • I have searched the existing issues

Current Behavior

HTTP ERROR 500 occurred while uploading a cover to a shelf or book.
Increasing these parameters did not help.
.env
FILE_UPLOAD_SIZE_LIMIT=50
php.ini
memory_limit = 256M
the problem repeated on two only deployable containers

Expected Behavior

No response

Steps To Reproduce

  1. Download image https://ru.freepik.com/free-vector/servisnoe-obsluzivanie-serverov-peredaca-informacii-nastroika-oborudovania-idea-setevogo-servera-khostingovye-tekhnologii-khranenie-baz-dannykh-oborudovanie-dla-programmirovania-vektornaa-illustracia-izolirovannykh-koncepcii-metafory_12470270.htm#fromView=search&page=1&position=30&uuid=bc61c1a4-8c78-4f16-aac1-88e1fa282d5a
    image
    image

  2. Upload image on cover to a shelf or book

  3. This page isn’t working ... is currently unable to handle this request. HTTP ERROR 500.
    image

Environment

- OS: Ubuntu 22.04.4 LTS (GNU/Linux 5.15.0-97-generic x86_64)
- Memory = "2048" 
- Cpus = "2"

CPU architecture

x86-64

Docker creation

---
services:
  bookstack:
    image: lscr.io/linuxserver/bookstack
    container_name: bookstack
    environment:
      - PUID=1000
      - PGID=1000
      - TZ=Europe/Kiev
      - APP_URL=http://192.168.0.107
      - DB_HOST=bookstack_db
      - DB_PORT=3306
      - DB_USER=bookstack
      - DB_PASS=bookpass
      - DB_DATABASE=bookstackapp
    volumes:
      - ./bookstack_app_data:/config
    ports:
      - 80:80
    restart: unless-stopped
    depends_on:
      - bookstack_db

  bookstack_db:
    image: lscr.io/linuxserver/mariadb
    container_name: bookstack_db
    environment:
      - PUID=1000
      - PGID=1000
      - TZ=Europe/Kiev
      - MYSQL_ROOT_PASSWORD=bookroot
      - MYSQL_DATABASE=bookstackapp
      - MYSQL_USER=bookstack
      - MYSQL_PASSWORD=bookpass
    volumes:
      - ./bookstack_db_data:/config
    restart: unless-stopped

Container logs

Docker compose logs bookstack
bookstack  | [migrations] started
bookstack  | [migrations] 01-nginx-site-confs-default: skipped
bookstack  | [migrations] 02-default-location: skipped
bookstack  | [migrations] done
bookstack  | ───────────────────────────────────────
bookstack  |
bookstack  |       ██╗     ███████╗██╗ ██████╗
bookstack  |       ██║     ██╔════╝██║██╔═══██╗
bookstack  |       ██║     ███████╗██║██║   ██║
bookstack  |       ██║     ╚════██║██║██║   ██║
bookstack  |       ███████╗███████║██║╚██████╔╝
bookstack  |       ╚══════╝╚══════╝╚═╝ ╚═════╝
bookstack  |
bookstack  |    Brought to you by linuxserver.io
bookstack  | ───────────────────────────────────────
bookstack  |
bookstack  | To support LSIO projects visit:
bookstack  | https://www.linuxserver.io/donate/
bookstack  |
bookstack  | ───────────────────────────────────────
bookstack  | GID/UID
bookstack  | ───────────────────────────────────────
bookstack  |
bookstack  | User UID:    1000
bookstack  | User GID:    1000
bookstack  | ───────────────────────────────────────
bookstack  | Linuxserver.io version: v24.05.2-ls151
bookstack  | Build-date: 2024-06-17T18:25:38+00:00
bookstack  | ───────────────────────────────────────
bookstack  |
bookstack  | using keys found in /config/keys
bookstack  | App Key found - setting variable for seds
bookstack  | Running config - DB_HOST set
bookstack  | **** APP_URL in /config/www/.env is being updated from https://bookstack.example.com to http://192.168.0.107 ****
bookstack  | **** If this is an existing install, you should run the following line from your host terminal to update the database URL entries: ****
bookstack  | ************************************************************************
bookstack  | docker exec -it bookstack php /app/www/artisan bookstack:update-url https://bookstack.example.com http://192.168.0.107
bookstack  | ************************************************************************
bookstack  | Waiting for DB to be available
bookstack  |
bookstack  |    INFO  Nothing to migrate.
bookstack  |
bookstack  | [custom-init] No custom files found, skipping...
bookstack  | [ls.io-init] done.

~/bookstack$ cat bookstack_app_data/log/nginx/error.log

2024/06/17 22:33:49 [error] 311#311: *35 FastCGI sent in stderr: "PHP message: PHP Fatal error:  Allowed memory size of 134217728 bytes exhausted (tried to allocate 32768 bytes) in /app/www/vendor/intervention/image/src/Drivers/Gd/Decoders/BinaryImageDecoder.php on line 45; PHP message: PHP Fatal error:  Allowed memory size of 134217728 bytes exhausted (tried to allocate 32768 bytes) in /app/www/vendor/laravel/framework/src/Illuminate/Foundation/Exceptions/Handler.php on line 1" while reading response header from upstream, client: 192.168.0.106, server: _, request: "POST /shelves HTTP/1.1", upstream: "fastcgi://127.0.0.1:9000", host: "192.168.0.107", referrer: "http://192.168.0.107/create-shelf"

cat bookstack_app_data/log/php/error.log

[17-Jun-2024 22:28:22] NOTICE: fpm is running, pid 310
[17-Jun-2024 22:28:22] NOTICE: ready to handle connections
[17-Jun-2024 22:28:49] NOTICE: Terminating ...
[17-Jun-2024 22:28:49] NOTICE: exiting, bye-bye!
[17-Jun-2024 22:29:48] NOTICE: fpm is running, pid 280
[17-Jun-2024 22:29:48] NOTICE: ready to handle connections

Thanks for opening your first issue here! Be sure to follow the relevant issue templates, or risk having this issue marked as invalid.

This issue has been automatically marked as stale because it has not had recent activity. This might be due to missing feedback from OP. It will be closed if no further activity occurs. Thank you for your contributions.

This issue is locked due to inactivity