Skip to content
No description, website, or topics provided.
JavaScript HTML Dockerfile CSS
Branch: master
Clone or download
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.github Initial project-meta files Sep 19, 2019
lib End-to-end code success Oct 3, 2019
public Enable windows close Oct 3, 2019
views End-to-end code success Oct 3, 2019
.gitignore
CONTRIBUTING.md Initial project-meta files Sep 19, 2019
Dockerfile Feature/inital code (#1) Sep 25, 2019
LICENSE Initial project-meta files Sep 19, 2019
README.md Feature/inital code (#1) Sep 25, 2019
index.js Fix retention url Oct 3, 2019
jobtechdev.md Initial project-meta files Sep 19, 2019
package-lock.json Feature/inital code (#1) Sep 25, 2019
package.json Feature/inital code (#1) Sep 25, 2019
prod-nginx.conf Feature/inital code (#1) Sep 25, 2019
stage-nginx.conf Feature/inital code (#1) Sep 25, 2019
supervisord.conf Feature/inital code (#1) Sep 25, 2019

README.md

alt text

A JobTech Project

AF Connect

The AF Connect service is responsible for obtaining informed consent from the user before any user data is transferred to third parties.

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 privileges

Installation

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

git clone https://github.com/MagnumOpuses/af-connect.git
cd af-connect
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 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.

    ##Only Localhost config
    LOCAL_PORT=443
    PKEY="./cert_and_key/hacksparrow-key.pem"
    SSLCERT="./cert_and_key/hacksparrow-cert.pem"
    #config for OpenShift deploy
    PORT=3000
    
  2. Create an folder name cert_and_key at the root of the af-connect directory containing the cerificate and private keys for Https connection.

    Download all the files from this link Centificate drive link and put them in the cert_and_key folder.

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

  3. Go to the host file of your machine

    For windows: (C:\Windows\System32\drivers\etc\hosts)
    For mac: (/private/etc/hosts)
    Replace the 'localhost' with 'demotest.arbetsformedlingen.se'
    

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 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.