These are my Packer templates for deploying Laravel applications on Digital Ocean infrastructure.
Installs:
- PHP 8
- Nginx
- MySQL
- Redis
- Memcached
- Postfix
- Certbot
- Supervisor
Create a variables.json
file with your Digital Ocean API token:
{
"do_api_token": "YOUR_DIGITAL_OCEAN_API_TOKEN_HERE"
}
To build a Digital Ocean droplet snapshot in nyc3
:
brew upgrade packer
packer plugins install github.com/digitalocean/digitalocean
packer validate -var-file=variables.json laravel-lemp/template.json
packer build -var-file=variables.json laravel-lemp/template.json
Then, create a droplet from the resulting snapshot.
Links and guides that helped inform this setup: