-
Notifications
You must be signed in to change notification settings - Fork 152
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #194 from camicroscope/develop
For 3.9.11
- Loading branch information
Showing
15 changed files
with
567 additions
and
289 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
[mysqld] | ||
datadir=/data/pathdb/mysql | ||
user=mysql | ||
skip-name-resolve | ||
symbolic-links=0 | ||
max_connections = 150 | ||
max_user_connections = 150 | ||
key_buffer = 36M | ||
myisam_sort_buffer_size = 64M | ||
join_buffer_size = 2M | ||
read_buffer_size = 2M | ||
sort_buffer_size = 3M | ||
table_cache = 1024 | ||
thread_cache_size = 286 | ||
interactive_timeout = 25 | ||
wait_timeout = 1800 | ||
connect_timeout = 10 | ||
max_allowed_packet = 16M | ||
max_connect_errors = 1000 | ||
query_cache_limit = 1M | ||
query_cache_size = 0 | ||
query_cache_type = 0 | ||
tmp_table_size = 16M | ||
|
||
innodb-flush-log-at-trx-commit=2 | ||
innodb_file_per_table=ON | ||
innodb_buffer_pool_size = 4G | ||
innodb_log_file_size=512M | ||
innodb_stats_on_metadata=0 | ||
innodb_buffer_pool_instances=4 | ||
|
||
[mysqld_safe] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,16 @@ | ||
# Kubernetes Version of caMicroscope and quip | ||
|
||
## FYI | ||
- ALL host mounts are ignored, at least as of now. | ||
Note that the images persistent volume starts empty. Please replace `emptyDir` with an alternate source if required. | ||
|
||
## Develop | ||
## develop and caMicroscope | ||
run `kubectl apply -f develop.yml` to create, cleanup.sh to remove *everything* when done. | ||
|
||
When using minikube, run `minikube tunnel` then `minikube service ca-back --url` to get the url. | ||
When using minikube, run `minikube tunnel` then `minikube service back --url` to get the url. | ||
|
||
|
||
## caMicroscope | ||
TODO | ||
For instances where security is enabled, after generating keys in 'jwt_keys' and confiuring login.html, run `camicroscope_add_config.sh` or some modification thereof as needed for your configuration. | ||
|
||
## quip | ||
TODO | ||
(worried about non-optional config mounts and image mount in particular) | ||
* Setup required configuration by running `pathdb_add_config.sh` | ||
* Change the persistent volume configuration in quip-pathdb.yml to match where your slide and other data files are. | ||
* Run `kubectl apply -f quip-pathdb.yml` to create the pod | ||
* When using minikube, run `minikube tunnel` then `minikube service pathdb --url` to get the url. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
#!/usr/bin/env bash | ||
kubectl create secret generic camic-jwt-keys --from-file=key=../jwt_keys/key --from-file=key.pub=../jwt_keys/key.pub | ||
kubectl create configmap camic-login --from-file=login.html=../config/login.html |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
#!/usr/bin/env bash | ||
kubectl create secret generic camic-jwt-keys --from-file=key=../jwt_keys/key --from-file=key.pub=../jwt_keys/key.pub | ||
kubectl create configmap pathdb-sites --from-file=settings.php=../config/pathdb/settings.php | ||
kubectl create configmap pathdb-config --from-file=../config/ --from-file=httpd.conf=../config/httpd.conf.template |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
#!/bin/bash | ||
kubectl delete --all pvc | ||
kubectl delete --all pv |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,190 @@ | ||
apiVersion: v1 | ||
kind: List | ||
items: | ||
- apiVersion: v1 | ||
kind: PersistentVolume | ||
metadata: | ||
name: pv-images | ||
labels: | ||
type: local | ||
spec: | ||
storageClassName: manual | ||
capacity: | ||
storage: 10Gi | ||
accessModes: | ||
- ReadWriteOnce | ||
hostPath: | ||
path: /data/images | ||
- apiVersion: v1 | ||
kind: PersistentVolume | ||
metadata: | ||
name: pv-data | ||
labels: | ||
type: local | ||
spec: | ||
storageClassName: manual | ||
capacity: | ||
storage: 10Gi | ||
accessModes: | ||
- ReadWriteOnce | ||
hostPath: | ||
path: /data | ||
- apiVersion: v1 | ||
kind: PersistentVolumeClaim | ||
metadata: | ||
name: pv-data-claim | ||
spec: | ||
storageClassName: manual | ||
volumeName: pv-data | ||
accessModes: | ||
- ReadWriteOnce | ||
resources: | ||
requests: | ||
storage: 10Gi | ||
- apiVersion: v1 | ||
kind: PersistentVolumeClaim | ||
metadata: | ||
name: pv-images-claim | ||
spec: | ||
storageClassName: manual | ||
volumeName: pv-images | ||
accessModes: | ||
- ReadWriteOnce | ||
resources: | ||
requests: | ||
storage: 10Gi | ||
- apiVersion: apps/v1 | ||
kind: Deployment | ||
metadata: | ||
name: pathdb | ||
labels: | ||
service: pathdb | ||
spec: | ||
selector: | ||
matchLabels: | ||
service: pathdb | ||
template: | ||
metadata: | ||
labels: | ||
service: pathdb | ||
spec: | ||
hostAliases: | ||
- ip: "127.0.0.1" | ||
hostnames: | ||
- "quip-pathdb" | ||
- "quip-imageloader" | ||
- "quip-segloader" | ||
- "quip-hmloader" | ||
- "ca-iip" | ||
- "ca-mongo" | ||
- "ca-back" | ||
- "ca-security" | ||
volumes: | ||
- name: images | ||
persistentVolumeClaim: | ||
claimName: pv-images-claim | ||
- name: data | ||
persistentVolumeClaim: | ||
claimName: pv-data-claim | ||
- name: pathdb-files | ||
emptyDir: {} | ||
- name: jwtkeys | ||
secret: | ||
secretName: camic-jwt-keys | ||
- name: pathdb-sites | ||
configMap: | ||
name: pathdb-sites | ||
- name: pathdb-config | ||
configMap: | ||
name: pathdb-config | ||
containers: | ||
- name: mongo | ||
image: mongo:4.2-bionic | ||
ports: | ||
- containerPort: 27017 | ||
- name: back | ||
image: ghcr.io/camicroscope/caracal:master | ||
ports: | ||
- containerPort: 4010 | ||
volumeMounts: | ||
- name: jwtkeys | ||
mountPath: /src/keys/ | ||
env: | ||
- name: PORT | ||
value: "4010" | ||
- name: JWK_URL | ||
value: "https://www.googleapis.com/oauth2/v3/certs" | ||
- name: IIP_PATH | ||
value: "http://localhost:8080/fcgi-bin/iipsrv.fcgi" | ||
- name: MONGO_URI | ||
value: "mongodb://localhost" | ||
- name: GENERATE_KEY_IF_MISSING | ||
value: "true" | ||
- name: "DEFAULT_USER_TYPE" | ||
value: "Editor" | ||
- name: "DISABLE_SEC" | ||
value: "true" | ||
- name: "DISABLE_CSP" | ||
value: "true" | ||
- name: iip | ||
image: camicroscope/iipimage:latest | ||
ports: | ||
- containerPort: 8080 | ||
volumeMounts: | ||
- name: images | ||
mountPath: /data/images/ | ||
- name: imageloader | ||
image: camicroscope/pathdb-imageloader:latest | ||
volumeMounts: | ||
- name: data | ||
mountPath: /data/ | ||
- name: images | ||
mountPath: /data/images/ | ||
- name: heatmaploader | ||
image: camicroscope/pathdb-heatmaploader:latest | ||
volumeMounts: | ||
- name: data | ||
mountPath: /mnt/data/ | ||
env: | ||
- name: "TZ" | ||
value: "America/New_York" | ||
- name: "DEBIAN_FRONTEND" | ||
value: "noninteractive" | ||
- name: pathdb | ||
image: camicroscope/pathdb:latest | ||
ports: | ||
- containerPort: 443 | ||
- containerPort: 80 | ||
volumeMounts: | ||
- name: data | ||
mountPath: /data/ | ||
- name: images | ||
mountPath: /data/pathdb/files/wsi | ||
- name: pathdb-sites | ||
mountPath: /quip/web/sites/default/ | ||
- name: pathdb-files | ||
mountPath: /quip/web/sites/default/files/ | ||
- name: pathdb-config | ||
mountPath: /config/ | ||
- name: jwtkeys | ||
mountPath: /keys/ | ||
- apiVersion: v1 | ||
kind: Service | ||
metadata: | ||
name: pathdb | ||
labels: | ||
service: pathdb | ||
spec: | ||
type: NodePort | ||
selector: | ||
service: pathdb | ||
ports: | ||
- name: "443" | ||
port: 443 | ||
targetPort: 443 | ||
nodePort: 30443 | ||
- name: "80" | ||
port: 80 | ||
targetPort: 80 | ||
nodePort: 30180 | ||
type: LoadBalancer |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.