Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Docker/Longhorn/K8s: Project directory "/app" is not empty. #107

Open
panromir opened this issue Jul 7, 2024 · 0 comments
Open

Docker/Longhorn/K8s: Project directory "/app" is not empty. #107

panromir opened this issue Jul 7, 2024 · 0 comments

Comments

@panromir
Copy link

panromir commented Jul 7, 2024

Hey there!

I stumbled upon this issue when creating an automad deployment in my k8s cluster using longhorn as a storage backend with ext4 as it's default fsType.

There are several ways for me to work around this issue, but I think this should be fixed in this image, if possible.

Initially, the container will run /init.sh, which already checks whether or not a folder exists named /app/automad.
When using a new ext4 volume mounted at /app, there will be a lost+found folder

~ # ls -lah /app
total 20K
drwxr-xr-x    3 www-data www-data    4.0K Jul  7 21:28 .
drwxr-xr-x    1 root     root          62 Jul  7 21:28 ..
drwxr-xr-x    2 www-data www-data   16.0K Jul  7 21:28 lost+found

The Composer Script doesn't seem to like that:

~ # composer create-project --no-install --prefer-dist automad/automad /app $AUTOMAD_VERSION
Do not run Composer as root/super user! See https://getcomposer.org/root for details
Continue as root/super user [yes]? yes
Creating a "automad/automad" project at "../app"

In CreateProjectCommand.php line 371:

  Project directory "/app" is not empty.


create-project [-s|--stability STABILITY] [--prefer-source] [--prefer-dist] [--prefer-install PREFER-INSTALL] [--repository REPOSITORY] [--repository-url REPOSITORY-URL] [--add-repository] [--dev] [--no-dev] [--no-custom-installers] [--no-scripts] [--no-progress] [--no-secure-http] [--keep-vcs] [--remove-vcs] [--no-install] [--no-audit] [--audit-format AUDIT-FORMAT] [--ignore-platform-req IGNORE-PLATFORM-REQ] [--ignore-platform-reqs] [--ask] [--] [<package> [<directory> [<version>]]]

From what I can find on the internet, composer itself doesn't really have an option to work around this behaviour.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant