Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 25 additions & 0 deletions cluster/apps/mkdocs/deployment.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
apiVersion: apps/v1
kind: Deployment
metadata:
name: mkdocs
namespace: mkdocs
spec:
replicas: 1
selector:
matchLabels:
ocf.berkeley.edu/flux: mkdocs
template:
metadata:
labels:
ocf.berkeley.edu/flux: mkdocs
spec:
containers:
- image: ghcr.io/ocf/ocf-docs:latest # {"$imagepolicy": "flux-system:mkdocs"}

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

using the image update policy is probably not ideal if there will be a new build of the container every time the docs are updated (as opposed to just pinning latest)

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

latest will always point to the latest build, not exactly sure what the imagepolicy does

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should I remove ':latest' and keep the policy?

imagePullPolicy: IfNotPresent
name: main
ports:
- containerPort: 80
dnsConfig:
searches:
- ocf.berkeley.edu
dnsPolicy: ClusterFirst
23 changes: 23 additions & 0 deletions cluster/apps/mkdocs/image.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
apiVersion: image.toolkit.fluxcd.io/v1
kind: ImageRepository
metadata:
name: mkdocs
namespace: flux-system
spec:
image: ghcr.io/ocf/ocf-docs
interval: 5m0s
---
apiVersion: image.toolkit.fluxcd.io/v1
kind: ImagePolicy
metadata:
name: mkdocs
namespace: flux-system
spec:
imageRepositoryRef:
name: mkdocs
filterTags:
pattern: '^latest$'
policy:
alphabetical: {}
digestReflectionPolicy: Always
interval: 10m
21 changes: 21 additions & 0 deletions cluster/apps/mkdocs/ingress.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
name: mkdocs
namespace: mkdocs
spec:
rules:
- host: bestdocs.ocf.berkeley.edu

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this should be docs.o.b.e, we should be 301ing bestdocs to that

alternatively it could be both

http:
paths:
- backend:
service:
name: mkdocs
port:
number: 80
path: /
pathType: Prefix
tls:
- hosts:
- bestdocs.ocf.berkeley.edu
secretName: mkdocs-tls
4 changes: 4 additions & 0 deletions cluster/apps/mkdocs/namespace.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
apiVersion: v1
kind: Namespace
metadata:
name: mkdocs
11 changes: 11 additions & 0 deletions cluster/apps/mkdocs/service.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
apiVersion: v1
kind: Service
metadata:
name: mkdocs
namespace: mkdocs
spec:
ports:
- port: 80
targetPort: 80
selector:
ocf.berkeley.edu/flux: mkdocs