Skip to content

Arslankhan123/Frontend

Repository files navigation

giessdenkiez.de

Netlify Status Node.js CI love badge citylab badge

Source repo for giessdenkiez.de project by Technologiestiftung Berlin and CityLAB Berlin.

Used Resources

This is a short list of the things that are needed for running this project yourselves.

  • Netlify.com for hosting
  • vercel.com for serverless functions to interact with the database
  • AWS RDS Postgres
  • auth0.com + vercel.com for user management
  • AWS Fargate python script in docker for rain data aggreagation from Deutsche Wetterdientst (DWD) + Mapbox API for creating vector tiles for mobile

These are the related repos:

Below is a rough sketch of the architecture:

software architecture

Development

Duplicate the .env.sample file, rename it .env and adapt the values to your needs.

Set the environment variable BUILD_TARGET in the netlify.toml, in your .env file, in the build contexts or via the npm-scripts. You can use this to build the demo mode.

Make sure to set your NODE_ENV to either test, development or production


Start the project via

npm start

Deployment

To deploy the frontend we use netlify.com

Take a look at the netlify.toml for the the used commands to deploy it. Make sure to set all the variables you have in your .env file in the environment section of your projects build & deploy settings.

Demo Mode

The purpose of the demo mode (created if you set the env variable BUILD_TARGET=DEMO) is to run this application in the exhibition of the CityLAB Berlin. In this mode all requests to the api get mocked responses except for the get tree by id and get all trees. It uses the msw (Mock Service Worker) module underneath to handle API requests and does a module replacement for the auth0-spa-js library wrapper with webpack.

To start the DEMO mode run.

npm run demo

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published