Closed cyrrill closed 3 years ago
Hello ! I did find a workaround that seem to works for docker desktop on linux In the Dockerfile i changed the creation line of the user for this
RUN useradd -ms /bin/bash --no-user-group -o -g $WWWGROUP -u $WWWUSER sail
And i set WWWGROUP and WWWUSER to 0:0 So it will alias sail for the root user but binded to a non-root user on your computer
I'm able to reproduce this on a fresh install of Ubuntu 22.04.5 LTS, a fresh install of the latest version of Laravel, and a fresh install of Docker Desktop.
Running docker context use default
, restarting, and running sail build --no-cache
does not resolve the issue.
From looking into this, the issue could be solved on Laravel's side by making sure that the user has proper access permission when the container is built. On Docker's side, there's something about Docker Desktop that makes this change necessary.
https://github.com/docker/desktop-linux/issues/252
If someone familiar with Sail wants to point me in the right direction, I'm happy to make a pull request to resolve.
Description:
Unable to write to storage folder.
Steps To Reproduce:
I have installed Sail into an existing Laravel 8 application as per the installation guide. The container and associated services come up and yield no errors.
When I attempt to access the application from the browser, the exception mentioned above shows up.
Normally, all you need to do is
chmod
and/orchown
the /storage/ folder in order for Laravel to run.When I try to publish the Dockerfiles (in order to attempt to set permissions), I get this other exception: