Install and run OctoberCMS on Github Codespaces

Hi,

Could you please give me some instruction how could I install and run OctoberCMS application on Github Codespaces?

I’ve installed OCMS by composer on Codespaces, started by php artisan serve and used sqlite database, but when I open the site (on https://site.name.generated.by.codespaces:8000) the page loads but without any styling. If I open console log it says “ERR_CONNECTION_REFUSED” next to asset files.

Do you know how should I install or configure OCMS to run properly on Codespaces?

Thanks in advance for your help,
vimre

Hi @vimre,

It sounds like you are very close. For some reason, Codespaces is not serving any asset files (CSS, JS, images, etc); you may need to contact their support to find the reason. One thing to note, make sure you use the php artisan october:mirror command to make the server secure.

I hope this helps.

Hi Samuel,

Thanks for your reply. I was able to solve the issue without Github support.
I have noticed that the problem is that theme URL pointed to localhost even if I have changed app URL in .env file.

Solution:
I have changed LINK_POLICY value to force in .env file and now pages and theme files load correctly.

APP_URL=https://xyz-8000.preview.app.github.dev/
LINK_POLICY=force

P.s.: Thanks for the warning regarding the mirroring.

1 Like