Dec 15, 2024
0
Level 1
My laravel 11 assets files not found when deploy to Oracle
I have deployed laravel 11 app to Oracle Cloud when I connect Domain to project my assets file don't work using https
https://couponalyom.com/backend/assets/css/app.min.css
but working like this
http://couponalyom.com/backend/assets/css/app.min.css
this is for backend folder and build folder inside public directory
this is my coupons.conf file
<VirtualHost *:80>
ServerAdmin [email protected]
DocumentRoot /home/coupons/code/public
ServerName couponalyom.com
DirectoryIndex index.php
AddDefaultCharset UTF-8
<IfModule mod_proxy_fcgi.c>
<FilesMatch \.php$>
SetHandler "proxy:unix:/var/run/php/php8.3-fpm.sock|fcgi://localhost"
</FilesMatch>
</IfModule>
<Directory "/home/coupons/code">
AllowOverride All
Require all granted
Options Indexes FollowSymLinks
<FilesMatch "^\.(env|git|gitignore|htpasswd)$">
Require all denied
</FilesMatch>
AuthType Basic
AuthName "Restricted Access"
AuthUserFile /etc/apache2/.htpasswd
Require valid-user
</Directory>
RewriteCond %{SERVER_NAME} =couponalyom.com
RewriteRule ^ https://%{SERVER_NAME}%{REQUEST_URI} [END,NE,R=permanent]
</VirtualHost>
<VirtualHost *:443>
ServerAdmin [email protected]
DocumentRoot /home/coupons/code/public
ServerName couponalyom.com
DirectoryIndex index.php
SSLEngine on
SSLCertificateFile /etc/letsencrypt/live/couponalyom.com/cert.pem
SSLCertificateKeyFile /etc/letsencrypt/live/couponalyom.com/privkey.pem
SSLCertificateChainFile /etc/letsencrypt/live/couponalyom.com/chain.pem
RewriteEngine On
RewriteCond %{HTTPS} off
RewriteRule ^ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]
AddDefaultCharset UTF-8
<IfModule mod_proxy_fcgi.c>
<FilesMatch \.php$>
SetHandler "proxy:unix:/var/run/php/php8.3-fpm.sock|fcgi://localhost"
</FilesMatch>
</IfModule>
<Directory "/home/coupons/code">
AllowOverride All
Require all granted
Options Indexes FollowSymLinks
<FilesMatch "^\.(env|git|gitignore|htpasswd)$">
Require all denied
</FilesMatch>
AuthType Basic
AuthName "Restricted Access"
AuthUserFile /etc/apache2/.htpasswd
Require valid-user
</Directory>
</VirtualHost>
Please or to participate in this conversation.