Using Django to handle login / authentication / db / email etc. Then creating "normal" endpoints for JS/JSframeworks to manipulate/get data from django Models. This means you will need to be logged inn through the Django backend.
The application can be found here.
function getCookie(name) {
Put microcicd.py & redeploy.sh in your git project.
Run git config credential.helper store
as the (systemd) user that will run the script.
Edit the files with user/repo info and move them in to possision.
Enable --now microcicd.service and update your master brach.
Disclaimer, security or tests have not been considered here, I needed something fast and dirty. Webhooks is the prefered method. As well as tokens for AUTH.
I have always found systemd to be a reliable manager for my docker containers, here is a few examples that should be enough to get the general idea.
I thought a symbiotic example would be best as that's about as complicated as it gets.
Some basic systemd usage skills like how to use systemctl
and deamon-reload
are expeted.
(Remember NOT! to deamonize the containers! -d --deamonize
in the docker command.)