Skip to content

Commit

Permalink
Merge branch 'main' into BC-5654-remove-usage-of-index
Browse files Browse the repository at this point in the history
  • Loading branch information
wolfganggreschus authored Nov 21, 2023
2 parents a1cef1b + bbd7075 commit 0aac3f3
Show file tree
Hide file tree
Showing 499 changed files with 5,286 additions and 1,778 deletions.
1 change: 1 addition & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -24,4 +24,5 @@ COPY scripts/ldapSync.sh /schulcloud-server/scripts/
RUN npm run build

ENV NODE_ENV=production
ENV NO_COLOR="true"
CMD npm run start
2 changes: 1 addition & 1 deletion TODO.md
Original file line number Diff line number Diff line change
Expand Up @@ -88,4 +88,4 @@
- naming of dtos and dto-files: api vs domain, we leave out "dto" suffix for simplicity (we know that they are dtos) and instead append a specific suffix:
e.g.
api: <PaginationParams, pagination.params.ts>, <CreatNewsParams, create-news.params.ts>, <NewsResponse, news.response.ts>
domain: <ICreateNews, create-news.interface.ts>, <News, news.entity.ts>
domain: <CreateNews, create-news.interface.ts>, <News, news.entity.ts>
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,13 @@ metadata:
namespace: {{ NAMESPACE }}
labels:
app: amqp-files
app.kubernetes.io/part-of: schulcloud-verbund
app.kubernetes.io/version: {{ SCHULCLOUD_SERVER_IMAGE_TAG }}
app.kubernetes.io/name: amqp-files
app.kubernetes.io/component: files
app.kubernetes.io/managed-by: ansible
git.branch: {{ SCHULCLOUD_SERVER_BRANCH_NAME }}
git.repo: {{ SCHULCLOUD_SERVER_REPO_NAME }}
spec:
replicas: {{ AMQP_FILE_STORAGE_REPLICAS|default("1", true) }}
strategy:
Expand All @@ -21,6 +28,13 @@ spec:
metadata:
labels:
app: amqp-files
app.kubernetes.io/part-of: schulcloud-verbund
app.kubernetes.io/version: {{ SCHULCLOUD_SERVER_IMAGE_TAG }}
app.kubernetes.io/name: amqp-files
app.kubernetes.io/component: files
app.kubernetes.io/managed-by: ansible
git.branch: {{ SCHULCLOUD_SERVER_BRANCH_NAME }}
git.repo: {{ SCHULCLOUD_SERVER_REPO_NAME }}
spec:
securityContext:
runAsUser: 1000
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,18 @@ metadata:
labels:
app: api
cronjob: delete-s3-files
app.kubernetes.io/part-of: schulcloud-verbund
app.kubernetes.io/version: {{ SCHULCLOUD_SERVER_IMAGE_TAG }}
app.kubernetes.io/name: delete-s3-files
app.kubernetes.io/component: files
app.kubernetes.io/managed-by: ansible
git.branch: {{ SCHULCLOUD_SERVER_BRANCH_NAME }}
git.repo: {{ SCHULCLOUD_SERVER_REPO_NAME }}
name: api-delete-s3-files-cronjob
spec:
concurrencyPolicy: Forbid
schedule: "{{ SERVER_FILE_DELETION_CRONJOB_SCHEDULE|default("@hourly", true) }}"
jobTemplate:
labels:
app: api
cronjob: delete-s3-files
spec:
template:
spec:
Expand All @@ -34,3 +38,14 @@ spec:
cpu: {{ API_CPU_REQUESTS|default("100m", true) }}
memory: {{ API_MEMORY_REQUESTS|default("150Mi", true) }}
restartPolicy: OnFailure
metadata:
labels:
app: api
cronjob: delete-s3-files
app.kubernetes.io/part-of: schulcloud-verbund
app.kubernetes.io/version: {{ SCHULCLOUD_SERVER_IMAGE_TAG }}
app.kubernetes.io/name: delete-s3-files
app.kubernetes.io/component: files
app.kubernetes.io/managed-by: ansible
git.branch: {{ SCHULCLOUD_SERVER_BRANCH_NAME }}
git.repo: {{ SCHULCLOUD_SERVER_REPO_NAME }}
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,13 @@ metadata:
namespace: {{ NAMESPACE }}
labels:
app: api-files
app.kubernetes.io/part-of: schulcloud-verbund
app.kubernetes.io/version: {{ SCHULCLOUD_SERVER_IMAGE_TAG }}
app.kubernetes.io/name: api-files
app.kubernetes.io/component: files
app.kubernetes.io/managed-by: ansible
git.branch: {{ SCHULCLOUD_SERVER_BRANCH_NAME }}
git.repo: {{ SCHULCLOUD_SERVER_REPO_NAME }}
spec:
replicas: {{ API_FILE_STORAGE_REPLICAS|default("1", true) }}
strategy:
Expand All @@ -21,6 +28,13 @@ spec:
metadata:
labels:
app: api-files
app.kubernetes.io/part-of: schulcloud-verbund
app.kubernetes.io/version: {{ SCHULCLOUD_SERVER_IMAGE_TAG }}
app.kubernetes.io/name: api-files
app.kubernetes.io/component: files
app.kubernetes.io/managed-by: ansible
git.branch: {{ SCHULCLOUD_SERVER_BRANCH_NAME }}
git.repo: {{ SCHULCLOUD_SERVER_REPO_NAME }}
spec:
securityContext:
runAsUser: 1000
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,13 @@ metadata:
namespace: {{ NAMESPACE }}
labels:
app: api-fwu
app.kubernetes.io/part-of: schulcloud-verbund
app.kubernetes.io/version: {{ SCHULCLOUD_SERVER_IMAGE_TAG }}
app.kubernetes.io/name: api-fwu
app.kubernetes.io/component: fwu
app.kubernetes.io/managed-by: ansible
git.branch: {{ SCHULCLOUD_SERVER_BRANCH_NAME }}
git.repo: {{ SCHULCLOUD_SERVER_REPO_NAME }}
spec:
replicas: {{ API_FWU_LEARNING_CONTENTS_REPLICAS|default("1", true) }}
strategy:
Expand All @@ -21,6 +28,13 @@ spec:
metadata:
labels:
app: api-fwu
app.kubernetes.io/part-of: schulcloud-verbund
app.kubernetes.io/version: {{ SCHULCLOUD_SERVER_IMAGE_TAG }}
app.kubernetes.io/name: api-fwu
app.kubernetes.io/component: fwu
app.kubernetes.io/managed-by: ansible
git.branch: {{ SCHULCLOUD_SERVER_BRANCH_NAME }}
git.repo: {{ SCHULCLOUD_SERVER_REPO_NAME }}
spec:
securityContext:
runAsUser: 1000
Expand Down
14 changes: 14 additions & 0 deletions ansible/roles/schulcloud-server-core/templates/deployment.yml.j2
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,13 @@ metadata:
namespace: {{ NAMESPACE }}
labels:
app: api
app.kubernetes.io/part-of: schulcloud-verbund
app.kubernetes.io/version: {{ SCHULCLOUD_SERVER_IMAGE_TAG }}
app.kubernetes.io/name: api
app.kubernetes.io/component: server
app.kubernetes.io/managed-by: ansible
git.branch: {{ SCHULCLOUD_SERVER_BRANCH_NAME }}
git.repo: {{ SCHULCLOUD_SERVER_REPO_NAME }}
spec:
replicas: {{ API_REPLICAS|default("1", true) }}
strategy:
Expand All @@ -21,6 +28,13 @@ spec:
metadata:
labels:
app: api
app.kubernetes.io/part-of: schulcloud-verbund
app.kubernetes.io/version: {{ SCHULCLOUD_SERVER_IMAGE_TAG }}
app.kubernetes.io/name: api
app.kubernetes.io/component: server
app.kubernetes.io/managed-by: ansible
git.branch: {{ SCHULCLOUD_SERVER_BRANCH_NAME }}
git.repo: {{ SCHULCLOUD_SERVER_REPO_NAME }}
spec:
securityContext:
runAsUser: 1000
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,4 @@ metadata:
labels:
app: preview-generator
data:
NEST_LOG_LEVEL: "info"
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,13 @@ metadata:
namespace: {{ NAMESPACE }}
labels:
app: preview-generator
app.kubernetes.io/part-of: schulcloud-verbund
app.kubernetes.io/version: {{ SCHULCLOUD_SERVER_IMAGE_TAG }}
app.kubernetes.io/name: preview-generator
app.kubernetes.io/component: files
app.kubernetes.io/managed-by: ansible
git.branch: {{ SCHULCLOUD_SERVER_BRANCH_NAME }}
git.repo: {{ SCHULCLOUD_SERVER_REPO_NAME }}
spec:
replicas: {{ AMQP_FILE_PREVIEW_REPLICAS|default("1", true) }}
strategy:
Expand All @@ -21,6 +28,13 @@ spec:
metadata:
labels:
app: preview-generator
app.kubernetes.io/part-of: schulcloud-verbund
app.kubernetes.io/version: {{ SCHULCLOUD_SERVER_IMAGE_TAG }}
app.kubernetes.io/name: preview-generator
app.kubernetes.io/component: files
app.kubernetes.io/managed-by: ansible
git.branch: {{ SCHULCLOUD_SERVER_BRANCH_NAME }}
git.repo: {{ SCHULCLOUD_SERVER_REPO_NAME }}
spec:
securityContext:
runAsUser: 1000
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,13 @@ metadata:
namespace: {{ NAMESPACE }}
labels:
app: preview-generator
app.kubernetes.io/part-of: schulcloud-verbund
app.kubernetes.io/version: {{ SCHULCLOUD_SERVER_IMAGE_TAG }}
app.kubernetes.io/name: preview-generator
app.kubernetes.io/component: files
app.kubernetes.io/managed-by: ansible
git.branch: {{ SCHULCLOUD_SERVER_BRANCH_NAME }}
git.repo: {{ SCHULCLOUD_SERVER_REPO_NAME }}
spec:
scaleTargetRef:
name: preview-generator-deployment
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,13 @@ metadata:
namespace: {{ NAMESPACE }}
labels:
app: api-h5p
app.kubernetes.io/part-of: schulcloud-verbund
app.kubernetes.io/version: {{ SCHULCLOUD_SERVER_IMAGE_TAG }}
app.kubernetes.io/name: api-h5p
app.kubernetes.io/component: h5p
app.kubernetes.io/managed-by: ansible
git.branch: {{ SCHULCLOUD_SERVER_BRANCH_NAME }}
git.repo: {{ SCHULCLOUD_SERVER_REPO_NAME }}
spec:
replicas: {{ API_H5P_EDITOR_REPLICAS|default("1", true) }}
strategy:
Expand All @@ -21,6 +28,13 @@ spec:
metadata:
labels:
app: api-h5p
app.kubernetes.io/part-of: schulcloud-verbund
app.kubernetes.io/version: {{ SCHULCLOUD_SERVER_IMAGE_TAG }}
app.kubernetes.io/name: api-h5p
app.kubernetes.io/component: h5p
app.kubernetes.io/managed-by: ansible
git.branch: {{ SCHULCLOUD_SERVER_BRANCH_NAME }}
git.repo: {{ SCHULCLOUD_SERVER_REPO_NAME }}
spec:
securityContext:
runAsUser: 1000
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,13 @@ metadata:
namespace: {{ NAMESPACE }}
labels:
app: management-deployment
app.kubernetes.io/part-of: schulcloud-verbund
app.kubernetes.io/version: {{ SCHULCLOUD_SERVER_IMAGE_TAG }}
app.kubernetes.io/name: management-deployment
app.kubernetes.io/component: management
app.kubernetes.io/managed-by: ansible
git.branch: {{ SCHULCLOUD_SERVER_BRANCH_NAME }}
git.repo: {{ SCHULCLOUD_SERVER_REPO_NAME }}
spec:
replicas: {{ API_MANAGEMENT_REPLICAS|default("1", true) }}
strategy:
Expand All @@ -20,6 +27,13 @@ spec:
metadata:
labels:
app: management-deployment
app.kubernetes.io/part-of: schulcloud-verbund
app.kubernetes.io/version: {{ SCHULCLOUD_SERVER_IMAGE_TAG }}
app.kubernetes.io/name: management-deployment
app.kubernetes.io/component: management
app.kubernetes.io/managed-by: ansible
git.branch: {{ SCHULCLOUD_SERVER_BRANCH_NAME }}
git.repo: {{ SCHULCLOUD_SERVER_REPO_NAME }}
spec:
securityContext:
runAsUser: 1000
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,13 @@ metadata:
namespace: {{ NAMESPACE }}
labels:
app: api-ldapsync-cronjob
app.kubernetes.io/part-of: schulcloud-verbund
app.kubernetes.io/version: {{ SCHULCLOUD_SERVER_IMAGE_TAG }}
app.kubernetes.io/name: api-ldapsync-cronjob
app.kubernetes.io/component: sync
app.kubernetes.io/managed-by: ansible
git.branch: {{ SCHULCLOUD_SERVER_BRANCH_NAME }}
git.repo: {{ SCHULCLOUD_SERVER_REPO_NAME }}
name: api-ldapsync-full-cronjob
spec:
schedule: "{{ SERVER_LDAP_SYNC_FULL_CRONJOB|default("0 3 * * 3,6", true) }}"
Expand All @@ -30,3 +37,13 @@ spec:
cpu: {{ API_CPU_REQUESTS|default("100m", true) }}
memory: {{ API_MEMORY_REQUESTS|default("150Mi", true) }}
restartPolicy: OnFailure
metadata:
labels:
app: api-ldapsync-cronjob
app.kubernetes.io/part-of: schulcloud-verbund
app.kubernetes.io/version: {{ SCHULCLOUD_SERVER_IMAGE_TAG }}
app.kubernetes.io/name: api-ldapsync-cronjob
app.kubernetes.io/component: sync
app.kubernetes.io/managed-by: ansible
git.branch: {{ SCHULCLOUD_SERVER_BRANCH_NAME }}
git.repo: {{ SCHULCLOUD_SERVER_REPO_NAME }}
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,13 @@ metadata:
namespace: {{ NAMESPACE }}
labels:
app: api-worker
app.kubernetes.io/part-of: schulcloud-verbund
app.kubernetes.io/version: {{ SCHULCLOUD_SERVER_IMAGE_TAG }}
app.kubernetes.io/name: api-worker
app.kubernetes.io/component: sync
app.kubernetes.io/managed-by: ansible
git.branch: {{ SCHULCLOUD_SERVER_BRANCH_NAME }}
git.repo: {{ SCHULCLOUD_SERVER_REPO_NAME }}
spec:
replicas: {{ API_WORKER_REPLICAS|default("2", true) }}
strategy:
Expand All @@ -21,6 +28,13 @@ spec:
metadata:
labels:
app: api-worker
app.kubernetes.io/part-of: schulcloud-verbund
app.kubernetes.io/version: {{ SCHULCLOUD_SERVER_IMAGE_TAG }}
app.kubernetes.io/name: api-worker
app.kubernetes.io/component: sync
app.kubernetes.io/managed-by: ansible
git.branch: {{ SCHULCLOUD_SERVER_BRANCH_NAME }}
git.repo: {{ SCHULCLOUD_SERVER_REPO_NAME }}
spec:
securityContext:
runAsUser: 1000
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,19 @@ metadata:
namespace: {{ NAMESPACE }}
labels:
app: api-tsp-sync-cronjob
app.kubernetes.io/part-of: schulcloud-verbund
app.kubernetes.io/version: {{ SCHULCLOUD_SERVER_IMAGE_TAG }}
app.kubernetes.io/name: api-tsp-sync-cronjob
app.kubernetes.io/component: sync
app.kubernetes.io/managed-by: ansible
git.branch: {{ SCHULCLOUD_SERVER_BRANCH_NAME }}
git.repo: {{ SCHULCLOUD_SERVER_REPO_NAME }}
name: api-tsp-sync-base-cronjob
spec:
schedule: "{{ SERVER_TSP_SYNC_BASE_CRONJOB|default("9 3 * * *", true) }}"
jobTemplate:
spec:
template:
metadata:
labels:
app: api-tsp-sync-cronjob
spec:
containers:
- name: api-tsp-sync-base-cronjob
Expand All @@ -23,3 +27,13 @@ spec:
command: ['/bin/sh','-c']
args: ['curl -H "X-API-Key: $SYNC_API_KEY" "http://{{ API_TSP_SYNC_SVC|default("api-tsp-sync-svc", true) }}:3030/api/v1/sync?target=tsp-base" | python3 -m json.tool']
restartPolicy: OnFailure
metadata:
labels:
app: api-tsp-sync-cronjob
app.kubernetes.io/part-of: schulcloud-verbund
app.kubernetes.io/version: {{ SCHULCLOUD_SERVER_IMAGE_TAG }}
app.kubernetes.io/name: api-tsp-sync-cronjob
app.kubernetes.io/component: sync
app.kubernetes.io/managed-by: ansible
git.branch: {{ SCHULCLOUD_SERVER_BRANCH_NAME }}
git.repo: {{ SCHULCLOUD_SERVER_REPO_NAME }}
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,13 @@ metadata:
namespace: {{ NAMESPACE }}
labels:
app: api-tsp-sync
app.kubernetes.io/part-of: schulcloud-verbund
app.kubernetes.io/version: {{ SCHULCLOUD_SERVER_IMAGE_TAG }}
app.kubernetes.io/name: api-tsp-sync
app.kubernetes.io/component: sync
app.kubernetes.io/managed-by: ansible
git.branch: {{ SCHULCLOUD_SERVER_BRANCH_NAME }}
git.repo: {{ SCHULCLOUD_SERVER_REPO_NAME }}
spec:
replicas: {{ API_TSP_REPLICAS|default("1", true) }}
strategy:
Expand All @@ -21,6 +28,13 @@ spec:
metadata:
labels:
app: api-tsp-sync
app.kubernetes.io/part-of: schulcloud-verbund
app.kubernetes.io/version: {{ SCHULCLOUD_SERVER_IMAGE_TAG }}
app.kubernetes.io/name: api-tsp-sync
app.kubernetes.io/component: sync
app.kubernetes.io/managed-by: ansible
git.branch: {{ SCHULCLOUD_SERVER_BRANCH_NAME }}
git.repo: {{ SCHULCLOUD_SERVER_REPO_NAME }}
spec:
securityContext:
runAsUser: 1000
Expand Down
Loading

0 comments on commit 0aac3f3

Please sign in to comment.