Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ description: Learn about the aspire new command and its usage. This command crea
import AsciinemaPlayer from '@components/AsciinemaPlayer.astro';

import Include from '@components/Include.astro';
import LearnMore from '@components/LearnMore.astro';
import { Aside } from '@astrojs/starlight/components';

## Name
Expand Down Expand Up @@ -33,6 +34,50 @@ This command defaults to **interactive** mode. When executed without any options
with Aspire templates as an alternative for project creation.
</Aside>

## Interactive prompts

When running `aspire new` in interactive mode, the command asks one or more questions before generating the project. The available prompts depend on the template and options you provide.

### Use \*.dev.localhost URLs?

During project creation, you may be prompted:

> **Use \*.dev.localhost URLs?**

This prompt determines whether the generated launch profile configures your Aspire services to be accessible via `*.dev.localhost` wildcard subdomain URLs (for example, `https://myservice.dev.localhost`) instead of standard `http://localhost` with port numbers.

Comment on lines +47 to +48
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nit: The Safari caveat is mentioned here and again in the <Aside> on line 73. Consider dropping the inline mention from this paragraph and relying solely on the callout — it's more prominent and avoids saying the same thing twice.

Suggested change
This prompt determines whether the generated launch profile configures your Aspire services to be accessible via `*.dev.localhost` wildcard subdomain URLs (for example, `https://myservice.dev.localhost`) instead of standard `http://localhost` with port numbers.
`*.dev.localhost` is a wildcard subdomain pattern that resolves to your local machine (`127.0.0.1` or `::1`) in most modern browsers without additional DNS configuration. The ASP.NET Core HTTPS development certificate includes `*.dev.localhost` as a Subject Alternative Name (SAN), so browsers trust connections to any subdomain under `*.dev.localhost` when the certificate is installed and trusted.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nit: This paragraph packs DNS resolution behavior, browser support exceptions, and HTTPS certificate details into one block. Consider splitting it into two paragraphs — one for DNS/browser resolution and one for the certificate trust story — to make it easier to scan.

#### What are \*.dev.localhost URLs?
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is missing lots of nuance about what these are and aren't. The biggest being that it only works in browsers.


`*.dev.localhost` is a wildcard subdomain pattern that resolves to your local machine (`127.0.0.1` or `::1`) in most modern browsers without additional DNS configuration. Safari on macOS is an exception and may require hosts-file entries for `*.dev.localhost` subdomains. The ASP.NET Core HTTPS development certificate includes `*.dev.localhost` as a Subject Alternative Name (SAN), so browsers trust connections to any subdomain under `*.dev.localhost` when the certificate is installed and trusted.

#### Yes — use \*.dev.localhost URLs

Choosing **Yes** configures the generated project so that each service gets a unique subdomain URL such as `https://myservice.dev.localhost`. This option:

- Enables HTTPS for all services from the start, leveraging the wildcard development certificate.
- Gives each service its own origin, which prevents cookie and authentication token collisions between services running on the same machine.
Comment thread
IEvangelist marked this conversation as resolved.
- More closely mirrors a production setup where services are hosted on separate (sub)domains.

**Prerequisite:** The ASP.NET Core HTTPS development certificate must be installed and trusted on your machine. Run the following command if you haven't done so already:
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is true, but I would just say developer cert and move all of the details about the cert to the cert article.


```bash title="Aspire CLI"
aspire certs trust
```

<LearnMore>
[Command reference: `aspire certs trust`](../aspire-certs-trust/)
</LearnMore>

<Aside type="note">
Safari on macOS does not resolve `*.dev.localhost` subdomains to
`127.0.0.1` by default. If you use Safari, choose **No** or add an entry to
your hosts file.
</Aside>

#### No — use standard localhost URLs (default)
Comment on lines +73 to +77
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nit: "add an entry to your hosts file" leaves the reader guessing what the entry should be. A brief inline example would make this immediately actionable:

Suggested change
`127.0.0.1` by default. If you use Safari, choose **No** or add an entry to
your hosts file.
</Aside>
#### No — use standard localhost URLs (default)
<Aside type="note">
Safari on macOS does not resolve `*.dev.localhost` subdomains to
`127.0.0.1` by default. If you use Safari, choose **No** or add entries to
your hosts file (for example, `127.0.0.1 myservice.dev.localhost`).
</Aside>


Choosing **No** (the default) configures services with standard `http://localhost:<port>` addresses. This option requires no certificate setup and works in all browsers and tools without additional configuration.

## Options

The following options are available:
Expand Down
Loading