![]() |
aws lightsail missconfiguration - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: CodeIgniter 4 (https://forum.codeigniter.com/forumdisplay.php?fid=28) +--- Forum: CodeIgniter 4 Support (https://forum.codeigniter.com/forumdisplay.php?fid=30) +--- Thread: aws lightsail missconfiguration (/showthread.php?tid=77065) |
aws lightsail missconfiguration - alex-cross - 07-16-2020 Hi everybody! I'm always been practiced with localhost sites to test ci4, now i have a project called www.mediestad.com, but I can't setup CI4 in AWSLighsail server. If you go to the address you will see the directory www.mediestad.com/mediestad/public send the error page.: DNS_PROBE_FINISHED_NXDOMAIN This is my apache site definition ubuntu@ip-172-26-10-139:~$ cat /etc/apache2/sites-available/www.mediestad.com.conf <VirtualHost *:80> ServerName www.mediestad.com <Directory /var/www/html/mediestad/public/> Options Indexes FollowSymLinks MultiViews AllowOverride All Require all granted </Directory> ErrorLog /var/log/apache2/mediestad.local_error.log CustomLog /var/log/apache2/mediestad.local_requests.log combined </VirtualHost> the site is enabled lrwxrwxrwx 1 root root 41 Jul 16 22:28 www.mediestad.com.conf -> ../sites-available/www.mediestad.com.conf The .env file #-------------------------------------------------------------------- # ENVIRONMENT #-------------------------------------------------------------------- CI_ENVIRONMENT = development #-------------------------------------------------------------------- # APP #-------------------------------------------------------------------- app.baseURL = 'http://www.mediestad.com' # app.forceGlobalSecureRequests = false -------------------------------------------------------------------------------------------------------- The file /app/Config/App.php public $baseURL = 'http://www.mediestad.com/'; If anyone have any idea about this issue RE: aws lightsail missconfiguration - tgix - 07-17-2020 Thanks for giving me the opportunity to try LightSail, been using AWS for many many years, but haven't tried LightSail. Without you giving much information about you setup I created a CI4 lightsail instance in 5 minutes following these steps: Platform: Linux/Unix Blueprint: OS Only / Amazon Linux Instance type: 1GB RAM instance SSH to the host and then follow the instructions from AWS, just Step 1 is OK for this test: https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/install-LAMP.html (skip point 6 on lightsail since the instance is wide-open anyway) Install CI4 dependencies: Code: sudo yum install php72-intl php72-mbstring Reboot instance. Code: sudo /sbin/init 6 Test IP address in browser to see the Apache Test Page. SSH back in to host and create directory for CI4: Code: sudo mkdir -p /var/www/ci4 Install composer in /home/ec2-user: Code: cd ~ Install CI4 appstarter: Code: cd /var/www/ci4 Change into the CI4 directory: Code: cd /var/www/ci4/test Change permissions for writeable: Code: chmod -R 777 /var/www/ci4/test/writable/ Configure the env file by setting CI_ENVIRONMENT and app.baseURL Code: cp env .env Modifications to .env: Code: #-------------------------------------------------------------------- Edit apache config and change DocumentRoot to the appstarter directory: Code: sudo nano /etc/httpd/conf/httpd.conf Change line with DocumentRoot to: Code: DocumentRoot "/var/www/ci4/test/public" Restart apache: Code: sudo /etc/init.d/httpd restart Go to IP-address to see CI4's welcome page. RE: aws lightsail missconfiguration - alex-cross - 07-17-2020 (07-17-2020, 12:23 AM)tgix Wrote: Thanks for giving me the opportunity to try LightSail, been using AWS for many many years, but haven't tried LightSail. Without you giving much information about you setup I created a CI4 lightsail instance in 5 minutes following these steps: |