feat: upgrade to maple
This commit is contained in:
parent
546a0cf8f7
commit
54049ee28a
@ -2,7 +2,7 @@ variables:
|
||||
TUTOR_PLUGIN: cairn
|
||||
TUTOR_IMAGES: cairn-clickhouse cairn-superset
|
||||
TUTOR_PYPI_PRIVATE_PACKAGE: tutor-cairn
|
||||
OPENEDX_RELEASE: lilac
|
||||
OPENEDX_RELEASE: maple
|
||||
|
||||
include:
|
||||
- project: 'community/tutor-ci'
|
||||
|
||||
@ -52,6 +52,11 @@ spec:
|
||||
labels:
|
||||
name: cairn-vector
|
||||
spec:
|
||||
securityContext:
|
||||
runAsUser: 1000
|
||||
runAsGroup: 1000
|
||||
fsGroup: 1000
|
||||
fsGroupChangePolicy: "OnRootMismatch"
|
||||
serviceAccountName: cairn-vector
|
||||
# Run vector next to LMS
|
||||
affinity:
|
||||
@ -66,7 +71,7 @@ spec:
|
||||
topologyKey: kubernetes.io/hostname
|
||||
containers:
|
||||
- name: cairn-vector
|
||||
image: docker.io/timberio/vector:0.17.3-alpine
|
||||
image: docker.io/timberio/vector:0.18.1-alpine
|
||||
env:
|
||||
- name: VECTOR_SELF_NODE_NAME
|
||||
valueFrom:
|
||||
@ -94,6 +99,8 @@ spec:
|
||||
name: config
|
||||
subPath: k8s.toml
|
||||
readOnly: true
|
||||
securityContext:
|
||||
allowPrivilegeEscalation: false
|
||||
volumes:
|
||||
- name: data
|
||||
persistentVolumeClaim:
|
||||
@ -117,6 +124,11 @@ spec:
|
||||
selector:
|
||||
matchLabels:
|
||||
app.kubernetes.io/name: cairn-clickhouse
|
||||
securityContext:
|
||||
runAsUser: 1000
|
||||
runAsGroup: 1000
|
||||
fsGroup: 1000
|
||||
fsGroupChangePolicy: "OnRootMismatch"
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
@ -139,6 +151,8 @@ spec:
|
||||
ports:
|
||||
- containerPort: 8123
|
||||
- containerPort: 9000
|
||||
securityContext:
|
||||
allowPrivilegeEscalation: false
|
||||
volumes:
|
||||
- name: data
|
||||
persistentVolumeClaim:
|
||||
@ -165,6 +179,9 @@ spec:
|
||||
selector:
|
||||
matchLabels:
|
||||
app.kubernetes.io/name: cairn-superset
|
||||
securityContext:
|
||||
runAsUser: 1000
|
||||
runAsGroup: 1000
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
@ -182,6 +199,8 @@ spec:
|
||||
- mountPath: /scripts/clickhouse-auth.json
|
||||
name: clickhouse-auth
|
||||
subPath: auth.json
|
||||
securityContext:
|
||||
allowPrivilegeEscalation: false
|
||||
volumes:
|
||||
- name: config
|
||||
configMap:
|
||||
@ -204,6 +223,9 @@ spec:
|
||||
selector:
|
||||
matchLabels:
|
||||
app.kubernetes.io/name: cairn-superset-worker
|
||||
securityContext:
|
||||
runAsUser: 1000
|
||||
runAsGroup: 1000
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
@ -217,6 +239,8 @@ spec:
|
||||
- mountPath: /app/superset_config.py
|
||||
name: config
|
||||
subPath: superset_config.py
|
||||
securityContext:
|
||||
allowPrivilegeEscalation: false
|
||||
volumes:
|
||||
- name: config
|
||||
configMap:
|
||||
@ -233,6 +257,9 @@ spec:
|
||||
selector:
|
||||
matchLabels:
|
||||
app.kubernetes.io/name: cairn-superset-worker-beat
|
||||
securityContext:
|
||||
runAsUser: 1000
|
||||
runAsGroup: 1000
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
@ -246,6 +273,8 @@ spec:
|
||||
- mountPath: /app/superset_config.py
|
||||
name: config
|
||||
subPath: superset_config.py
|
||||
securityContext:
|
||||
allowPrivilegeEscalation: false
|
||||
volumes:
|
||||
- name: config
|
||||
configMap:
|
||||
@ -261,6 +290,9 @@ spec:
|
||||
selector:
|
||||
matchLabels:
|
||||
app.kubernetes.io/name: cairn-redis
|
||||
securityContext:
|
||||
runAsUser: 1000
|
||||
runAsGroup: 1000
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
@ -268,9 +300,11 @@ spec:
|
||||
spec:
|
||||
containers:
|
||||
- name: cairn-superset-worker
|
||||
image: docker.io/redis:5.0-alpine
|
||||
image: docker.io/redis:6.2.4-alpine
|
||||
ports:
|
||||
- containerPort: 6379
|
||||
securityContext:
|
||||
allowPrivilegeEscalation: false
|
||||
{% if CAIRN_RUN_POSTGRESQL %}
|
||||
---
|
||||
apiVersion: apps/v1
|
||||
@ -285,6 +319,11 @@ spec:
|
||||
app.kubernetes.io/name: cairn-postgresql
|
||||
strategy:
|
||||
type: Recreate
|
||||
securityContext:
|
||||
runAsUser: 70
|
||||
runAsGroup: 70
|
||||
fsGroup: 70
|
||||
fsGroupChangePolicy: "OnRootMismatch"
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
@ -309,6 +348,8 @@ spec:
|
||||
volumeMounts:
|
||||
- mountPath: /var/lib/postgresql/data
|
||||
name: data
|
||||
securityContext:
|
||||
allowPrivilegeEscalation: false
|
||||
volumes:
|
||||
- name: data
|
||||
persistentVolumeClaim:
|
||||
|
||||
@ -2,7 +2,7 @@
|
||||
|
||||
# log collection
|
||||
cairn-vector:
|
||||
image: docker.io/timberio/vector:0.17.3-alpine
|
||||
image: docker.io/timberio/vector:0.18.1-alpine
|
||||
volumes:
|
||||
- ../../data/cairn/vector:/var/lib/vector
|
||||
- ../plugins/cairn/apps/vector/local.toml:/etc/vector/vector.toml:ro
|
||||
@ -19,11 +19,20 @@ cairn-clickhouse:
|
||||
- ../plugins/cairn/apps/clickhouse/users.d/cairn.xml:/etc/clickhouse-server/users.d/cairn.xml:ro
|
||||
- ../plugins/cairn/apps/clickhouse/auth.json:/scripts/clickhouse-auth.json:ro
|
||||
- ../plugins/cairn/apps/clickhouse/migrations.d/:/etc/clickhouse-server/migrations.d/:ro
|
||||
user: "1000:1000"
|
||||
ulimits:
|
||||
nofile:
|
||||
soft: 262144
|
||||
hard: 262144
|
||||
restart: unless-stopped
|
||||
depends_on:
|
||||
- cairn-clickhouse-permissions
|
||||
cairn-clickhouse-permissions:
|
||||
image: {{ DOCKER_IMAGE_PERMISSIONS }}
|
||||
command: ["1000", "/data/clickhouse"]
|
||||
restart: on-failure
|
||||
volumes:
|
||||
- ../../data/cairn/clickhouse:/data/clickhouse
|
||||
{% endif %}
|
||||
cairn-superset:
|
||||
image: {{ CAIRN_SUPERSET_DOCKER_IMAGE }}
|
||||
@ -56,6 +65,7 @@ cairn-superset-worker-beat:
|
||||
cairn-redis:
|
||||
image: docker.io/redis:6.2.4-alpine
|
||||
restart: unless-stopped
|
||||
user: "1000:1000"
|
||||
{% if CAIRN_RUN_POSTGRESQL %}
|
||||
cairn-postgresql:
|
||||
image: docker.io/postgres:9.6-alpine
|
||||
@ -66,4 +76,13 @@ cairn-postgresql:
|
||||
volumes:
|
||||
- ../../data/cairn/postgresql:/var/lib/postgresql/data
|
||||
restart: unless-stopped
|
||||
user: "70:70"
|
||||
depends_on:
|
||||
- cairn-postgresql-permissions
|
||||
cairn-postgresql-permissions:
|
||||
image: {{ DOCKER_IMAGE_PERMISSIONS }}
|
||||
command: ["70", "/data/postgresql"]
|
||||
restart: on-failure
|
||||
volumes:
|
||||
- ../../data/cairn/postgresql:/data/postgresql
|
||||
{% endif %}
|
||||
|
||||
@ -1,4 +1,5 @@
|
||||
FROM docker.io/yandex/clickhouse-server:21.11.3.6
|
||||
# https://hub.docker.com/r/yandex/clickhouse-server/tags
|
||||
FROM docker.io/yandex/clickhouse-server:21.11.6.7
|
||||
|
||||
RUN apt update && apt install -y python3
|
||||
COPY ./scripts /scripts
|
||||
|
||||
@ -1,23 +1,19 @@
|
||||
# Superset image with additional database drivers
|
||||
# https://hub.docker.com/r/apache/superset
|
||||
# https://superset.apache.org/docs/databases/installing-database-drivers
|
||||
FROM docker.io/apache/superset:c829614c42a620dba7ce1d622fe8f52b6b56f492
|
||||
FROM docker.io/apache/superset:1.3.2
|
||||
USER superset
|
||||
|
||||
USER root
|
||||
# https://pypi.org/project/clickhouse-driver/
|
||||
# https://pypi.org/project/clickhouse-sqlalchemy/
|
||||
# https://pypi.org/project/mysqlclient/
|
||||
RUN pip install clickhouse-driver==0.2.2 mysqlclient==2.0.3
|
||||
RUN pip install clickhouse-sqlalchemy==0.1.6
|
||||
# Install from master to resolve issue: https://github.com/xzkostyan/clickhouse-sqlalchemy/issues/151
|
||||
# RUN pip install -I git+https://github.com/xzkostyan/clickhouse-sqlalchemy@master#egg=clickhouse-sqlalchemy
|
||||
RUN pip install clickhouse-driver==0.2.2 mysqlclient==2.1.0
|
||||
RUN pip install clickhouse-sqlalchemy==0.1.7
|
||||
|
||||
COPY ./scripts /scripts
|
||||
COPY --chown=superset:superset ./scripts /scripts
|
||||
RUN chmod a+x /scripts/*
|
||||
ENV PATH /scripts:${PATH}
|
||||
|
||||
USER superset
|
||||
|
||||
ENTRYPOINT []
|
||||
CMD gunicorn \
|
||||
--bind "0.0.0.0:8000" \
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user