2 Respuestas
- Más nuevo
- Más votos
- Más comentarios
1
After playing around with it, I was able to get a successful redirect by editing opt/bitnami/apache/conf/vhosts/00_status-vhost.conf
with your above code:
Define CUSTOM_DOMAIN_NAME "example.com"
RewriteEngine On
<VirtualHost *:80 *:443>
ServerName www.example.com
RewriteRule ^/(.*) https://${CUSTOM_DOMAIN_NAME}/$1 [R=301,L]
</VirtualHost>
All seems to be working now! Thank you!
respondido hace 3 meses
1
Hello.
Can I redirect if I configure Apache as below?(After making the settings, restart Apache.)
Define CUSTOM_DOMAIN_NAME "example.com"
RewriteEngine On
<VirtualHost *:80 *:443>
ServerName www.example.com
RewriteRule ^/(.*) https://${CUSTOM_DOMAIN_NAME}/$1 [R=301,L]
</VirtualHost>
Contenido relevante
- ¿Cómo puedo restablecer la contraseña de inicio de sesión de WordPress en la instancia de Lightsail?OFICIAL DE AWSActualizada hace un año
- OFICIAL DE AWSActualizada hace un año
- OFICIAL DE AWSActualizada hace 3 años
- OFICIAL DE AWSActualizada hace 9 meses
Thanks for the suggestion, but unfortunately, it doesn't seem to have worked.
I edited this file
/opt/bitnami/apache/conf/httpd.conf
and added the virtual host code (after swapping out my domain for example.com), saved the file, restarted Apache, reset my CloudFront cache too for good measure, and no luck. I've tried from multiple browsers/computers too, double checked for redirects using a 3rd party, and no dice.Is that the correct file?