-
Notifications
You must be signed in to change notification settings - Fork 1
/
main.tf
42 lines (34 loc) · 775 Bytes
/
main.tf
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
terraform {
required_providers {
heroku = {
source = "heroku/heroku"
version = "4.6.0"
}
}
}
variable "example_app_name" {
description = "Name of the Heroku app provisioned as an example"
}
resource "heroku_app" "example" {
name = var.example_app_name
region = "us"
}
resource "heroku_build" "example" {
app = heroku_app.example.name
source {
path = "app/"
}
}
resource "heroku_formation" "example" {
app = heroku_app.example.name
type = "web"
quantity = 1
size = "Standard-1x"
depends_on = [heroku_build.example]
}
output "example_app_url" {
value = "https://${heroku_app.example.name}.herokuapp.com"
}
output "example_app_build_log_url" {
value = heroku_build.example.output_stream_url
}