HW06: Web Application Development Environment due Sat 07 Oct 23:59

\begin{purpose}
In this assignment you will install a Laravel application from ...
...group that
will be given permissions to work on the application.
\end{purpose}

The git repository https://tsergeant@bitbucket.org/tsergeant/sayit.git contains a working Laravel application called “SayIt!”. You should create a virtual host named sayit.yourdomain that maps to /var/www/live/sayit.yourdomain. You will have performed some of the steps below as part of the prelab assignment. Some steps you'll need to take:

  1. Update DNS to point the subdomain to your server.
  2. Clone the git repository to the appropriate directory and set permissions of various files/directories as need for a Laravel application.
  3. In the cloned and renamed repository run the command: composer update (which will download and create all the needed vendor files and packages).
  4. Create logs directory with appropriate permissions.
  5. Create an appropriate .conf file.
  6. Use cerbot to install an SSL certificate and create redirect code to push all traffic to https.
  7. Setup a MySQL database and database user for the application.
  8. Create tables by executing the appropriate commands found in database/sql/tables.sql: mysql sayit_db -u root -p < tables.sql. Copy .env.example file in Laravel to .env and then edit it as follows:
    1. Specify app name and url.
    2. From the command-line execute php artisan key:generate to create a random key.
    3. Set app environment to “staging”
    4. Specify database info.
    5. Comment out redis, mail, aws, and pusher statements.
  9. Use a combination of errors messages, apache log files, and Laravel log files to debug any issues.
  10. NOTE: Once the application is working you should be able to type a topic (in the second box) and then enter a message. When you click “Say It!” it should show the message in the “What's Been Said ...” section.

Establish the new, working Laravel application as a work environment for all users who are part of the webdev group. Some steps:

  1. Create a group called webdev that has access to the directory. All files should have webdev as group and new files in those folders should use that group. (logs folder and other folders that need apache write access are exceptions)

  2. Create a user webdude and add that user to webdev. Add your personal account to webdev too.

  3. Verify that Laravel logs and apache logs are writing successfully.