pcs-website-test/pcs-setup.txt

55 lines
1.4 KiB
Text

New Lektor Approach:
build your lektor docker container:
docker build -t lektorcontainer lektor/docker
run your lektor server
docker run -it -v ${PWD}/lektor/lektordata:/opt/lektor -p 5000:5000 lektorcontainer lektor serve -h 0.0.0.0
access it with your browser:
http://localhost:5000
thats all!
To update "Termine" page run:
docker run -v ${PWD}/lektor/lektordata:/opt/lektor lektorcontainer /bin/bash -c "/opt/lektor/scripts/calendar-fetcher.sh 'https://backoffice.pc-stammertal.ch/remote.php/dav/public-calendars/RqLX5wj25aY6cpnP?export' > /opt/lektor/project/content/termine/contents.lr"
building the website for deployment is:
docker run -it -v ${PWD}/lektor/lektordata:/opt/lektor -p 5000:5000 lektorcontainer lektor build -O /opt/lektor/output
deployemnt can then be found in:
lektor/lektordata/output
If you would like to start from scratch you would delete all contents in lektordata/project and run
docker run -it -v ${PWD}/lektor/lektordata:/opt/lektor lektorcontainer lektor quickstart
Old Hugo Approach:
hugo new site pcs --format yaml
cd pcs
git init
hugo mod init pcsmod
hugo mod get github.com/imfing/hextra
add the following to hugo.yaml:
module:
imports:
- path: github.com/imfing/hextra
hugo new content/_index.md
hugo new content/docs/_index.md
hugo server --buildDrafts --disableFastRender