Skip to content

Instantly share code, notes, and snippets.

@eerison
Last active October 24, 2025 10:43
Show Gist options
  • Select an option

  • Save eerison/b79070bf142e4ea301867bd3308dadea to your computer and use it in GitHub Desktop.

Select an option

Save eerison/b79070bf142e4ea301867bd3308dadea to your computer and use it in GitHub Desktop.
Easy php setup
#!/bin/bash
# You can run using: bash <(curl -fsSL https://gist.githubusercontent.com/eerison/b79070bf142e4ea301867bd3308dadea/raw/easy-php-setup.sh)
git clone https://github.com/shield-wall/easy-php-setup.git
cd easy-php-setup
docker compose up -d --wait
docker compose exec -T php git config --global --add safe.directory /app
docker compose exec php composer install
mkdir var
mkdir var/cache
chmod 777 var/cache
docker compose exec -T database sh -c 'exec mysql --defaults-extra-file=.docker/mysql/config.cnf' < .docker/mysql/dump.sql
xdg-open http://localhost:8000
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment