Islandora-Devops / isle-dc

ISLE 8 - Dockerized Islandora 8 Deployment orchestrated with docker-compose
MIT License
23 stars 60 forks source link

make starter_dev doesn't work when run with WSL2 on Windows #409

Open Sora201710 opened 1 month ago

Sora201710 commented 1 month ago

The Bug:

When I tried to run the make starter_dev command on WSL2, it gave me an error message: "drupal /var/www/drupal/vendor does not exist and could not be created".

How to Reproduce: Stack: 1) Docker Desktop 4.34.2 2) WSL version: 2.3.24.0 3) Latest ISLE-dc version as of October 2024 (not sure how to find what version I'm on sorry) Open the isle-dc folder through WSL, then run the make starter_dev command.

Expected Behaviour: The Islandora Starter Site will be created locally.

Actual Behaviour: There is an error, "drupal /var/www/drupal/vendor does not exist and could not be created" image

I tried to run sudo make starter_dev and also creating the folder manually, but that didn't work. What I had to do was: 1) Go into the isle-dc folder on Docker, then open drupal-1 container in the terminal 2) Run command "composer install" 3) go back into WSL inside the isle-dc directory and run "sudo make starter-finalize ENVIRONMENT=starter_dev"

seth-shaw-asu commented 1 month ago

I can reproduce locally. It appears we need to give the group write access to the codebase directory; but I'll let folks who know more about ISLE-DC to determine the best fix for this.

seth-shaw-asu commented 1 month ago

Tested #320 to see if it would resolve the issue; but the issue still persists:

s6-envdir: fatal: unable to envdir /run/s6/container_environment: No such file or directory
Waiting for /var/www/drupal directory to be available...
make[1]: Leaving directory '/home/sshaw28/isle-dc'
docker compose exec -T -u nginx drupal sh -c 'composer install'
Installing dependencies from lock file (including require-dev)
Verifying lock file contents can be installed on current platform.
Package operations: 182 installs, 0 updates, 0 removals

In Filesystem.php line 260:

  /var/www/drupal/vendor does not exist and could not be created:

install [--prefer-source] [--prefer-dist] [--prefer-install PREFER-INSTALL] [--dry-run] [--download-only] [--dev] [--no-suggest] [--no-dev] [--no-autoloader] [--no-progress] [--no-install] [--audit] [--audit-format AUDIT-FORMAT] [-v|vv|vvv|--verbose] [-o|--optimize-autoloader] [-a|--classmap-authoritative] [--apcu-autoloader] [--apcu-autoloader-prefix APCU-AUTOLOADER-PREFIX] [--ignore-platform-req IGNORE-PLATFORM-REQ] [--ignore-platform-reqs] [--] [<packages>...]

make: *** [Makefile:181: starter_dev] Error 1

> ls -l
total 128
-rw-r--r-- 1 sshaw28 sshaw28          6925 Feb 29  2024 CONTRIBUTING.md
-rw-r--r-- 1 sshaw28 sshaw28          1077 Feb 29  2024 LICENSE
-rw-r--r-- 1 sshaw28 sshaw28         34152 Oct 16 11:03 Makefile
-rw-r--r-- 1 sshaw28 sshaw28         21399 Jul  3 16:27 README.md
drwxr-xr-x 6 sshaw28 sshaw28          4096 Feb 29  2024 build
drwxr-xr-x 2 sshaw28 sshaw28          4096 Oct 16 11:06 certs
drwxr-xr-x 7 sshaw28 systemd-journal  4096 Oct 16 11:07 codebase
-rw-r--r-- 1 sshaw28 sshaw28          4075 Sep 27 10:33 default_settings.txt
-rw-r--r-- 1 sshaw28 sshaw28         16112 Oct 16 11:06 docker-compose.yml
drwxr-xr-x 2 sshaw28 sshaw28          4096 Feb 29  2024 docs
-rw-r--r-- 1 sshaw28 sshaw28           729 Feb 29  2024 sample.Dockerfile
-rw-r--r-- 1 sshaw28 sshaw28          7021 Jul  3 16:27 sample.env
drwxr-xr-x 4 sshaw28 sshaw28          4096 Jul  3 16:27 scripts
drwxr-xr-x 4 sshaw28 sshaw28          4096 Feb 29  2024 secrets

> ls -l codebase
total 528
-rw-r--r-- 1 sshaw28 systemd-journal   7543 Oct 16 11:07 CONTRIBUTING.md
-rw-r--r-- 1 sshaw28 systemd-journal  18092 Oct 16 11:07 LICENSE
-rw-r--r-- 1 sshaw28 systemd-journal  18775 Oct 16 11:07 README.md
drwxr-xr-x 4 sshaw28 systemd-journal   4096 Oct 16 11:07 assets
-rwxr-xr-x 1 sshaw28 systemd-journal   5309 Oct 16 11:07 composer.json
-rw-r--r-- 1 sshaw28 systemd-journal 468872 Oct 16 11:07 composer.lock
drwxr-xr-x 3 sshaw28 systemd-journal   4096 Oct 16 11:07 config
drwxr-xr-x 3 root    root              4096 Oct 16 11:07 web

Tagging @DonRichards

DonRichards commented 1 month ago

@Sora201710 I'm not sure but I think running make with sudo will cause issues. The Makefile is calling sudo at times so this will likely cause a conflict.