This repository was archived by the owner on May 16, 2023. It is now read-only.
forked from supabase/postgres
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathamazon.json
More file actions
62 lines (62 loc) · 1.56 KB
/
amazon.json
File metadata and controls
62 lines (62 loc) · 1.56 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
{
"variables": {
"profile": "{{env `AWS_PROFILE`}}"
},
"builders": [
{
"type": "amazon-ebs",
"profile": "{{user `profile`}}",
"region": "{{user `region`}}",
"ami_regions": "{{user `ami_regions`}}",
"source_ami": "{{user `ubuntu-2004`}}",
"instance_type": "{{user `instance-type`}}",
"ssh_username": "ubuntu",
"ami_name": "supabase-postgres-{{user `postgres-version`}}",
"tags": {
"environment": "{{user `environment`}}",
"appType": "postgres",
"creator": "packer"
},
"run_tags": {
"creator": "packer"
},
"snapshot_tags": {
"creator": "packer"
},
"run_volume_tags": {
"creator": "packer"
},
"launch_block_device_mappings": [
{
"device_name": "/dev/sda1",
"volume_size": 16,
"volume_type": "gp3",
"delete_on_termination": true
}
]
}
],
"provisioners": [
{
"type": "shell",
"inline": [
"while [ ! -f /var/lib/cloud/instance/boot-finished ]; do echo 'Waiting for cloud-init...'; sleep 1; done"
]
},
{
"type": "ansible",
"user": "ubuntu",
"playbook_file": "ansible/playbook.yml",
"extra_arguments": "--skip-tags,install-postgrest"
},
{
"execute_command": "echo 'packer' | sudo -S sh -c '{{ .Vars }} {{ .Path }}'",
"type": "shell",
"scripts": [
"scripts/02-credentials_cleanup.sh",
"scripts/90-cleanup.sh",
"scripts/91-log_cleanup.sh"
]
}
]
}