feat: Comments section is added
continuous-integration/drone/push Build is failing Details

This commit is contained in:
Nikolai Rodionov 2023-02-18 21:02:02 +01:00
parent bd3fa6bbab
commit ecd61bff94
13 changed files with 115 additions and 3 deletions

View File

@ -70,6 +70,10 @@ steps:
environment:
KUBECONFIG_CONTENT:
from_secret: KUBECONFIG_CONTENT
ARGO_GITHUB_OAUTH_KEY:
from_secret: GITHUB_OAUTH_KEY
ARGO_GOOGLE_OAUTH_KEY:
from_secret: GOOGLE_OAUTH_KEY
commands:
- mkdir $HOME/.kube
- echo $KUBECONFIG_CONTENT | base64 -d > $HOME/.kube/config

6
chart/Chart.lock Normal file
View File

@ -0,0 +1,6 @@
dependencies:
- name: remark42
repository: https://groundhog2k.github.io/helm-charts/
version: 0.5.5
digest: sha256:975188682c1b89eca43ecfd655b70853c1c6dc6fbebd6a8da43cf3cac26f3d63
generated: "2023-02-27T13:32:44.817705541+01:00"

View File

@ -2,5 +2,11 @@ apiVersion: v2
name: badhouseplants-net
description: A Helm chart for Kubernetes
type: application
version: 0.4.2
appVersion: "1.16.0"
version: 0.5.7
appVersion: "4.20.0"
dependencies:
- name: remark42
version: 0.5.5
repository: https://groundhog2k.github.io/helm-charts/
condition: remark42.enabled

Binary file not shown.

View File

@ -2,7 +2,7 @@
apiVersion: networking.istio.io/v1beta1
kind: VirtualService
metadata:
name: blog-virtual-service
name: {{ include "badhouseplants-net.fullname" . }}
labels:
{{- include "badhouseplants-net.labels" . | nindent 4 }}
{{- with .Values.istio.annotations }}
@ -26,3 +26,32 @@ spec:
port:
number: {{ .Values.service.port }}
{{- end }}
---
{{- if .Values.remark42.istio.enabled -}}
apiVersion: networking.istio.io/v1beta1
kind: VirtualService
metadata:
name: {{ include "remark42.fullname" . }}-remark42
labels:
{{- include "badhouseplants-net.labels" . | nindent 4 }}
{{- with .Values.remark42.istio.annotations }}
annotations:
{{- toYaml . | nindent 4 }}
{{- end }}
spec:
gateways:
- istio-system/badhouseplants-net
hosts:
{{- range .Values.remark42.istio.hosts}}
- {{ . }}
{{- end }}
http:
- match:
- uri:
prefix: {{ .Values.remark42.istio.prefix }}
route:
- destination:
host: {{ .Release.Name }}-remark42
port:
number: {{ .Values.remark42.service.port }}
{{- end }}

View File

@ -69,6 +69,31 @@ volumes:
name: s3-data
sizeLimit: 1Gi
remark42:
enabled: true
settings:
url: https://remark42.badhouseplants.net
secretKey: secret
emoji: true
auth:
anonymous: true
sameSite: "none"
oauth:
google:
enabled: true
key: ""
secret: ""
github:
enabled: true
key: ""
secret: ""
istio:
annotations: {}
enabled: true
hosts:
- remark42.badhouseplants.net
prefix: /
imagePullSecrets: []
nameOverride: ""
fullnameOverride: ""

View File

@ -23,6 +23,8 @@ taxonomies:
tag: tags
params:
GitBranch: main
Remark42ID: remark
Remark42URL: https://remark42-add-comments-dev.badhouseplants.net
ShowBreadCrumbs: true
ShowReadingTime: true
ShowPostNavLinks: true
@ -64,3 +66,4 @@ outputs:
- HTML
- RSS
- JSON

View File

@ -572,3 +572,6 @@ In the next post I will try doing the same with `ApplicationSets`, and we'll see
Thanks,
Oi!
{{< comments >}}

View File

@ -1583,3 +1583,4 @@ You can find an example of PR here: <https://git.badhouseplants.net/allanger/hel
> When helmfile is not GitOps?
> To uninstall a helm release, you need to add `isntalled: false` to it. If you just remove a release from helmfile.yaml, it isn't going to be removed. So in such cases it's not GitOps. You can write a hook, that is comparing a previous state of your helmfile to the current one and doing a cleanup, then it's again fully GitOps. But I prefer removing things manually, so to me, it's not a problem. Removing stuff is something that I think should be mostly done by a human being, if it's not a part of your daily work.
{{< comments >}}

View File

@ -11,4 +11,18 @@
annotations:
link.argocd.argoproj.io/env: https://badhouseplants.net/
link.argocd.argoproj.io/build: $DRONE_BUILD_LINK
link.argocd.argoproj.io/remark42: https://remark42-$ARGO_APP_HOSTNAME/web
remark42:
settings:
auth:
anonymous: false
oauth:
github:
key: 1fb3d33a62b074bc0ea0
secret: $ARGO_GITHUB_OAUTH_KEY
google:
key: 966815964055-m9t7leuj1arqimqu2pvbs1k10cg54gcg.apps.googleusercontent.com
secret: $ARGO_GOOGLE_OAUTH_KEY
storage:
requestedSize: 300Mi

View File

@ -12,6 +12,7 @@
- $ARGO_APP_HOSTNAME
annotations:
link.argocd.argoproj.io/env: https://$ARGO_APP_HOSTNAME/
link.argocd.argoproj.io/remark42: https://remark42-$ARGO_APP_HOSTNAME/web
link.argocd.argoproj.io/build: $DRONE_BUILD_LINK
hugo:
image:
@ -20,3 +21,11 @@
buildDrafts: true
env:
HUGO_PARAMS_GITBRANCH: $ARGO_APP_BRANCH
HUDO_PARAMS_REMARK42URL: https://remark42-$ARGO_APP_HOSTNAME/
remark42:
istio:
hosts:
- remark42-$ARGO_APP_HOSTNAME
settings:
url: https://remark42-$ARGO_APP_HOSTNAME/

View File

@ -0,0 +1,11 @@
<div id="remark42"></div>
<script>
var theme = "light"
if (document.body.classList.contains("dark")) theme = "dark";
var remark_config = {
host: "{{ site.Params.Remark42URL }}",
site_id: "{{ site.Params.Remark42ID }}",
theme: theme
}
</script>
<script>!function(e,n){for(var o=0;o<e.length;o++){var r=n.createElement("script"),c=".js",d=n.head||n.body;"noModule"in r?(r.type="module",c=".mjs"):r.async=!0,r.defer=!0,r.src=remark_config.host+"/web/"+e[o]+c,d.appendChild(r)}}(remark_config.components||["embed"],document);</script>

View File

@ -0,0 +1 @@
{{ partial "remark42.html" . }}