Microservice sub-repository for injik/Broccoli user management engine
To develop Injik/Broccoli, the followings are required:
- Python related:
python3
,pip3
andpipenv
- MySQL / MariaDB
- Injik/did-core
You can prepare MariaDB and did-core with pre-defined
docker-compose.yaml
in here
MARIADB_HOST # MariaDB hostname
MARIADB_PORT # MariaDB port
MARIADB_USER # MariaDB username
MARIADB_PASSWORD # MariaDB password
MARIADB_DATABASE # MariaDB database name
RUNLEVEL # Run mode - one of `production` or `development`
DID_HOST # did-core service hostname
DID_PORT # did-core service port
JWT_SECR # JWT signing secret
FE_HOST # API server frontend host
FE_PORT # API server frontend host
ALLOWED_HOST # Allowed host
ALLOED_CORS_ORIGIN # CORS allowed origin
- Entering python virtual environment:
pipenv shell
- Install dependencies:
# In virtual environment (broccoli)
pipenv install
- Migrate to database
# In virtual environment (broccoli)
python manage.py makemigrations app
python manage.py makemigrations
python manage.py migrate app
python manage.py migrate
- Run
# In virtual environment (broccoli)
python manage.py runserver
As Injik/broccoli is designed to use as a Kubernetes pod, it's packaged as a Docker image.
You can find and use it in Docker hub
Here's example of how to run a container:
docker run -d \
-p 60072:7772 \
-h 0.0.0.0 \
-e ${environments ...} \
haeramkeem/brccoli
Also, docker-compose.yaml
file for easy-to-use container deployment is prepared
in here