Skip to content

Custom domains

A repository can be served at the root of a domain that you control, so your builds resolve from https://maven.example.com/ instead of the Artifex address.

You need admin permission in the repository.

Connect a domain

To connect a domain, follow these steps:

  1. Open the repository and go to Domains.
  2. Click New domain.
  3. In the Hostname field, enter the host name, such as maven.example.com.
  4. Click Add domain.
  5. At your DNS provider, add a CNAME record for that host name pointing at the target that the page shows.
  6. If the page shows a verification record, add that TXT record as well.
  7. Click Check status until the status is Active.

A host name connects to one repository. Domains under soh.gg, and the Artifex address itself, can't be used.

The records

RecordNameValue
CNAMEThe host name that you addedThe target shown on the Domains page
TXTShown on the page when ownership has to be provedShown next to the name

A CNAME record can't sit at the root of a domain at most DNS providers, so use a subdomain such as maven.example.com. Some providers offer a flattened root record, which also works.

Status

StatusWhat it meansWhat to do
Pending DNSThe records aren't visible yetCheck the records and wait for them to propagate
Pending certificateThe records are visible and the certificate is being issuedWait, then check the status again
ActiveThe domain serves the repositoryPoint your builds at it
FailedVerification or certificate issuance didn't succeedRead the message on the page, correct the records, and check again

The certificate is issued for you; there's nothing to upload and nothing to renew. Each status change is recorded in the repository's activity.

Use the domain

Once the status is Active, the repository answers at the root of the domain:

xml
<repository>
  <id>codesoh</id>
  <url>https://maven.example.com/</url>
</repository>

Access is unchanged: a private repository on a custom domain still needs a token, and a public one still doesn't.

The Artifex address keeps working as well, so you can move builds over one at a time. Because the domain points at the repository and not at its URL name, renaming the repository doesn't break the domain.

Disconnect a domain

To disconnect a domain, follow these steps:

  1. Open the repository and go to Domains.
  2. In the domain's row, click Remove.

The domain stops serving the repository. Remove the CNAME record afterwards. Builds that still use the domain fail until you point them at another address.

Deleting a repository disconnects its domains.