Open Spone opened 1 year ago
By default Parklife makes its mock requests to http://example.com
but you can change this in your Parkfile:
Parklife.application.config.base = 'https://www.benpickles.com'
Or by passing a --base
to bin/static-build
at runtime - as in the generated GitHub Actions workflow:
Now your app will think it's serving an https request for your chosen domain and won't respond with a 301.
Configuring the correct base for your build allows you to use full URLs where necessary - in things like feed links and social media/Open Graph URLs.
I was trying out parklife in a Rails project where
config/production.rb
contains:In this case, I got:
When changing the config option to
false
, I was able to runstatic-build
.Do you think there's a way to prevent this? (or maybe just add a notice in the README)