cleanup
This commit is contained in:
parent
b90f263cf1
commit
e5305bfde9
12 changed files with 2 additions and 825 deletions
|
@ -1,6 +0,0 @@
|
|||
FROM nginx:1.24-bullseye
|
||||
|
||||
COPY ./site-html /var/www/blog
|
||||
COPY ./site-repo/nginx.conf /etc/nginx/conf.d/default.conf
|
||||
COPY ./site-repo/counter /var/www/counter
|
||||
COPY ./site-repo/robots.txt /var/www/robots.txt
|
|
@ -1,6 +1,3 @@
|
|||
# static
|
||||
# Static
|
||||
|
||||
![CI](https://ci.kun.is/api/v1/teams/main/pipelines/static/badge)
|
||||
|
||||
My static website written in Jekyll.
|
||||
Deployment through Concourse.
|
||||
Container image serving static resources.
|
||||
|
|
|
@ -1,371 +0,0 @@
|
|||
body {
|
||||
font-family:Open Sans,Arial;
|
||||
color:#454545;
|
||||
font-size:16px;
|
||||
margin:2em auto;
|
||||
max-width:800px;
|
||||
padding:1em;
|
||||
line-height:1.4;
|
||||
text-align:justify
|
||||
}
|
||||
html.contrast body {
|
||||
color:#050505
|
||||
}
|
||||
html.contrast blockquote {
|
||||
color:#11151a
|
||||
}
|
||||
html.contrast blockquote:before {
|
||||
color:#262626
|
||||
}
|
||||
html.contrast a {
|
||||
color:#03f
|
||||
}
|
||||
html.contrast a:visited {
|
||||
color:#7d013e
|
||||
}
|
||||
html.contrast span.wr {
|
||||
color:#800
|
||||
}
|
||||
html.contrast span.mfw {
|
||||
color:#4d0000
|
||||
}
|
||||
@media screen and (prefers-color-scheme:light) {
|
||||
html.inverted {
|
||||
background-color:#000
|
||||
}
|
||||
html.inverted body {
|
||||
color:#d9d9d9
|
||||
}
|
||||
html.inverted #contrast,
|
||||
html.inverted #invmode {
|
||||
color:#fff;
|
||||
background-color:#000
|
||||
}
|
||||
html.inverted blockquote {
|
||||
color:#d3c9be
|
||||
}
|
||||
html.inverted blockquote:before {
|
||||
color:#b8b8b8
|
||||
}
|
||||
html.inverted a {
|
||||
color:#00a2e7
|
||||
}
|
||||
html.inverted a:visited {
|
||||
color:#ca1a70
|
||||
}
|
||||
html.inverted span.wr {
|
||||
color:#d24637
|
||||
}
|
||||
html.inverted span.mfw {
|
||||
color:#b00000
|
||||
}
|
||||
html.inverted.contrast {
|
||||
background-color:#000
|
||||
}
|
||||
html.inverted.contrast body {
|
||||
color:#fff
|
||||
}
|
||||
html.inverted.contrast #contrast,
|
||||
html.inverted.contrast #invmode {
|
||||
color:#fff;
|
||||
background-color:#000
|
||||
}
|
||||
html.inverted.contrast blockquote {
|
||||
color:#f8f6f5
|
||||
}
|
||||
html.inverted.contrast blockquote:before {
|
||||
color:#e5e5e5
|
||||
}
|
||||
html.inverted.contrast a {
|
||||
color:#44c7ff
|
||||
}
|
||||
html.inverted.contrast a:visited {
|
||||
color:#e9579e
|
||||
}
|
||||
html.inverted.contrast span.wr {
|
||||
color:#db695d
|
||||
}
|
||||
html.inverted.contrast span.mfw {
|
||||
color:#ff0d0d
|
||||
}
|
||||
}
|
||||
@media (prefers-color-scheme:dark) {
|
||||
html:not(.inverted) {
|
||||
background-color:#000
|
||||
}
|
||||
html:not(.inverted) body {
|
||||
color:#d9d9d9
|
||||
}
|
||||
html:not(.inverted) #contrast,
|
||||
html:not(.inverted) #invmode {
|
||||
color:#fff;
|
||||
background-color:#000
|
||||
}
|
||||
html:not(.inverted) blockquote {
|
||||
color:#d3c9be
|
||||
}
|
||||
html:not(.inverted) blockquote:before {
|
||||
color:#b8b8b8
|
||||
}
|
||||
html:not(.inverted) a {
|
||||
color:#00a2e7
|
||||
}
|
||||
html:not(.inverted) a:visited {
|
||||
color:#ca1a70
|
||||
}
|
||||
html:not(.inverted) span.wr {
|
||||
color:#d24637
|
||||
}
|
||||
html:not(.inverted) span.mfw {
|
||||
color:#b00000
|
||||
}
|
||||
html:not(.inverted).contrast {
|
||||
background-color:#000
|
||||
}
|
||||
html:not(.inverted).contrast body {
|
||||
color:#fff
|
||||
}
|
||||
html:not(.inverted).contrast #contrast,
|
||||
html:not(.inverted).contrast #invmode {
|
||||
color:#fff;
|
||||
background-color:#000
|
||||
}
|
||||
html:not(.inverted).contrast blockquote {
|
||||
color:#f8f6f5
|
||||
}
|
||||
html:not(.inverted).contrast blockquote:before {
|
||||
color:#e5e5e5
|
||||
}
|
||||
html:not(.inverted).contrast a {
|
||||
color:#44c7ff
|
||||
}
|
||||
html:not(.inverted).contrast a:visited {
|
||||
color:#e9579e
|
||||
}
|
||||
html:not(.inverted).contrast span.wr {
|
||||
color:#db695d
|
||||
}
|
||||
html:not(.inverted).contrast span.mfw {
|
||||
color:#ff0d0d
|
||||
}
|
||||
html.inverted html {
|
||||
background-color:#fefefe
|
||||
}
|
||||
}
|
||||
a {
|
||||
color:#07a
|
||||
}
|
||||
a:visited {
|
||||
color:#941352
|
||||
}
|
||||
.noselect {
|
||||
-webkit-touch-callout:none;
|
||||
-webkit-user-select:none;
|
||||
-khtml-user-select:none;
|
||||
-moz-user-select:none;
|
||||
-ms-user-select:none;
|
||||
user-select:none
|
||||
}
|
||||
span.citneed {
|
||||
vertical-align:top;
|
||||
font-size:.7em;
|
||||
padding-left:.3em
|
||||
}
|
||||
small {
|
||||
font-size:.4em
|
||||
}
|
||||
p.st {
|
||||
margin-top:-1em
|
||||
}
|
||||
div.fancyPositioning div.picture-left {
|
||||
float:left;
|
||||
width:40%;
|
||||
overflow:hidden;
|
||||
margin-right:1em
|
||||
}
|
||||
div.fancyPositioning div.picture-left img {
|
||||
width:100%
|
||||
}
|
||||
div.fancyPositioning div.picture-left figure {
|
||||
margin:10px
|
||||
}
|
||||
div.fancyPositioning div.picture-left figure figcaption {
|
||||
font-size:.7em
|
||||
}
|
||||
div.fancyPositioning div.tleft {
|
||||
float:left;
|
||||
width:55%
|
||||
}
|
||||
div.fancyPositioning div.tleft p:first-child {
|
||||
margin-top:0
|
||||
}
|
||||
div.fancyPositioning:after {
|
||||
display:block;
|
||||
content:"";
|
||||
clear:both
|
||||
}
|
||||
ul li img {
|
||||
height:1em
|
||||
}
|
||||
blockquote {
|
||||
color:#456;
|
||||
margin-left:0;
|
||||
margin-top:2em;
|
||||
margin-bottom:2em
|
||||
}
|
||||
blockquote span {
|
||||
float:left;
|
||||
margin-left:1rem;
|
||||
padding-top:1rem
|
||||
}
|
||||
blockquote author {
|
||||
display:block;
|
||||
clear:both;
|
||||
font-size:.6em;
|
||||
margin-left:2.4rem;
|
||||
font-style:oblique
|
||||
}
|
||||
blockquote author:before {
|
||||
content:"- ";
|
||||
margin-right:1em
|
||||
}
|
||||
blockquote:before {
|
||||
font-family:Times New Roman,Times,Arial;
|
||||
color:#666;
|
||||
content:open-quote;
|
||||
font-size:2.2em;
|
||||
font-weight:600;
|
||||
float:left;
|
||||
margin-top:0;
|
||||
margin-right:.2rem;
|
||||
width:1.2rem
|
||||
}
|
||||
blockquote:after {
|
||||
content:"";
|
||||
display:block;
|
||||
clear:both
|
||||
}
|
||||
@media screen and (max-width:500px) {
|
||||
body {
|
||||
text-align:left
|
||||
}
|
||||
div.fancyPositioning div.picture-left,
|
||||
div.fancyPositioning div.tleft {
|
||||
float:none;
|
||||
width:inherit
|
||||
}
|
||||
blockquote span {
|
||||
width:80%
|
||||
}
|
||||
blockquote author {
|
||||
padding-top:1em;
|
||||
width:80%;
|
||||
margin-left:15%
|
||||
}
|
||||
blockquote author:before {
|
||||
content:"";
|
||||
margin-right:inherit
|
||||
}
|
||||
}
|
||||
span.visited {
|
||||
color:#941352
|
||||
}
|
||||
span.visited-maroon {
|
||||
color:#85144b
|
||||
}
|
||||
span.wr {
|
||||
color:#c0392b;
|
||||
font-weight:600
|
||||
}
|
||||
button.cont-inv,
|
||||
span.wr {
|
||||
text-decoration:underline
|
||||
}
|
||||
button.cont-inv {
|
||||
cursor:pointer;
|
||||
border-radius:2px;
|
||||
position:fixed;
|
||||
right:10px;
|
||||
font-size:.8em;
|
||||
border:0;
|
||||
padding:2px 5px
|
||||
}
|
||||
#contrast {
|
||||
color:#000;
|
||||
top:10px
|
||||
}
|
||||
#contrast,
|
||||
#invmode {
|
||||
-webkit-touch-callout:none;
|
||||
-webkit-user-select:none;
|
||||
-khtml-user-select:none;
|
||||
-moz-user-select:none;
|
||||
-ms-user-select:none;
|
||||
user-select:none
|
||||
}
|
||||
#invmode {
|
||||
color:#fff;
|
||||
background-color:#000;
|
||||
position:fixed;
|
||||
top:34px;
|
||||
text-decoration:underline
|
||||
}
|
||||
@media screen and (max-width:1080px) {
|
||||
#contrast,
|
||||
#invmode {
|
||||
position:absolute
|
||||
}
|
||||
}
|
||||
span.sb {
|
||||
color:#00e
|
||||
}
|
||||
span.sb,
|
||||
span.sv {
|
||||
cursor:not-allowed
|
||||
}
|
||||
span.sv {
|
||||
color:#551a8b
|
||||
}
|
||||
span.foufoufou {
|
||||
color:#444;
|
||||
font-weight:700
|
||||
}
|
||||
span.foufoufou:before {
|
||||
content:"";
|
||||
display:inline-block;
|
||||
width:1em;
|
||||
height:1em;
|
||||
margin-left:.2em;
|
||||
margin-right:.2em;
|
||||
background-color:#444
|
||||
}
|
||||
span.foufivfoufivfoufiv {
|
||||
color:#454545;
|
||||
font-weight:700
|
||||
}
|
||||
span.foufivfoufivfoufiv:before {
|
||||
content:"";
|
||||
display:inline-block;
|
||||
width:1em;
|
||||
height:1em;
|
||||
margin-left:.2em;
|
||||
margin-right:.2em;
|
||||
background-color:#454545
|
||||
}
|
||||
span.mfw {
|
||||
color:#730000
|
||||
}
|
||||
a.kopimi,
|
||||
a.kopimi img.kopimi {
|
||||
display:block;
|
||||
margin-left:auto;
|
||||
margin-right:auto
|
||||
}
|
||||
a.kopimi img.kopimi {
|
||||
height:2em
|
||||
}
|
||||
p.fakepre {
|
||||
font-family:monospace;
|
||||
font-size:.9em
|
||||
}
|
||||
|
|
@ -1,134 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<meta content="text/html;charset=utf-8" http-equiv="Content-Type">
|
||||
<meta content="utf-8" http-equiv="encoding">
|
||||
<link rel="stylesheet" type="text/css" href="index.css">
|
||||
<style>
|
||||
.deadline {
|
||||
display: inline;
|
||||
}
|
||||
|
||||
.late {
|
||||
color: red;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<h1>Grades when (now!)</h1>
|
||||
<h2>AN Resit</h2>
|
||||
<p>
|
||||
The grades were published 2023-08-25 🎉
|
||||
</p>
|
||||
|
||||
<h2>OT</h2>
|
||||
<p>
|
||||
The grades were published 2023-08-25 🎉
|
||||
</p>
|
||||
|
||||
<h2>RP2</h2>
|
||||
<p>
|
||||
The grades were published 2023-08-25 🎉
|
||||
</p>
|
||||
|
||||
<h2>AS</h2>
|
||||
<p>
|
||||
The grades were published 2023-07-19 🎉
|
||||
</p>
|
||||
|
||||
<h1>References</h2>
|
||||
OER-A (<a href="https://beeldbank.uva.nl/m/4ae52bce4e5d86a8/original/OER-2022-2023-FNWI-MSc-EN.pdf">link</a>):
|
||||
<ul>
|
||||
<li>The resit for an examination must not take place within ten working days of the announcement of the result of the examination being resat.</li>
|
||||
<li>The examiner determines the result (= mark) of a written examination as soon as possible, but at the latest within fifteen working days.</li>
|
||||
</ul>
|
||||
|
||||
<!--
|
||||
OER-A 2022 - 2023:
|
||||
The resit for an examination must not take place within ten working days of the announcement of the result of the examination being resat.
|
||||
The examiner determines the result (= mark) of a written examination as soon as possible, but at the latest within fifteen working days.
|
||||
|
||||
AS
|
||||
Exam date 30th May
|
||||
Deadline grade 19th June
|
||||
Retake date 4th August
|
||||
Deadline grade for resit 21st July
|
||||
|
||||
OT
|
||||
OT deadline date 4th June
|
||||
OT grade deadline 22th June
|
||||
|
||||
RP2
|
||||
RP2 handin date 14th July
|
||||
Final re-enrollment date 31th August
|
||||
-->
|
||||
<script>
|
||||
function set_deadlines() {
|
||||
const minute = 60;
|
||||
const hour = 60 * minute;
|
||||
const day = 24 * hour;
|
||||
const now = Date.now();
|
||||
const deadlines = document.getElementsByClassName('deadline');
|
||||
for (let i = 0; i < deadlines.length; ++i) {
|
||||
const deadline = deadlines[i];
|
||||
const dl_date = Date.parse(deadline.dataset.deadline);
|
||||
|
||||
var str = "";
|
||||
|
||||
str += dl_date > now ? "is at " : "was at ";
|
||||
var time_added = false;
|
||||
|
||||
str += deadline.dataset.deadline;
|
||||
str += " (";
|
||||
str += "<span";
|
||||
str += dl_date < now ? ' class="late">' : ">";
|
||||
|
||||
var timediff = Math.round((now - dl_date) / 1000);
|
||||
timediff = timediff < 0 ? -timediff : timediff
|
||||
|
||||
if (timediff >= day) {
|
||||
const days = Math.floor(timediff / day);
|
||||
str += days + " days";
|
||||
time_added = true;
|
||||
timediff -= days * day;
|
||||
}
|
||||
|
||||
if (timediff >= hour) {
|
||||
const hours = Math.floor(timediff / hour);
|
||||
if (time_added) {
|
||||
str += ", ";
|
||||
}
|
||||
str += hours + " hours";
|
||||
time_added = true;
|
||||
timediff -= hours * hour;
|
||||
}
|
||||
|
||||
if (timediff >= minute) {
|
||||
const minutes = Math.floor(timediff / minute);
|
||||
if (time_added) {
|
||||
str += ", ";
|
||||
}
|
||||
str += minutes + " minutes";
|
||||
time_added = true;
|
||||
timediff -= minutes * minute;
|
||||
}
|
||||
|
||||
if (time_added) {
|
||||
str += " and ";
|
||||
}
|
||||
str += timediff + " seconds";
|
||||
time_added = true;
|
||||
|
||||
str += dl_date > now ? " from now" : " ago";
|
||||
str += "</span>" ;
|
||||
str += ")";
|
||||
|
||||
deadline.innerHTML = str;
|
||||
}
|
||||
}
|
||||
|
||||
setInterval(set_deadlines, 1000);
|
||||
set_deadlines();
|
||||
</script>
|
||||
</body>
|
||||
</html
|
|
@ -1 +0,0 @@
|
|||
fly -t home set-pipeline -l secrets.yml -p static -c pipeline.yml
|
|
@ -1,34 +0,0 @@
|
|||
# vi: ft=yaml
|
||||
version: '3'
|
||||
|
||||
networks:
|
||||
traefik:
|
||||
external: true
|
||||
|
||||
services:
|
||||
static:
|
||||
image: git.kun.is/pim/static:TAG
|
||||
networks:
|
||||
- traefik
|
||||
deploy:
|
||||
labels:
|
||||
- traefik.enable=true
|
||||
|
||||
- traefik.http.routers.blog.entrypoints=websecure
|
||||
- traefik.http.routers.blog.service=static
|
||||
- traefik.http.services.static.loadbalancer.server.port=80
|
||||
- traefik.http.routers.blog.rule=Host(`pim.kun.is`)
|
||||
- traefik.http.routers.blog.tls=true
|
||||
- traefik.http.routers.blog.tls.certresolver=letsencrypt
|
||||
|
||||
- traefik.http.routers.redirects.entrypoints=websecure
|
||||
- traefik.http.routers.redirects.service=static
|
||||
- "traefik.http.routers.redirects.rule=(Host(`pim.kunis.nl`) || Host(`concourse.pim.kunis.nl`) || Host(`rss.pim.kunis.nl`) || Host(`md.pim.kunis.nl`) || Host(`cloud.pim.kunis.nl`) || Host(`dav.pim.kunis.nl`) || Host(`git.pim.kunis.nl`) || Host(`latex.pim.kunis.nl`) || Host(`grades.when.kun.is`) || Path(`/robots.txt`))"
|
||||
- traefik.http.routers.redirects.tls=true
|
||||
- traefik.http.routers.redirects.tls.certresolver=letsencrypt
|
||||
|
||||
- traefik.http.routers.redirects-local.entrypoints=localsecure
|
||||
- traefik.http.routers.redirects-local.service=static
|
||||
- "traefik.http.routers.redirects-local.rule=(Host(`traefik.pim.kunis.nl`) || Host(`pihole.pim.kunis.nl`) || Host(`swarm.pim.kunis.nl`) || Host(`uptime.pim.kunis.nl`))"
|
||||
- traefik.http.routers.redirects-local.tls=true
|
||||
- traefik.http.routers.redirects-local.tls.certresolver=letsencrypt
|
|
@ -1 +0,0 @@
|
|||
ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIBSVLcr617iJt+hqLFSsOQy1JeueLIAj1eRfuI+KeZAu pim@x260
|
4
labels
4
labels
|
@ -1,4 +0,0 @@
|
|||
org.opencontainers.image.authors=Pim Kunis
|
||||
org.opencontainers.image.source=https://git.kun.is/pim/static
|
||||
org.opencontainers.image.documentation=https://git.kun.is/pim/static/src/branch/master/README.md
|
||||
org.opencontainers.image.description=My static website written in Jekyll.
|
106
nginx.conf
106
nginx.conf
|
@ -1,106 +0,0 @@
|
|||
server {
|
||||
listen 80;
|
||||
server_name _;
|
||||
|
||||
location /robots.txt {
|
||||
alias /var/www/robots.txt;
|
||||
}
|
||||
}
|
||||
|
||||
server {
|
||||
listen 80;
|
||||
server_name pim.kun.is;
|
||||
index index.html index.htm;
|
||||
root /var/www/blog;
|
||||
|
||||
location / {
|
||||
try_files $uri $uri/ /index.html;
|
||||
}
|
||||
|
||||
location ~* \.(?:ico|css|js|gif|jpe?g|png)$ {
|
||||
expires 3600;
|
||||
add_header Pragma public;
|
||||
add_header Cache-Control "public";
|
||||
}
|
||||
|
||||
location /robots.txt {
|
||||
alias /var/www/robots.txt;
|
||||
}
|
||||
|
||||
error_page 404 /404.html;
|
||||
}
|
||||
|
||||
server {
|
||||
listen 80;
|
||||
server_name grades.when.kun.is;
|
||||
index index.html;
|
||||
root /var/www/counter;
|
||||
|
||||
location / {
|
||||
try_files $uri $uri/ /index.html;
|
||||
}
|
||||
|
||||
location /robots.txt {
|
||||
alias /var/www/robots.txt;
|
||||
}
|
||||
}
|
||||
|
||||
server {
|
||||
server_name pim.kunis.nl;
|
||||
return 301 https://pim.kun.is$request_uri;
|
||||
}
|
||||
|
||||
server {
|
||||
server_name concourse.pim.kunis.nl;
|
||||
return 301 https://ci.kun.is$request_uri;
|
||||
}
|
||||
|
||||
server {
|
||||
server_name rss.pim.kunis.nl;
|
||||
return 301 https://rss.kun.is$request_uri;
|
||||
}
|
||||
|
||||
server {
|
||||
server_name md.pim.kunis.nl;
|
||||
return 301 https://md.kun.is$request_uri;
|
||||
}
|
||||
|
||||
server {
|
||||
server_name cloud.pim.kunis.nl;
|
||||
return 301 https://cloud.kun.is$request_uri;
|
||||
}
|
||||
|
||||
server {
|
||||
server_name dav.pim.kunis.nl;
|
||||
return 301 https://dav.kun.is$request_uri;
|
||||
}
|
||||
|
||||
server {
|
||||
server_name git.pim.kunis.nl;
|
||||
return 301 https://git.kun.is$request_uri;
|
||||
}
|
||||
|
||||
server {
|
||||
server_name traefik.pim.kunis.nl;
|
||||
return 301 https://traefik.kun.is:444$request_uri;
|
||||
}
|
||||
|
||||
server {
|
||||
server_name latex.pim.kunis.nl;
|
||||
return 301 https://latex.kun.is$request_uri;
|
||||
}
|
||||
|
||||
server {
|
||||
server_name pihole.pim.kunis.nl;
|
||||
return 301 https://pihole.kun.is:444$request_uri;
|
||||
}
|
||||
|
||||
server {
|
||||
server_name swarm.pim.kunis.nl;
|
||||
return 301 https://swarm.kun.is:444$request_uri;
|
||||
}
|
||||
|
||||
server {
|
||||
server_name uptime.pim.kunis.nl;
|
||||
return 301 https://uptime.kun.is:444$request_uri;
|
||||
}
|
153
pipeline.yml
153
pipeline.yml
|
@ -1,153 +0,0 @@
|
|||
---
|
||||
resource_types:
|
||||
- name: apprise
|
||||
type: registry-image
|
||||
source:
|
||||
repository: git.kun.is/pim/concourse-apprise-notifier
|
||||
tag: "1.1.1"
|
||||
|
||||
resources:
|
||||
- name: site-repo
|
||||
type: git
|
||||
source:
|
||||
uri: https://git.kun.is/pim/static.git
|
||||
icon: git
|
||||
- name: site-registry-image
|
||||
type: registry-image
|
||||
source:
|
||||
repository: git.kun.is/pim/static
|
||||
username: pim
|
||||
password: ((api_key))
|
||||
tag: stable
|
||||
icon: docker
|
||||
- name: apprise-notification
|
||||
type: apprise
|
||||
source:
|
||||
host: https://apprise.kun.is:444
|
||||
key: concourse
|
||||
icon: bell
|
||||
- name: version
|
||||
type: semver
|
||||
source:
|
||||
driver: git
|
||||
initial_version: "1.1.0"
|
||||
uri: ssh://git@git.kun.is:56287/pim/static.git
|
||||
branch: version
|
||||
file: version
|
||||
private_key: {{private_key}}
|
||||
icon: numeric
|
||||
|
||||
notify-failed: ¬ify-failed
|
||||
put: apprise-notification
|
||||
params:
|
||||
body: "Failed to deploy static website!"
|
||||
|
||||
jobs:
|
||||
- name: build-static-website
|
||||
plan:
|
||||
- get: site-repo
|
||||
trigger: true
|
||||
- task: build-site
|
||||
config:
|
||||
platform: linux
|
||||
image_resource:
|
||||
type: registry-image
|
||||
source:
|
||||
repository: jekyll/builder
|
||||
inputs:
|
||||
- name: site-repo
|
||||
outputs:
|
||||
- name: site-html
|
||||
params:
|
||||
JEKYLL_ENV: production
|
||||
run:
|
||||
path: sh
|
||||
args:
|
||||
- -exc
|
||||
- |
|
||||
ls -lash
|
||||
chown jekyll:jekyll site-html
|
||||
cd site-repo/jekyll
|
||||
bundle install
|
||||
bundle exec jekyll build --disable-disk-cache --destination ../../site-html
|
||||
on_failure:
|
||||
<< : *notify-failed
|
||||
- task: build-image
|
||||
privileged: true
|
||||
config:
|
||||
platform: linux
|
||||
image_resource:
|
||||
type: registry-image
|
||||
source:
|
||||
repository: concourse/oci-build-task
|
||||
inputs:
|
||||
- name: site-repo
|
||||
- name: site-html
|
||||
outputs:
|
||||
- name: image
|
||||
params:
|
||||
DOCKERFILE: site-repo/Dockerfile
|
||||
LABELS_FILE: site-repo/labels
|
||||
run:
|
||||
path: sh
|
||||
args:
|
||||
- -exc
|
||||
- |
|
||||
build
|
||||
ls image
|
||||
on_failure:
|
||||
<< : *notify-failed
|
||||
- get: version
|
||||
params:
|
||||
bump: patch
|
||||
- put: site-registry-image
|
||||
params:
|
||||
image: image/image.tar
|
||||
additional_tags: version/version
|
||||
on_failure:
|
||||
<< : *notify-failed
|
||||
- put: version
|
||||
params:
|
||||
file: version/version
|
||||
- name: deploy-static-website
|
||||
plan:
|
||||
- get: version
|
||||
trigger: true
|
||||
passed: [build-static-website]
|
||||
- get: site-repo
|
||||
- get: site-registry-image
|
||||
passed: [build-static-website]
|
||||
- task: deploy-site
|
||||
config:
|
||||
platform: linux
|
||||
image_resource:
|
||||
type: registry-image
|
||||
source:
|
||||
repository: raesene/alpine-containertools
|
||||
params:
|
||||
DOCKER_HOST: ssh://root@maestro.dmz
|
||||
inputs:
|
||||
- name: site-repo
|
||||
- name: site-registry-image
|
||||
- name: version
|
||||
run:
|
||||
path: sh
|
||||
args:
|
||||
- -exc
|
||||
- |
|
||||
ls -lash
|
||||
mkdir $HOME/.ssh
|
||||
cp site-repo/ssh_config $HOME/.ssh/config
|
||||
echo "((private_key))" > $HOME/.ssh/id_ed25519
|
||||
chmod 600 $HOME/.ssh/id_ed25519
|
||||
sed "s/TAG/$(cat version/version)/g" "site-repo/docker-stack.yml.template" > docker-stack.yml
|
||||
cat docker-stack.yml
|
||||
docker stack deploy --compose-file docker-stack.yml static
|
||||
on_success:
|
||||
put: apprise-notification
|
||||
params:
|
||||
title: "Static website deployed!"
|
||||
body: "New version: $(cat version/version)"
|
||||
no_get: true
|
||||
on_failure:
|
||||
<< : *notify-failed
|
|
@ -1,8 +0,0 @@
|
|||
User-agent: SemrushBot
|
||||
Disallow: /
|
||||
User-agent: AhrefsBot
|
||||
Disallow: /
|
||||
User-agent: DotBot
|
||||
Disallow: /
|
||||
User-Agent: FacebookBot
|
||||
Disallow: /
|
|
@ -1,2 +0,0 @@
|
|||
Host maestro.dmz
|
||||
StrictHostKeyChecking no
|
Reference in a new issue