To use Ghostable during deployments with Laravel Forge:
  1. Open the site you want to configure.
  2. Go to Environments → Site Environment.
  3. Add your Ghostable CI token to your existing .env file.
Example:
GHOSTABLE_CI_TOKEN="YOUR_TOKEN_HERE"
  1. Go to Deployments → Deployment Script.
  2. Add the Ghostable deploy command before your config:cache step.
Example:
if [ -f artisan ]; then
  # Existing Forge deployment commands...

  # Deploy environment variables from Ghostable
  $FORGE_PHP vendor/bin/ghostable deploy:forge

  # Rebuild Laravel config cache so new vars are applied
  $FORGE_PHP artisan config:cache
fi
:::note When you run ghostable during deployment, Ghostable merges its managed environment variables into your server’s existing .env file. • Existing keys are updated in place (your old values are replaced with the new Ghostable values). • New keys are added automatically. • Keys that Ghostable doesn’t manage are left untouched. After the deploy finishes, you’ll see these updates reflected inside the Forge dashboard under Environment → Site Environment. Forge reads directly from the .env file on your server, so any changes applied by Ghostable are visible there immediately. :::