Can't stop helpers using localhost:2368 rather than 127.0.0.1:2368

Ghost 5.87.0 - Node 18.20.2

I’m using “url”: “http://127.0.0.1:2368/”, in the config.development.json file as localhost doesn’t work with node network adaptors and generates an ORB error. 127.0.0.1 works fine. However the ghost head helper is injecting the cards.min.css and cards.min.js using the localhost:2368 scheme. How do you stop the ghost head helper doing this I had assumed the config setting would be used by everything. I’ve had a look in the core code but its not obvious what is going in the ghost_head calls getAssetURL which I think is the root of the problem. Its also weird that just these links are using the scheme not in the config file. Any advice appreciated, thankyou.

Can you try restarting Ghost? getAssetUrl uses the url field from your config, from my recollection, so it should work.

I have done several ghost start and stops cycles but it still is using the localhost - I really can’t find where its getting it from. The other urls are all using the 127.0.0.1 in the config

The ordering of that content looks a little odd, the cards scripts/styles would normally appear before the member-attribution script and accent color styles.

Are you sure your theme isn’t providing its own assets?

1 Like

I’m using the source theme out of the box no mods - the helper js code seems to be loading these assets into it’s header stack but you are correct something weird if going on because if I modify the ghost_head.js code the asset links are not reflecting my changes. I’m not sure what is going on.