Compare commits

..

5 commits

Author SHA1 Message Date
Julius 2b54fdbce5 Merge pull request 'Update drone for fun and profit' (#3) from staging into main
All checks were successful
continuous-integration/drone/push Build is passing
Reviewed-on: https://git.voidcorp.nl/j00lz/galerie-site/pulls/3
2021-11-14 16:34:27 +01:00
Julius 3319cf5648 Merge branch 'main' into staging
All checks were successful
continuous-integration/drone/push Build is passing
2021-11-14 16:31:41 +01:00
Julius 4a05646533
Output hash in logs
All checks were successful
continuous-integration/drone/push Build is passing
2021-11-14 16:30:58 +01:00
Julius 73f822ce46
Fix drone config
All checks were successful
continuous-integration/drone/push Build is passing
2021-11-14 16:20:59 +01:00
Julius b8de5e080b
Add link to git
All checks were successful
continuous-integration/drone/push Build is passing
2021-11-14 16:08:44 +01:00
5 changed files with 13 additions and 1 deletions

View file

@ -12,6 +12,10 @@ trigger:
- pull_request
steps:
- name: commit hash magic
image: bitnami/git:2.33.0
commands:
- git show -s --format=%H | tee hash
- name: kaniko
image: plugins/kaniko
settings:

1
.gitignore vendored
View file

@ -1,2 +1,3 @@
.vscode/
dist/
hash

View file

@ -9,6 +9,7 @@ RUN pip install pipenv && pipenv install --system
COPY app.py /app/app.py
COPY templates/ /app/templates
COPY data/ /app/data
COPY hash /app/hash
RUN python ./app.py

7
app.py
View file

@ -26,11 +26,16 @@ update = date.today()
tijden = render("tijden.md")
nieuws = render("nieuws.md")
def read_hash():
with open("hash") as f:
line = f.readline()
return {"long": line, "short": line[0:7]}
inject_now = {'now': date.today().year,
'tijden': tijden,
'nieuws': nieuws,
'update': update}
'update': update,
'hash': read_hash()}

View file

@ -54,6 +54,7 @@
<hr style="height: 2px;"/>
<p style="margin-top: 16px; height: 40px;">Laatste
update: {{ update }}<br/>
<a href="https://git.voidcorp.nl/j00lz/galerie-site/commit/{{hash.long}}">Build {{hash.short}}</a><br>
Webmaster: <a href="mailto:webmaster@galerievanslagmaat.nl?SUBJECT=Website Galerie van Slagmaat">Julius de
Jeu</a>