### Install docs dependencies Source: https://github.com/studio1902/statamic-peak/blob/main/CONTRIBUTING.md Navigate to the `docs` directory and run this command to install the VuePress documentation dependencies. ```bash npm i ``` -------------------------------- ### Run docs development server Source: https://github.com/studio1902/statamic-peak/blob/main/CONTRIBUTING.md After installing dependencies, run this command to start the local VuePress development server. Visit http://localhost:8080. ```bash npm run docs:dev ``` -------------------------------- ### Installation Commands Source: https://github.com/studio1902/statamic-peak/blob/main/export/README.example.md Run these commands in order to install dependencies, create a user, and build assets for the Statamic Peak site. ```bash composer install ``` ```bash php please make:user ``` ```bash npm i && npm run dev ``` -------------------------------- ### Production Environment File with Full Static Caching Source: https://github.com/studio1902/statamic-peak/blob/main/export/README.md Production .env example enabling full static caching via STATAMIC_STATIC_CACHING_STRATEGY=full. Includes settings for database, queue, mail, and Statamic features. ```env Dump your .env values here with sensitive data removed. The following is a production example that uses full static caching: APP_NAME="Statamic Peak" APP_ENV=production APP_KEY= APP_DEBUG=false APP_URL= APP_LOCALE=en APP_FALLBACK_LOCALE=en APP_FAKER_LOCALE=en_US APP_MAINTENANCE_DRIVER=file APP_MAINTENANCE_STORE=file BCRYPT_ROUNDS=12 LOG_CHANNEL=stack LOG_STACK=single LOG_DEPRECATIONS_CHANNEL=null LOG_LEVEL=debug DB_CONNECTION=sqlite # DB_HOST=127.0.0.1 # DB_PORT=3306 # DB_DATABASE=laravel # DB_USERNAME=root # DB_PASSWORD= SESSION_DRIVER=file SESSION_LIFETIME=120 SESSION_ENCRYPT=false SESSION_PATH=/ SESSION_DOMAIN=null BROADCAST_CONNECTION=log FILESYSTEM_DISK=local QUEUE_CONNECTION=redis CACHE_STORE=file CACHE_PREFIX= MEMCACHED_HOST=127.0.0.1 REDIS_CLIENT=phpredis REDIS_DATABASE= REDIS_HOST=127.0.0.1 REDIS_PASSWORD=null REDIS_PORT=6379 MAIL_MAILER=smtp MAIL_HOST=smtp.postmarkapp.com MAIL_PORT=587 MAIL_ENCRYPTION=tls MAIL_USERNAME= MAIL_PASSWORD= MAIL_FROM_ADDRESS= MAIL_FROM_NAME="${APP_NAME}" AWS_ACCESS_KEY_ID= AWS_SECRET_ACCESS_KEY= AWS_DEFAULT_REGION=us-east-1 AWS_BUCKET= AWS_USE_PATH_STYLE_ENDPOINT=false VITE_APP_NAME="${APP_NAME}" STATAMIC_LICENSE_KEY= STATAMIC_PRO_ENABLED=true STATAMIC_TWO_FACTOR_ENABLED=false STATAMIC_STACHE_WATCHER=auto STATAMIC_STATIC_CACHING_STRATEGY=full STATAMIC_CACHE_TAGS_ENABLED=true STATAMIC_REVISIONS_ENABLED=false STATAMIC_GRAPHQL_ENABLED=false STATAMIC_API_ENABLED=false STATAMIC_GIT_ENABLED=true STATAMIC_GIT_PUSH=true STATAMIC_GIT_DISPATCH_DELAY=5 STATAMIC_ELEVATED_SESSIONS_ENABLED=true #IMAGE_MANIPULATION_DRIVER=imagick #STATAMIC_CUSTOM_CMS_NAME= #STATAMIC_CUSTOM_LOGO_NAV_URL= #STATAMIC_CUSTOM_DARK_LOGO_URL= STATAMIC_CUSTOM_LOGO_OUTSIDE_URL="/visuals/client-logo.svg" #STATAMIC_CUSTOM_FAVICON_URL= #STATAMIC_CUSTOM_CSS_URL= ``` -------------------------------- ### Ploi Deploy Script Source: https://github.com/studio1902/statamic-peak/blob/main/export/README.md Deployment script for Ploi that skips deployment for bot commits, pulls the latest code, installs dependencies, builds assets, and runs Statamic artisan commands. ```bash if [[ {COMMIT_MESSAGE} =~ "[BOT]" ]] && [[ {DEPLOYMENT_SOURCE} == "quick-deploy" ]]; then echo "Automatically committed on production. Nothing to deploy." {DO_NOT_NOTIFY} exit 0 fi cd {SITE_DIRECTORY} git pull origin {BRANCH} {SITE_COMPOSER} install --no-interaction --prefer-dist --optimize-autoloader --no-dev npm ci npm run build {RELOAD_PHP_FPM} {SITE_PHP} artisan optimize:clear {SITE_PHP} artisan statamic:stache:refresh {SITE_PHP} artisan queue:restart {SITE_PHP} artisan statamic:search:update --all {SITE_PHP} artisan statamic:static:clear {SITE_PHP} artisan statamic:static:warm --queue echo "🚀 Application deployed!" ``` -------------------------------- ### Ploi Deploy Script Source: https://github.com/studio1902/statamic-peak/blob/main/export/README.example.md Deployment script for Ploi. Skips deployment for bot commits, pulls latest code, installs dependencies, builds assets, clears caches, and warms static cache. ```bash if [[ {COMMIT_MESSAGE} =~ "[BOT]" ]] && [[ {DEPLOYMENT_SOURCE} == "quick-deploy" ]]; then echo "Automatically committed on production. Nothing to deploy." {DO_NOT_NOTIFY} exit 0 fi cd {SITE_DIRECTORY} git pull origin {BRANCH} {SITE_COMPOSER} install --no-interaction --prefer-dist --optimize-autoloader --no-dev npm ci npm run build {RELOAD_PHP_FPM} {SITE_PHP} artisan cache:clear {SITE_PHP} artisan config:cache {SITE_PHP} artisan route:cache {SITE_PHP} artisan statamic:stache:warm {SITE_PHP} artisan queue:restart {SITE_PHP} artisan statamic:search:update --all {SITE_PHP} artisan statamic:static:clear {SITE_PHP} artisan statamic:static:warm --queue echo "🚀 Application deployed!" ``` -------------------------------- ### Forge Deploy Script Source: https://github.com/studio1902/statamic-peak/blob/main/export/README.md Deployment script for Forge that skips deployment for bot commits, pulls the latest code, installs dependencies, builds assets, and runs Statamic artisan commands. Includes a file lock to prevent simultaneous PHP-FPM restarts. ```bash if [[ $FORGE_QUICK_DEPLOY == 1 ]]; then if [[ $FORGE_DEPLOY_MESSAGE =~ "[BOT]" ]]; then echo "Automatically committed on production. Nothing to deploy." exit 0 fi fi cd $FORGE_SITE_PATH git pull origin $FORGE_SITE_BRANCH $FORGE_COMPOSER install --no-interaction --prefer-dist --optimize-autoloader --no-dev npm ci npm run build # Prevents multiple deployments from restarting PHP-FPM simultaneously touch /tmp/fpmlock 2>/dev/null || true ( flock -w 10 9 || exit 1 echo 'Restarting FPM...'; sudo -S service $FORGE_PHP_FPM reload ) 9