Skip to content

theclayton/the-archive-backend

Repository files navigation

The Archive Backend

The Archive Backend is used to display your technology portfolio. This project contains a RESTful API, running Express. MongoDB is used to store all Archive data, except for file uploads, which are stored on the server (This will be moved somewhere more scalable, eventually). There is an accompanying frontend project built using Angular.

Prerequisites

  • Set environment variables in the .env file.
  • You will need access to a MongoDB instance, you can quickly set one up with docker: docker run --name mongodb -d -p 27017:27017 mongo:6.0.13. Note you will need to setup Docker networking if running both MongoDB and server containers on the same machine.
  • You can either run the server using Docker or using the node server.js command.

Getting started

Install dependencies by running:

npm i

Build docker container:

npm run build

Run docker container:

npm run start

The server should now be listening on port 3000. You can ensure this by using the healthcheck endpoint:

curl 'http://localhost:3000/healthcheck'

Should return status 200 with text body containing OK

Basic Usage

On startup, a new admin user should have been created with the following credentials:

email: admin@flaresoftware.com
password: password

You can use these credentials to login and create other users, create and anage projects, etc.

About

ExpressJS backend API for an Angular frontend. A resource for viewing projects.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published