Wivik / devops-solutions-map

A tool displaying your DevOps solution map and their adoption for each step of the loop. Demo available on GitHub Page !
https://wivik.github.io/devops-solutions-map/
MIT License
178 stars 19 forks source link

Can this generate a static site? #3

Closed NickLarsenNZ closed 1 year ago

NickLarsenNZ commented 1 year ago

I think it would be useful to optionally produce the static output so that it doesn't have to be hosted.

An example being a github page.

Wivik commented 1 year ago

Thanks for the idea ! I'll look at it.

Wivik commented 1 year ago

First result available in the following branch feat/static-website .

Published on GitHub Pages for testing : https://wivik.github.io/devops-solutions-map/

There is an issue with the "Open All" button that doesn't work since its action was managed by Flask, I'll have to see how to handle that.

Two ways to generate :

  1. With the code directly
python app.py --freeze [--freezer-base-url http://mywebsite/folder]

Base URL arg is required in case the website is not at the root of the domain, GitHub Pages typically. If not, the argument is not necessary. It can be verified using Python's builtin web server :

cd build
python -m http.server 8080

Then go to http://localhost:8080

  1. Using the container image, it's a kind of dirty for now because I've had some permissions issues
mkdir build
chmod 777 build # :vomiting_face: 
podman run --rm -v ./build:/devops-map/build:Z ghcr.io/wivik...... --freeze

I still have to update the documentation and ensure I've not broken anything, but so far so good :+1: