Deployment to netlify with custom domain still shows netlify in metadata

Hi,

I’ve build my website with hugo/academic and deployed to netlify with custom domain. However when opening the sourcecode of fede.sangati.me I see a number of href link to netlify.
How can I avoid this?

Please find the code repository here.

Thanks for the support,
Federico

You need to set the baseURL.

It is common to put your main baseURL into config.toml and then for the other environments (branches, pull requests), do something like this:

1 Like

Thanks @bep for the quick reply.

I already had baseURL, into config.toml in branch fede, see here.

Also, it’s not clear if the netlify.toml you specified should be put in main branch or fede branch.

Thanks again,
Federico

Put it in main (I don’t know what fede is …)

I’m a little confused by your project …

In

I see no config folder or config.toml …

Hi, sorry I wasn’t clear.
“fede” is a personal branch of the project which maps to fede.sangati.me subdomain which has config.toml (cannot put the direct link here, because the website tells me “Sorry you cannot post a link to that host.”).

The “main” branch is a simple landing page, and has no config.toml. Do you think that adding it there, would solve the problem?

Thanks again,
Federico

Hi @bep,
just to let you know that I’ve solved the problem manually by setting

[context.branch-deploy]
command = “hugo --gc --minify -b https : // fede . sangati . me”

in netlify.toml (spaces in url are placed to avoid discourse to complain about urls) since $DEPLOY_PRIME_URL didn’t work correctly (still not clear why).

Best,
Federico

This also seems to be related: