Skip to content

bug/docs: Permission & folder sturcture issues when installing with mounted volumes #77

@Blboun3

Description

@Blboun3

Issue filing pre-requisites

  • I've checked the documentation.
  • I've looked for similar issues both Open and Closed.
  • Ive tried clearing both cache and cookies in my browser or tried opening the app in the Incognito/InPrivate window.

Describe the bug

When installing with mounted volumes instead of named volumes I've encountered many errors.

  1. The folders on the drive HAVE to be owned by user 82:82 (related to **** Configure SQLite3 database **** Operation not permitted #54, feature request: support PUID + PGID environment settings #56, as that would help with this as well)
  2. The proper folder structure and required files have not been created in the mounted folders even when permissions were correct, this led to many errors including the software not being able to find the SQLite databse, the .env file or the Laravel migration/setup files

Steps to Reproduce the issue

Permission issues

  1. Download the official docker-compose.sqlite.yaml file
  2. Replace named volumes with local folders, i.e. /var/lib/invoiceshelf/{data,modules} owned by your user, root, or any other user for that matter. Even if I made sure it has 777 permissions it didn't work.

Files & folders issues

  1. As changing folder ownership to 82:82 seems to solve the previous issue it's not over, as it seems like the files and folders do not get created in mounted rather than named volumes, thus files like the SQLite database or .env file HAVE to be created manually for the software to be able to find and edit them.

Expected behavior

The software installing normally like with named volumes

Actual behavior

The software fails due to permission and file ownership issues and if that gets solved it is unable to install due to it missing critical files.

InvoiceShelf version

v2.3.3

Database type

SQLite

Server OS

Linux (Debian 13)

My solution that worked

  1. Make sure the base folder is owned by 82:82 (invoiceshelf/)
  2. Start the container with named volumes but also mount your base folder (invoiceshelf/)
  3. Go through the whole install and make sure invoiceshelf is working
  4. docker exec bash inside the container and manually copy the files from their in-container locations to folder in your mounted volumes (i.e. /var/www/html/Modules to /mnt/invoiceshelf/modules)
  5. Remove the named volumes and mount your proper foolders inside mounted volumes
  6. Voilá it works.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingdockerIssue relates to Docker container

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions