Polypedia is a school project for polytech montpellier DO which goal is to make anyone able to deploy it's own library. Rather it is to make a small library with your friends or to make an online school library. Users can create accounts, upload and find pdf to download or consults them online !
lightweight config to create a polypedia full instance on any device you need.
To run this project you must have installed docker-compose and docker on your machine
git clone [email protected]:thomas-mauran/Polypedia.git
cd Polypedia
Once filled with the desired data remove the .example from both file names.
docker-compose up
this command will launch 3 containers working together :
-
the vue frontend container
-
the rest api backend container
-
the postgres container
To run this project you will need k3d and kubernetes tools. You might want to setup k9s to manage you k3d cluster easily.
git clone [email protected]:thomas-mauran/Polypedia.git
cd Polypedia
- You need to fill the api configmap with the desired values used to override the api .env
- The ingress controller is set with my own server url as example. Make sure you change those values according to your domain name and DNS.
- Those files are also using my example server domain names. Make sure you change those values according to your domain name and DNS.
- Use your own email address in those files.
k3d cluster create polypedia --k3s-arg "--no-deploy=traefik@server:*"
this command is going to setup a basic k3d cluster without any traefik server.
kubectl apply -f kube/
helm repo add ingress-nginx https://kubernetes.github.io/ingress-nginx
helm repo update
helm upgrade --install ingress-nginx ingress-nginx \
--repo https://kubernetes.github.io/ingress-nginx \
--namespace ingress-nginx --create-namespace
use docker ps to check the container id with the image "rancher/k3s:v1.24.4-k3s1"
docker ps
select the contained id and use it in the following command
docker exec -it <container id> sh
once you are in the file system
mkdir /mnt/data/polypedia/files/img
mkdir /mnt/data/polypedia/files/pdf
kubectl apply -f https://github.com/cert-manager/cert-manager/releases/download/v1.10.1/cert-manager.yaml
kubectl apply -f kube/
k3d node edit k3d-polypedia-serverlb --port-add 80:80
k3d node edit k3d-polypedia-serverlb --port-add 443:443
You can create issues if you are having troubles seting up the project !