Skip to content
No description, website, or topics provided.
HTML JavaScript Dockerfile CSS
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.github
lib/config
public
views
.env-example
.gitignore
CONTRIBUTING.md
Dockerfile
LICENSE
README.md
index.js
jobtechdev.md
package-lock.json
package.json
prod-nginx.conf
stage-nginx.conf
supervisord.conf

README.md

alt text

A JobTech Project

AF Connect Demo

AF Connect Demo is an example website that demonstrates the use-case of pre-filling forms with CV data from AF Connect.

This website's runtime environment is Node.js and is built using the web application framework is Express.

The web pages/views are rendered using the EJS template engine and Bootstrap for responsive layouting.

Operating the website in development mode utilizes Nodemon to automatically restart the server upon source code changes.

Versions, current dev state and future

No versions yet.

Getting started

No getting started guidelines yet.

Prerequisites

You need Administrative privilege to make this change

Installation

Acquire the source code from this repository and install all dependencies using NPM.

git clone https://github.com/MagnumOpuses/af-connect-demo.git
cd af-connect-demo
npm install

Customized configuration

Listed below are methods of overriding the default configuration with custom properties.

Read move about environment configuration here: dotenv

Provide custom properties via configuration file
  1. Create an .env file at the root of the af-connect-demo directory with the following content.

    This .env file is ignored by the rules set in .gitignore, therefore in this file you may freely customizable the deployment to your own needs.

    HOST='localhost'
    PORT=3000
    

Test

Execute all test cases to ensure that all its features work as intended.

npm test

Deployment

Deploy the site with Docker in production mode

$ docker build --no-cache -t af-connect-demo .
$ docker run -p 3000:3000 af-connect-demo

Deploy the site with Docker in stage mode

$ docker build --build-arg ARG_BUILDNAME=stage --no-cache -t af-connect-demo .
$ docker run -p 3000:3000 af-connect-demo

Deploy the site in development mode

In development mode the Nodemon will automatically detect changes to the source code and restart the server.

npm run dev

Run the site on localhost

To run it on your local computer you have to add a (self signed) certificate and a private key and put those entries in to the .env file.

ex.

#Only Localhost config
LOCAL_PORT=443
PKEY = './cert_and_key/hacksparrow-key.pem'
SSLCERT = './cert_and_key/hacksparrow-cert.pem'
#Config
PORT=3000

Run with:

npm run local

Built with

Contributing

We would love if you'd like to help us build and improve this product for the benefit of everyone. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the Contributor Covenant code of conduct.

Any contributions, feedback and suggestions are more than welcome.

Please read our guidelines for contribution here.

License

Apache License 2.0

Acknowledgments

No acknowledgments yet.

You can’t perform that action at this time.