This project uses pythons built-in venv
to manage dependencies. Once the venv
is activated, one can also just use pip install -r requirements.txt
.
Make sure to be in the
django_project
directory when running venv commands
cd django_project
MacOS/Linux
python3 -m venv myenv
source myenv/bin/activate
pip install -r requirements.txt
Windows
python -m venv myenv
.\myenv\Scripts\activate
pip install -r requirements.txt
- Set up a Google Gemini API account and generate an API key.
- create a
.env
file in thedjango_project/project_230/dictionary
directory - Set the
GOOGLE_API_KEY
environment variable to their API key.
note the
GOOGLE_API_KEY
must be in the.env
file to use the app. and the API key should also be in "string" format.
Example .env
file:
# .env
GOOGLE_API_KEY="your_api_key_here"
- used for the Java microservice
Make sure to be in the
HashTableService
directory when running maven commands Make sure maven is installed
mvn --version
if not installed, install maven from here
cd HashTableService
mvn clean compile
NOTE: make sure that the current java version is supported by the maven
pom.xml
file in the
<properties>
<java.version>example_version</java.version>
</properties>
To check the current java version, run
java -version
Start the maven service
mvn spring-boot:run
Activate the python
venv
cd django_project
.\myenv\Scripts\activate
Start the django server
cd project_230
python manage.py runserver
In a different Terminal, Start the maven service
cd HashTableService
mvn spring-boot:run