diff --git a/digitalocean/app_spec.go b/digitalocean/app_spec.go index 4c636249b..420830a5d 100644 --- a/digitalocean/app_spec.go +++ b/digitalocean/app_spec.go @@ -272,15 +272,6 @@ func appSpecComponentBase() map[string]*schema.Schema { Elem: appSpecEnvSchema(), Set: schema.HashResource(appSpecEnvSchema()), }, - "routes": { - Type: schema.TypeList, - Optional: true, - Computed: true, - MaxItems: 1, - Elem: &schema.Resource{ - Schema: appSpecRouteSchema(), - }, - }, "source_dir": { Type: schema.TypeString, Optional: true, @@ -335,6 +326,14 @@ func appSpecServicesSchema() *schema.Resource { Schema: appSpecImageSourceSchema(), }, }, + "routes": { + Type: schema.TypeList, + Optional: true, + Computed: true, + Elem: &schema.Resource{ + Schema: appSpecRouteSchema(), + }, + }, } for k, v := range appSpecComponentBase() { @@ -368,6 +367,14 @@ func appSpecStaticSiteSchema() *schema.Resource { Optional: true, Description: "The name of the document to use as the fallback for any requests to documents that are not found when serving this static site.", }, + "routes": { + Type: schema.TypeList, + Optional: true, + Computed: true, + Elem: &schema.Resource{ + Schema: appSpecRouteSchema(), + }, + }, } for k, v := range appSpecComponentBase() { diff --git a/digitalocean/resource_digitalocean_app_test.go b/digitalocean/resource_digitalocean_app_test.go index a3c59a205..87d87ca5e 100644 --- a/digitalocean/resource_digitalocean_app_test.go +++ b/digitalocean/resource_digitalocean_app_test.go @@ -618,6 +618,10 @@ resource "digitalocean_app" "foobar" { routes { path = "/" } + + routes { + path = "/foo" + } } } }`