You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've encountered a strange issue where files like CSS, JS, and icons are being served over HTTP instead of HTTPS, which shouldn’t happen.
In my .env file, I have APP_URL set to HTTPS. HTML files and SVG logos are returned correctly over HTTPS, but the problem occurs with JS, CSS, and favicon files—they are served over HTTP.
Additionally, form URLs are also rendered with HTTP, for example:
<form action="http://domain.com/admin/login">
It seems the issue is related to the application. Could you help me investigate this?
Thanks in advance!
The text was updated successfully, but these errors were encountered:
Added forceSchema to boot function in app/Providers/AppServiceProvider.php
# importing URL
use Illuminate\Support\Facades\URL;
# Added forceSchema to boot function
public function boot()
{
URL::forceScheme('https');
}
I don't think it's good, can we talk about why I had to do this?
I'm working on Krayin Docker installation to make Krayin easier to install, and everything works ok, but I have these issue with https only.
We are using asset() and route() helpers to generate correct URLs with the appropriate protocol (HTTP or HTTPS), the APP_URL in your .env file should be set correctly. Here's how to fix the issue:
Update the APP_URL in your .env file: Ensure that the APP_URL is using the correct protocol (either HTTP or HTTPS) depending on your environment.
For HTTPS:
APP_URL=https://your-domain.com
For HTTP:
APP_URL=http://your-domain.com
Clear the configuration cache, using below command, After updating the .env file, you need to clear the cache to apply the changes. Run the following command:
I did what u wrote above. I have https url in the env file
Also I cleared few times cache and everything.
Even destroyed a docker container and created a new one.
Hi,
I've encountered a strange issue where files like CSS, JS, and icons are being served over HTTP instead of HTTPS, which shouldn’t happen.
In my .env file, I have APP_URL set to HTTPS. HTML files and SVG logos are returned correctly over HTTPS, but the problem occurs with JS, CSS, and favicon files—they are served over HTTP.
Additionally, form URLs are also rendered with HTTP, for example:
<form action="http://domain.com/admin/login">
It seems the issue is related to the application. Could you help me investigate this?
Thanks in advance!
The text was updated successfully, but these errors were encountered: