Skip to content

Commit

Permalink
Merge pull request #95 from sooraj-sky/dev
Browse files Browse the repository at this point in the history
Dev
  • Loading branch information
sooraj-sky authored Jul 22, 2023
2 parents ba9f77d + 9662d11 commit 890529d
Show file tree
Hide file tree
Showing 9 changed files with 209 additions and 1 deletion.
23 changes: 23 additions & 0 deletions k8s/skymeter-chart/.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/
24 changes: 24 additions & 0 deletions k8s/skymeter-chart/Chart.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
apiVersion: v2
name: skymeter-chart
description: A Helm chart for Kubernetes

# A chart can be either an 'application' or a 'library' chart.
#
# Application charts are a collection of templates that can be packaged into versioned archives
# to be deployed.
#
# Library charts provide useful utilities or functions for the chart developer. They're included as
# a dependency of application charts to inject those utilities and functions into the rendering
# pipeline. Library charts do not define any templates and therefore cannot be deployed.
type: application

# This is the chart version. This version number should be incremented each time you make changes
# to the chart and its templates, including the app version.
# Versions are expected to follow Semantic Versioning (https://semver.org/)
version: 0.1.0

# This is the version number of the application being deployed. This version number should be
# incremented each time you make changes to the application. Versions are not expected to
# follow Semantic Versioning. They should reflect the version the application is using.
# It is recommended to use it with quotes.
appVersion: "1.16.0"
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ spec:
spec:
containers:
- name: skymeter
image: soorajsky/sky-meter:release-0b314b4
image: soorajsky/sky-meter:release-ba9f77d
envFrom:
- configMapRef:
name: skymeter-env # Replace with your ConfigMap name
Expand Down
File renamed without changes.
File renamed without changes.
70 changes: 70 additions & 0 deletions k8s/skymeter-chart/values.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,70 @@
# Default values for skymeter-chart.
# This is a YAML-formatted file.
# Declare variables to be passed into your templates.

serviceAccount:
# Specifies whether a service account should be created
create: true
# Annotations to add to the service account
annotations: {}
# The name of the service account to use.
# If not set and create is true, a name is generated using the fullname template
name: ""

podAnnotations: {}

podSecurityContext: {}
# fsGroup: 2000

securityContext: {}
# capabilities:
# drop:
# - ALL
# readOnlyRootFilesystem: true
# runAsNonRoot: true
# runAsUser: 1000

service:
type: ClusterIP
port: 80

ingress:
enabled: false
className: ""
annotations: {}
# kubernetes.io/ingress.class: nginx
# kubernetes.io/tls-acme: "true"
hosts:
- host: chart-example.local
paths:
- path: /
pathType: ImplementationSpecific
tls: []
# - secretName: chart-example-tls
# hosts:
# - chart-example.local

resources: {}
# We usually recommend not to specify default resources and to leave this as a conscious
# choice for the user. This also increases chances charts run on environments with little
# resources, such as Minikube. If you do want to specify resources, uncomment the following
# lines, adjust them as necessary, and remove the curly braces after 'resources:'.
# limits:
# cpu: 100m
# memory: 128Mi
# requests:
# cpu: 100m
# memory: 128Mi

autoscaling:
enabled: false
minReplicas: 1
maxReplicas: 100
targetCPUUtilizationPercentage: 80
# targetMemoryUtilizationPercentage: 80

nodeSelector: {}

tolerations: []

affinity: {}
32 changes: 32 additions & 0 deletions k8s/yaml-files/deployment.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
apiVersion: apps/v1
kind: Deployment
metadata:
name: skymeter-deployment
spec:
replicas: 1
selector:
matchLabels:
app: skymeter
template:
metadata:
labels:
app: skymeter
spec:
containers:
- name: skymeter
image: soorajsky/sky-meter:release-ba9f77d
envFrom:
- configMapRef:
name: skymeter-env # Replace with your ConfigMap name
volumeMounts:
- name: settings-volume
mountPath: /home/skyuser/settings.yml # Replace with the desired path inside the container
subPath: settings.yml
volumes:
- name: settings-volume
configMap:
name: skymeter-settings # Replace with your ConfigMap name
items:
- key: settings.yml
path: settings.yml

15 changes: 15 additions & 0 deletions k8s/yaml-files/env-configmap.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
apiVersion: v1
kind: ConfigMap
metadata:
name: skymeter-env # Replace with your desired ConfigMap name
data:
DnsServer: "8.8.8.8"
DbUrl: "host=192.168.0.7 user=postgres password=postgres dbname=postgres port=5433 sslmode=disable"
EmailPass: "your-pass-here"
EmailFrom: "[email protected]"
EmailPort: "587"
EmailServer: "smtp.server-address-here.com"
OpsgenieSecret: "your-opsgenie-key-here"
Mode: "prod"
SentryDsn: "test"

44 changes: 44 additions & 0 deletions k8s/yaml-files/settings-config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
apiVersion: v1
kind: ConfigMap
metadata:
name: skymeter-settings # Replace with your desired ConfigMap name
data:
settings.yml: |
opegenie:
enabled: false
email:
enabled: true
groups:
- name: prod
emails:
- [email protected]
- [email protected]
- name: dev
emails:
- [email protected]
- [email protected]
domains:
- name: https://skywalks.in
enabled: true
timeout: 10
skip_ssl: false
frequency: 10
group: dev
- name: https://sky-meter.skywalks.in
enabled: true
timeout: 10
skip_ssl: false
frequency: 60
group: dev
- name: https://github.com
enabled: true
timeout: 10
skip_ssl: false
frequency: 60
group: prod
- name: https://githcccubs.com
enabled: true
timeout: 10
skip_ssl: false
frequency: 60
group: prod

0 comments on commit 890529d

Please sign in to comment.