onelinesetup 507 B

1234567891011121314151617
  1. #!/usr/bin/env bash
  2. set -o errexit
  3. DOMAIN=${1:-magento.test}
  4. VERSION=${2:-2.4.7}
  5. EDITION=${3:-community}
  6. if [ -d "./bin" ]; then
  7. echo "Error: The current directory is not empty. Please remove all contents within this directory and try again."
  8. exit 1
  9. fi
  10. curl -s https://raw.githubusercontent.com/markshust/docker-magento/master/lib/template | bash
  11. # &&'s are used below otherwise onelinesetup script fails/errors after bin/download
  12. bin/download "${VERSION}" "${EDITION}" \
  13. && bin/setup "${DOMAIN}"