Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save Quinten/d7444a72f9fb4458c510 to your computer and use it in GitHub Desktop.
Save Quinten/d7444a72f9fb4458c510 to your computer and use it in GitHub Desktop.
Activate maintenance mode on Magento 2 w/ IP address exclusion list
#!/bin/bash
# Comma separated list of IPs to be excluded
echo "123.123.123.123,234.234.234.234">var/.maintenance.ip
# For the rest of the world we go down for maintenance NOW
touch var/.maintenance.flag
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment