Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

K8s minor fix #61

Merged
merged 6 commits into from
Sep 11, 2024
Merged
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
1 change: 0 additions & 1 deletion .github/workflows/linter.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -44,5 +44,4 @@ jobs:

- name: Run chart-testing (install)
if: steps.list-changed.outputs.changed == 'true'
#run: ct install --helm-extra-args "-f tests/amd64.yaml" --target-branch ${{ github.event.repository.default_branch }}
run: ct install --target-branch ${{ github.event.repository.default_branch }}
2 changes: 1 addition & 1 deletion charts/mint/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -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: 3.3.2
version: 3.3.3-alpha.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
# follow Semantic Versioning. They should reflect the version the application is using.
Expand Down
9 changes: 9 additions & 0 deletions charts/mint/templates/ensemble-manager-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,15 @@ data:
},
{{- end}}

{{- if eq .Values.external_services.kubernetes.enabled true }}
"kubernetes": {
"namespace": {{ .Values.external_services.kubernetes.namespace | quote }},
"use": {{ .Values.external_services.kubernetes.enabled }},
"cpu_limit": {{ .Values.external_services.kubernetes.cpu_limit | quote }},
"memory_limit": {{ .Values.external_services.kubernetes.memory_limit | quote }}
},
{{- end}}

"auth_server": {{ .Values.auth.url | quote }},
"auth_realm": {{ .Values.auth.realm | quote }},
"auth_client_id": {{ .Values.auth.ui_client_id | quote }},
Expand Down
14 changes: 5 additions & 9 deletions charts/mint/templates/ensemble-manager.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,16 +13,7 @@ spec:
- name: "http"
port: 80
targetPort: 3000
{{ if eq .Values.service.type "NodePort" }}
nodePort: {{ include "helm.ensemble_manager_node_port" . }}
{{ end }}
protocol: TCP
- name: "datacatalog"
port: 8080
targetPort: 80
{{ if eq .Values.service.type "NodePort" }}
nodePort: {{ include "helm.ensemble_manager_data_node_port" . }}
{{ end }}
selector:
app: {{ include "mint.prefix" . }}-ensemble-manager
---
Expand Down Expand Up @@ -72,6 +63,9 @@ spec:
resources:
{{- toYaml .resources | nindent 12 }}
{{- end }}
ports:
- containerPort: 3000
name: api
env:
- name: TMPDIR
value: /home/node/app/data/temp
Expand All @@ -92,6 +86,8 @@ spec:
{{- with .Values.components.ensemble_manager }}
image: "nginx"
imagePullPolicy: {{ .image.pullPolicy }}
ports:
- containerPort: 80
resources:
{{- toYaml .resources | nindent 12 }}
{{- end }}
Expand Down
7 changes: 0 additions & 7 deletions charts/mint/templates/ingress-ensemble-manager.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -39,13 +39,6 @@ spec:
- host: {{ .host | quote }}
http:
paths:
- path: /data/
pathType: ImplementationSpecific
backend:
service:
name: {{ $fullName }}-ensemble-manager
port:
number: 8080
{{- range .paths }}
- path: {{ .path }}
{{- if and .pathType (semverCompare ">=1.18-0" $.Capabilities.KubeVersion.GitVersion) }}
Expand Down
9 changes: 8 additions & 1 deletion charts/mint/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -258,7 +258,7 @@ components:
api_version: v1
image:
repository: mintproject/ensemble-manager
tag: be57e330e06c1ba73295b3eb500c352384e9dbca
tag: 3e1f40865e647a8025b06ac63178b0eed64aed3e
pullPolicy: IfNotPresent
resources: {}
serviceAccountName: default
Expand Down Expand Up @@ -302,6 +302,8 @@ components:
storageClass: ""
size: 10Gi
dataSource: {}
accessModes:
- ReadWriteOnce
existingClaim: ""
selector: {}
annotations:
Expand Down Expand Up @@ -391,3 +393,8 @@ external_services:
type: "S3"
region: ""
bucket: ""
kubernetes:
enabled: false
namespace: "default"
cpu_limit: "256m"
memory_limit: "512Mi"
36 changes: 36 additions & 0 deletions docs/graphql/remove-regions.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
The following SQL query will remove all region geometry that are not California:

```sql
SELECT
rg.region_id
FROM
region
INNER JOIN
region_geometry rg
ON
region.id = rg.region_id
WHERE
region.parent_region_id IS NULL
AND region.parent_region_id != 'texas';
```

```sql
DELETE FROM region_geometry
USING region
WHERE region_geometry.region_id = region.id
AND region.parent_region_id != 'texas';
```

The following SQL query will remove all region geometry that are not California and are not a child of California:

```sql
DELETE FROM region
WHERE region.parent_region_id != 'texas' AND region.id != 'texas';
```

Delete all region that the id is not `texas` and the `parent_region_id` is `NULL`:

```sql
DELETE FROM region
WHERE region.parent_region_id IS NULL AND region.id != 'texas';
```
Loading
Loading