Django database system for devops assignment test jenkins-test2
git clone https://github.com/pauliee99/movie-database.git
python3 -m venv myvenv
source myvenv/bin/activate
pip install -r requirements.txt
cd database
cp database/.env.example database/.env
Edit database/.env to define the MySQL Database you have just created
SECRET_KEY='test123'
DB_NAME='name of database created'
DB_USER='your db username'
DB_PASSWORD='your db password'
DB_HOST='the host db is running'
DB_PORT='the port e.g. 3306 by default for MySQL'
Apply the database migrations running
python manage.py makemigrations
python manage.py migrate
Create a superuser (admin) running
python manage.py createsuperuser
and fill the required fields
python manage.py runserver 3000
First, log in using your superuser credentials: Link
Jenkinsfile: describes the procedure so Jenkins server is able to deploy the component using Ansible
docker.Jenkinsfile: describes the procedure so Jenkins server is able to deploy the component in Docker environment (VM)
nonroot.Dockerfile: describes the steps so the docker image can be built without being root users