Skip to content
This repository has been archived by the owner on Dec 15, 2024. It is now read-only.

Commit

Permalink
Merge pull request #5 from small-hack/fix/syncdb-server
Browse files Browse the repository at this point in the history
try to make syncv3.server and syncv3.db work...
  • Loading branch information
jessebot authored May 18, 2024
2 parents 9e3d262 + fff2c2b commit a8bbbf8
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 15 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,4 @@ helm install my-release-name matrix-sliding-sync/matrix-sliding-sync --values va

## Status

Not yet functional. Tests still not passing. If you know why, please submit PR.
Kinda working. Submit PRs or Issues if something specific isn't working
4 changes: 2 additions & 2 deletions charts/matrix-sliding-sync/Chart.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
apiVersion: v2
name: matrix-sliding-sync
description: A Helm chart for Kubernetes
description: A Helm chart for deploying matrix sliding sync on Kubernetes

# A chart can be either an 'application' or a 'library' chart.
#
Expand All @@ -15,7 +15,7 @@ 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.2.0
version: 0.2.1

# 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
Expand Down
10 changes: 6 additions & 4 deletions charts/matrix-sliding-sync/README.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
# matrix-sliding-sync

![Version: 0.2.0](https://img.shields.io/badge/Version-0.2.0-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: v0.99.17](https://img.shields.io/badge/AppVersion-v0.99.17-informational?style=flat-square)
![Version: 0.2.1](https://img.shields.io/badge/Version-0.2.1-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: v0.99.17](https://img.shields.io/badge/AppVersion-v0.99.17-informational?style=flat-square)

A Helm chart for Kubernetes
A Helm chart for deploying matrix sliding sync on Kubernetes

## Maintainers

Expand Down Expand Up @@ -90,8 +90,10 @@ A Helm chart for Kubernetes
| replicaCount | int | `1` | |
| resources | object | `{}` | |
| securityContext | object | `{}` | |
| service.port | int | `80` | |
| service.type | string | `"ClusterIP"` | |
| service.annotations | object | `{}` | annotations for your service |
| service.port | int | `80` | Port of service |
| service.targetPort | int | `8008` | targetPort of service. should be the same as port for syncv3.bindaddr |
| service.type | string | `"ClusterIP"` | type of service |
| serviceAccount.annotations | object | `{}` | |
| serviceAccount.automount | bool | `true` | |
| serviceAccount.create | bool | `true` | |
Expand Down
6 changes: 3 additions & 3 deletions charts/matrix-sliding-sync/templates/_helpers.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -167,10 +167,10 @@ templates out SYNCV3_DB which is a postgres connection string: https://www.postg
*/}}
{{- define "matrix-sliding-sync.dbConnString" -}}
{{- if not .Values.syncv3.existingSecret }}
{{- if or (not .Values.externalDatabase.sslmode) (not eq .Values.externalDatabase.sslmode "disable") }}
{{- printf "\"user=$PGUSER dbname=$PGDATABASE sslmode=disable host=$PGHOST password=$PGPASSWORD\"" }}
{{- if or .Values.postgresql.enabled }}
{{- printf "user=%s dbname=%s sslmode=disable host=%s password=%s" .Values.postgresql.global.postgresql.auth.username .Values.postgresql.global.postgresql.auth.database (include "matrix-sliding-sync.postgresql.hostname" .) .Values.postgresql.global.postgresql.auth.password }}
{{- else -}}
{{- printf "\"user=$PGUSER dbname=$PGDATABASE sslmode=$PGSSLMODE host=$PGHOST\"" }}
{{- printf "user=%s dbname=%s sslmode=%s sslmode=%s host=%s" .Values.externalDatabase.username .Values.externalDatabase.database .Values.externalDatabase.sslmode .Values.externalDatabase.hostname .Values.externalDatabase.password }}
{{- end }}
{{- end }}
{{- end }}
6 changes: 1 addition & 5 deletions charts/matrix-sliding-sync/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -104,11 +104,7 @@ spec:
{{- end }}
{{- if not .Values.syncv3.existingSecret }}
- name: SYNCV3_DB
{{- if or (not .Values.externalDatabase.sslmode) (not eq .Values.externalDatabase.sslmode "disable") }}
value: "user=$PGUSER dbname=$PGDATABASE sslmode=disable host=$PGHOST password=$PGPASSWORD"
{{- else -}}
value: "user=$PGUSER dbname=$PGDATABASE sslmode=$PGSSLMODE host=$PGHOST"
{{- end }}
value: {{ include "matrix-sliding-sync.dbConnString" . }}
{{- end }}
envFrom:
- secretRef:
Expand Down

0 comments on commit a8bbbf8

Please sign in to comment.