digitalcredentials / web-verifier-plus

VerifierPlus allows users to verify any supported digital academic credential
https://verifierplus.org
MIT License
7 stars 8 forks source link

VerifierPlus

This is a Next.js project bootstrapped with create-next-app.

Getting Started

Installing the Server

$ asdf install
$ npm i --legacy-peer-deps

Running the Server

$ yarn dev

This creates a dev server hosted at http://localhost:3000, open it in your browser while this is running in the command line

Editing the Page

Modify pages/index.tsx

API Routes

API routes can be accessed on http://localhost:3000/api/hello. This endpoint can be edited in pages/api/hello.ts.

Learn More

To learn more about Next.js, take a look at the following resources:

You can check out the Next.js GitHub repository - your feedback and contributions are welcome!

Deploy on Vercel

The easiest way to deploy your Next.js app is to use the Vercel Platform from the creators of Next.js.

Check out Next.js deployment documentation for more details.

MongoDB

This app currently requires MongoDB for its backend storage. To set up MongoDB for this app:

TROUBLESHOOTING: If the app can't connect to your Mongo Atlas collection, make sure that you've added your server IP to the whitelist for your Mongo Atlas account.

Docker

We've provided both a sample Dockerfile and two sample docker compose files.

The two docker compose files are identical except that the production version includes configuration for nginxproxy/nginx-proxy and nginxproxy/acme-companion.

Both compose files include a HEALTHCHECK configuration that monitors the running web app container. If the healthcheck returns 'unhealthy' three times in a row, the the willfarrell/autoheal service restarts the container.

You can also configure an SMTP email server, which the healtcheck will use to send emails to an email recipient whose address you can also configure. The healthcheck only sends emails if the check returns unhealthy.

And finally you can set a webhook on both the healtcheck and the autoheal, to which the same notifications of unhealthy status will be sent. We use the Slack webhook for this.

We've set the configuation values in the 'environment' sections of the compose file, but you can also use a .env file, like the .env.example we provide. The .env file may be more secure.