- Generate your own TLS/SSL certificate
- Make "certs" directory in ./lib.
- Place the certificates you generate into "certs" directory.
- One labelled ['web'] on port 8000 with no TLS configured.
- The other labelled ['web-tls'] on port 8001 will use TLS.
Configure this connection to use the ssl/tls certificates you just generated
and placed in ./lib/certs
Configure the application to always use TLS [Transport Layer Security] (http://en.wikipedia.org/wiki/Transport_Layer_Security).
Every http request should be redirected to https.
Two references:
- Make a new point in the home plugin called: "login"
- Make login route display view template named login.html.
- Use partials to display the login form
- make a directory inside of the ./views called partials
- configure the home plugin to use the ./views/partials directory to load partials from.
- In ./views/partials/ directory make a file named form.html.
- form should have two inputs one type="text" named "username" and the second type="password" named "password".
- form should have one submission button with text value "Login".
- Inside login.html template load the partial file named "form.html"
- In ./views/partials/ directory make a file named form.html.
- Make directory in root of project called "assets".
- Inside the assets directory, make three directories:
"styles" for css, "scripts" for JS scripts,
"images" for project images.- Place Hapi University logo into the images directory
and display it on the home page (home.html). (image is in the repo ./images/logo.png) - Place a CSS file in the stylesheets directory (styles).
Name css file styles.css:- Make one simple style:
h3 { font-size: 24px; font-weight: bold; } - Use the stylesheet in home.html. Make a title inside h3 tags.
- Make one simple style:
- Make a script named login.js and put in ./assets/scripts
- Make this script print a console message to the browser when the form button is clicked.
- In the home plugin configure the application to serve these static assets.
- Make a login link in home.html that links to the login route.
- Place Hapi University logo into the images directory
- server certificate configuration at npm newww
- Original assignment6