The project is configured using environment variables. Please set this values in your shell before running any of the commands below:
- REACT_APP_API_URL: the url where the API server is listening at, e.g.
http://localhost:8080/api/get_json?departamento=10
- TEKOPORA: the ID of the Google spreadsheet were Tekoporã data is available. Currently `1C4YS7tiQxAZ8vH4A46HpSc03xR0PVRA74itIcUdjYjQ
- ALMUERZO: the ID of the Google spreadsheet were Tekoporã data is available. Currently
18NgsyLY-BVR9lQ48oDs-2tf3QeQYxSGF0ywf1aW661c
- TECHO: the ID of the Google spreadsheet were Tekoporã data is available. Currently
11jSqn_p_uXK3xHntUmjws_Eaka1ei3CNyhZ9VRpKJ-w
- FUNDACION: the ID of the Google spreadsheet were Tekoporã data is available. Currently
1TnF5CaBj8EQLa8JbNMVnxYMP6W2YGG56mVDg6PeabLo
In the project directory, you can run:
Runs the app in the development mode.
Open http://localhost:3000 to view it in the browser.
The page will reload if you make edits.
You will also see any lint errors in the console.
Launches the test runner in the interactive watch mode.
See the section about running tests for more information.
Builds the app for production to the build
folder.
It correctly bundles React in production mode and optimizes the build for the best performance.
The build is minified and the filenames include the hashes.
Your app is ready to be deployed!
See the section about deployment for more information.
For Python=3.7
To use the api you should create a virtual environment with python, install virtualenv with pip
pip install virtualenv
Then redirect yourself to the flask_api folder and create an env folder
cd flask_api/ && mkdir env
Last, create the virtual environment and install the requirements
python -m venv env && pip install -r requirements.txt
Create a folder named geojson_data and download the geojson file available here in it, then execute the script.
python geojson_api.py
Install docker (minimun 17.05) and docker-compose in your local environment.
Execute
docker-compose build
docker-compose up -d
For production deployment you should change the localhost and port 8080 with your port and servername int the nginx_config files.