You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
# Create database and user
sudo -u postgres psql
CREATE DATABASE ghost_production;
CREATE USER ghost WITH ENCRYPTED PASSWORD 'your_secure_password';
GRANT ALL PRIVILEGES ON DATABASE ghost_production TO ghost;\q
4. Environment Configuration
# Copy and edit environment file
cp .env.example .env
nano .env
# Update DB_PASSWORD and other credentials
5. Start Services
# Start Consul
sudo systemctl start consul
sudo systemctl enable consul
# Start Nomad in dev mode (for testing)
sudo nomad agent -dev
# Or for production:# sudo systemctl start nomad# sudo systemctl enable nomad
6. Deploy with Nomad
# Deploy Ghost CMS
nomad job run nomad/ghost-cms.nomad
# Check job status
nomad job status ghost-cms
# View logs
nomad alloc logs -f <alloc-id>
7. Alternative: Docker Compose (Quick Test)
# For immediate testing without Nomad
docker-compose -f docker-compose-production.yml up -d
# Check logs
docker-compose -f docker-compose-production.yml logs -f
Next Steps
Configure SSL/TLS with Let's Encrypt
Set up nginx reverse proxy
Configure backups
Set up monitoring (Prometheus/Grafana)
Migrate content from current Ghost instance
Troubleshooting
If Nomad fails to start, check: journalctl -u nomad -f
For database connection issues: sudo -u postgres psql -c "\l"
Docker permission issues: Log out and back in after adding to docker group
Important Files
nomad/ghost-cms.nomad - Nomad job specification
docker-compose-production.yml - Production Docker setup