@Castopod Why do you guys hard-code localhost:8080 into castopod? That seems rather odd, I shouldn't need to edit application code directly to get something to install correctly. Especially since your documentation makes no mention of this.

@tek_dmn You shouldn't update the code.
The .env file is where the home url is defined.

Follow

@tek_dmn When you run the installation wizard it asks you your domain name, then writes it down to the .env file.

@tek_dmn We'll update the documentation to make that clearer.
Thank you for your feedback.

@Castopod When I run the installation wizard it hangs for 5 seconds and comes back with https://localhost:8080 is unreachable

That's not the port apache is on
That's not the hostname either

@Castopod

I can't run the installation wizard, for some reason, until there's a proper domain name attached, something I generally don't do until after a container is fully provisioned and configured. Using http://192.168.5.171/cp-install redirects to localhost:8080 and sets the HSTS header, something that is discouraged on a plain HTTP connection.

@tek_dmn @Castopod
Castopod forces https because it is a requirement, and by default the base url is set to localhost:8080, it's meant to be overwritten anyways during install (in your .env).

In your case, as you haven't setup a domain name with https yet, you can add the following in your .env to prevent the https redirect and continue install:

app.forceGlobalSecureRequests=false

You'll have to remove it after attaching a domain name with https.

@yassinedoghri @Castopod Okay then, that should be documented. Not everyone has a completely configured system before setup.

I'm still confused on why they use port 8080, which given their own install instructions, wouldn't be applicable in the first place.

@tek_dmn @Castopod
We use CodeIgniter4 under the hood which sets localhost:8080 by default for development purposes.

As we don't know what the user's baseURL would be, we just kept it at that.

In practice, it doesn't pose too much of an issue to be honest.

What would you put instead?

@yassinedoghri @Castopod just seems to be the logical option would be localhost no port, that way if anything it redirects you to itself, and not a (by the docs) unused port.

@yassinedoghri @Castopod to be clear, I don't imagine it would cause much of an issue in practice. I'm probably just an edge case that wasn't thought of, I get that.

I don't assign domain names and everything to a guest that's just been created, I'll create it, do any package updates, grab the address from DHCP, install / configure whatever software I'm applying, and once it's been set up, admin accounts are created and passwords set, and installer pages are locked out from the webserver, then I assign a domain and mapping from the frontend reverse proxy (which also handles TLS termination for the domains)

I know. It's not standard.

@yassinedoghri @Castopod While I'm here, small side note: I see TLS is required for email too.

This requires me to add a /etc/hosts entry 😆
I appreciate the secure by default idea here, but there's some environments that need workarounds for it (like when your internal DNS server is dumb for some reason and won't so split horizon DNS properly)

Sign in to participate in the conversation
Castopod

designed and built by and for podcasts lovers