~admicos/ecmelberk.com unlisted

ecmelberk.com/.build.yml -rw-r--r-- 1.0 KiB View raw
904796ebEcmel Berk Canlier Serve Gemini content alongside HTTP 10 days ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
image: debian/stable
packages:
    - git
    - openssh-client
    - wget
    - python3-pip
secrets:
    - 413d9ffe-9eb7-4696-91c6-a75887451779
sources:
    - https://git.sr.ht/~admicos/ecmelberk.com
tasks:
    - setup: |
        wget https://github.com/gohugoio/hugo/releases/download/v0.70.0/hugo_extended_0.70.0_Linux-64bit.tar.gz
        tar zxvf hugo*.tar.gz

        pip3 install --user -r ecmelberk.com/_gemini/requirements.txt

        ssh-keyscan -t rsa,dsa -H ecmelberk.com >> ~/.ssh/known_hosts
        git clone pages@ecmelberk.com:sites/ecmelberk.com deploy

        rm -r deploy/* || true

    - build: |
        cd ecmelberk.com

        ../hugo
        python3 _gemini/gemini.py
        python3 _gemini/index.py
        python3 _gemini/sitemap.py

    - deploy: |
        mv ecmelberk.com/public/* deploy/

        cd deploy

        git config --global user.email "pages@ecmelberk.com"
        git config --global user.name "Automated page deploy"

        git add --all
        git commit -m "Automated Deployment"
        git push -f