Skip to content

lucascajal/blog

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Simple jekyll app to host my personal blog. Check it out here! (it may not always be up 😉).

Kubernetes deployment

The blog is hosted in a K8s cluster. You can see the deployment here. This cluster uses the image created by the Dockerfile, and mounts a volume with this repo cloned. A comanion container is also created to regularly pull the latest changes from this repo into the volume, so that whenever changes are made to this blog repo, they are reflected in the deployemnt, without needing to restart the pods.

To push the image to the container registry, run:

docker login registry.gitlab.com
docker build -t registry.gitlab.com/lucascajal1/k8s/blog:latest .
docker push registry.gitlab.com/lucascajal1/k8s/blog:latest

If you update the docker image, the K8s deployment will need to be updated

Local execution

To bring up the compose deployment, run:

sudo docker compose up --remove-orphans --force-recreate -d

Add the --build flag to force the image rebuild. The website takes a few seconds to be available when installing dependencies on runtime

And stop it with:

sudo docker compose down

You can access the logs while the containers are running with:

sudo docker compose logs -t

See more options in the docs

It would be cool to use tools like Elasticsearch in the future

About

Personal blog, available at blog.lucascajal.com

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors