Skip to content

Commit

Permalink
feat: first semlookp deployment configs
Browse files Browse the repository at this point in the history
  • Loading branch information
jusa3 committed Dec 4, 2023
1 parent 0697507 commit 4e3aa8b
Show file tree
Hide file tree
Showing 10 changed files with 228 additions and 0 deletions.
27 changes: 27 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
name: Release Charts

on:
push:
branches:
- main

jobs:
release:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
with:
fetch-depth: 0

- name: Configure Git
run: |
git config user.name "$GITHUB_ACTOR"
git config user.email "[email protected]"
- name: Run chart-releaser
uses: helm/[email protected]
with:
charts_dir: k8s
env:
CR_TOKEN: "${{ secrets.GITHUB_TOKEN }}"
72 changes: 72 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,72 @@
### JetBrains template
# Covers JetBrains IDEs: IntelliJ, RubyMine, PhpStorm, AppCode, PyCharm, CLion, Android Studio, WebStorm and Rider
# Reference: https://intellij-support.jetbrains.com/hc/en-us/articles/206544839
.idea
# User-specific stuff
.idea/**/workspace.xml
.idea/**/tasks.xml
.idea/**/usage.statistics.xml
.idea/**/dictionaries
.idea/**/shelf

# Generated files
.idea/**/contentModel.xml

# Sensitive or high-churn files
.idea/**/dataSources/
.idea/**/dataSources.ids
.idea/**/dataSources.local.xml
.idea/**/sqlDataSources.xml
.idea/**/dynamic.xml
.idea/**/uiDesigner.xml
.idea/**/dbnavigator.xml

# Gradle
.idea/**/gradle.xml
.idea/**/libraries

# Gradle and Maven with auto-import
# When using Gradle or Maven with auto-import, you should exclude module files,
# since they will be recreated, and may cause churn. Uncomment if using
# auto-import.
# .idea/artifacts
# .idea/compiler.xml
# .idea/jarRepositories.xml
# .idea/modules.xml
# .idea/*.iml
# .idea/modules
# *.iml
# *.ipr

# CMake
cmake-build-*/

# Mongo Explorer plugin
.idea/**/mongoSettings.xml

# File-based project format
*.iws

# IntelliJ
out/

# mpeltonen/sbt-idea plugin
.idea_modules/

# JIRA plugin
atlassian-ide-plugin.xml

# Cursive Clojure plugin
.idea/replstate.xml

# Crashlytics plugin (for Android Studio and IntelliJ)
com_crashlytics_export_strings.xml
crashlytics.properties
crashlytics-build.properties
fabric.properties

# Editor-based Rest Client
.idea/httpRequests

# Android studio 3.1+ serialized cache file
.idea/caches/build_file_checksums.ser
21 changes: 21 additions & 0 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
MIT License

Copyright (c) 2021 Deutsche Zentralbibliothek für Medizin (ZB MED) - Informationszentrum Lebenswissenschaften

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
23 changes: 23 additions & 0 deletions k8s/semlookp-ui/.helmignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# Patterns to ignore when building packages.
# This supports shell glob matching, relative path matching, and
# negation (prefixed with !). Only one pattern per line.
.DS_Store
# Common VCS dirs
.git/
.gitignore
.bzr/
.bzrignore
.hg/
.hgignore
.svn/
# Common backup files
*.swp
*.bak
*.tmp
*.orig
*~
# Various IDEs
.project
.idea/
*.tmproj
.vscode/
6 changes: 6 additions & 0 deletions k8s/semlookp-ui/Chart.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
apiVersion: v2
name: semlookp-ui
description: A Helm chart to deploy the semlookp-ui.
type: application
version: 0.0.1
appVersion: "1.0.0"
4 changes: 4 additions & 0 deletions k8s/semlookp-ui/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
# Install semlookp-ui
```
helm install my-test ./semlookp-ui
```
25 changes: 25 additions & 0 deletions k8s/semlookp-ui/templates/semlookp-frontend-deployment.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
apiVersion: apps/v1
kind: Deployment
metadata:
name: {{ .Release.Name }}-frontend
spec:
selector:
matchLabels:
name: {{ .Release.Name }}-frontend
template:
metadata:
labels:
name: {{ .Release.Name }}-frontend
spec:
containers:
- name: frontend
image: {{ .Values.images.frontend }}
resources:
limits:
memory: 500Mi
requests:
memory: 100Mi
ports:
- containerPort: 80
imagePullSecrets:
- name: semlookp-dockerconfigjson-github-com
11 changes: 11 additions & 0 deletions k8s/semlookp-ui/templates/semlookp-frontend-service.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
apiVersion: v1
kind: Service
metadata:
name: {{ .Release.Name }}-frontend
spec:
ports:
- name: "80"
port: 80
targetPort: 80
selector:
name: {{ .Release.Name }}-frontend
33 changes: 33 additions & 0 deletions k8s/semlookp-ui/templates/semlookp-ingress.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
{{- if .Values.ingress.dns }}
{{- $relname := .Release.Name -}}
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
name: {{ .Release.Name }}-ingress
annotations:
kubernetes.io/ingress.class: "nginx"
{{ if .Values.ingress.enableSSL }}
nginx.ingress.kubernetes.io/ssl-redirect: "true"
nginx.ingress.kubernetes.io/force-ssl-redirect: "true"
cert-manager.io/issuer: {{ .Values.ingress.certIssuer | quote}}
{{ end }}
nginx.ingress.kubernetes.io/proxy-buffer-size: 12k
spec:
{{ if .Values.ingress.enableSSL }}
tls:
- hosts:
- {{ .Values.ingress.dns }}
secretName: {{ .Release.Name }}-ssl-secret
{{ end }}
rules:
- host: {{ .Values.ingress.dns }}
http:
paths:
- path: /
pathType: Prefix
backend:
service:
name: {{ .Release.Name }}-frontend
port:
number: 80
{{- end }}
6 changes: 6 additions & 0 deletions k8s/semlookp-ui/values.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
ingress:
dns:
enableSSL:
certIssuer:
images:
frontend: ghcr.io/zbmed/semlookp-ui:latest

0 comments on commit 4e3aa8b

Please sign in to comment.