microsoft / microsoft/aspire

Custom Domain should update bicep

Open
#11,271 2 comments 2 reactions 0 assignees View on GitHub
area-deployment azure
Dominant language
C#
Stars
6.3k
Forks
991
Avg merge
2d 15h
Merged PRs (30d)
196

Description

### Is there an existing issue for this?

- [x] I have searched the existing issues

### Describe the bug

When you have something like:

```cs
var api = builder.AddProject("myapiproject")
.PublishAsAzureContainerApp((cae, app) =>
{
app.ConfigureCustomDomain(customApiDomain, certificateName);
});

var frontend = builder.AddProject("myproject")
.WithReference(api);
```

The environment parameters uses:

```bicep
{
name: 'services__myapiproject__http__0'
value: 'http://myapiproject.${myproject_outputs_azure_container_apps_environment_default_domain}'
}
{
name: 'services__myapiproject__https__0'
value: 'https://myapiproject.${myproject_outputs_azure_container_apps_environment_default_domain}'
}
```

### Expected Behavior

This should instead update the resource to use the custom domain.

```bicep
{
name: 'services__myapiproject__http__0'
value: 'http://mycustomdomain.com'
}
{
name: 'services__myapiproject__https__0'
value: 'https://mycustomdomain.com'
}
```

### Steps To Reproduce

```cs
var api = builder.AddProject("myapiproject")
.PublishAsAzureContainerApp((cae, app) =>
{
app.ConfigureCustomDomain(customApiDomain, certificateName);
});

var frontend = builder.AddProject("myproject")
.WithReference(api);
```

### Exceptions (if any)

_No response_

### .NET Version info

_No response_

### Anything else?

_No response_

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.