1
0
mirror of https://github.com/coltoneshaw/CS-Repro-Mattermost.git synced 2025-12-23 10:01:30 +01:00

1 Commits

Author SHA1 Message Date
mk
d0a1dce9a6 test 2024-12-19 12:17:54 +01:00
2 changed files with 38 additions and 44 deletions

View File

@@ -6,12 +6,6 @@ logs:
@echo "Done"
setup-mattermost:
@cp ./files/mattermost/defaultConfig.json ./volumes/mattermost/config
@cp ./files/mattermost/replicaConfig.json ./volumes/mattermost/config
@cp ./files/mattermost/rtcdConfig.json ./volumes/mattermost/config
@cp ./files/mattermost/samlCert.crt ./volumes/mattermost/config
@cp ./license.mattermost ./volumes/mattermost/config/license.mattermost-enterprise
@./scripts/mattermost.sh setup
check-mattermost:
@@ -28,7 +22,7 @@ echo-logins:
run:
@echo "Starting..."
@make restore-keycloak
#@make restore-keycloak
@make run-core
@make setup-mattermost
@make echo-logins
@@ -36,7 +30,7 @@ run:
run-core:
@echo "Starting the core services... hang in there."
@docker-compose up -d postgres openldap prometheus grafana elasticsearch mattermost keycloak mitmproxy
@docker-compose up -d postgres openldap prometheus grafana elasticsearch mattermost keycloak #mitmproxy
run-db-replicas:
@echo "Starting with replicas. Hang in there..."
@@ -50,11 +44,6 @@ run-mm-replicas:
@echo "Starting Mattermost replicas. Hang in there..."
@docker exec -it cs-repro-mattermost mmctl config set ClusterSettings.Enable true --local
@docker-compose down mattermost
@cp ./files/mattermost/defaultConfig.json ./volumes/mattermost_2/config
@cp ./files/mattermost/replicaConfig.json ./volumes/mattermost_2/config
@cp ./files/mattermost/rtcdConfig.json ./volumes/mattermost_2/config
@cp ./files/mattermost/samlCert.crt ./volumes/mattermost_2/config
@cp ./license.mattermost ./volumes/mattermost/mattermost_2/license.mattermost-enterprise
@docker-compose up -d mattermost mattermost-2
@docker exec -it -u root cs-repro-mattermost-2 /bin/bash update-ca-certificates
@echo "Should be up and running. Go crazy."

View File

@@ -66,8 +66,8 @@ services:
depends_on:
postgres:
condition: service_healthy
mitmproxy:
condition: service_started
#mitmproxy:
# condition: service_started
image: mattermost/mattermost-enterprise-edition:release-9.11
restart: unless-stopped
security_opt:
@@ -86,13 +86,18 @@ services:
- ./volumes/mattermost/plugins:/mattermost/plugins:rw
- ./volumes/mattermost/client/plugins:/mattermost/client/plugins:rw
- ./volumes/mattermost/bleve-indexes:/mattermost/bleve-indexes:rw
#- ./license.mattermost:/mattermost/config/license.mattermost-enterprise:ro
#- ./files/mattermost/samlCert.crt:/mattermost/config/saml-cert.crt
#- ./files/mattermost/defaultConfig.json:/mattermost/config/defaultConfig.json:ro
#- ./files/mattermost/replicaConfig.json:/mattermost/config/replicaConfig.json:ro
#- ./files/mattermost/rtcdConfig.json:/mattermost/config/rtcdConfig.json:ro
## Files are required for the mitmproxy on the box
- ./files/mitmproxy/mitmproxy-ca.pem:/etc/ssl/certs/mitmproxy-ca.pem
- ./files/mitmproxy/mitmproxy-dhparam.pem:/etc/ssl/certs/mitmproxy-dhparam.pem
environment:
# - HTTP_PROXY=http://cs-repro-mitmproxy:8080
# - HTTPS_PROXY=http://cs-repro-mitmproxy:8080
#- HTTP_PROXY=http://cs-repro-mitmproxy:8080
#- HTTPS_PROXY=http://cs-repro-mitmproxy:8080
- MM_SqlSettings_DriverName=postgres
- MM_SqlSettings_DataSource=postgres://mmuser:mmuser_password@cs-repro-postgres:5432/mattermost?sslmode=disable&connect_timeout=10&binary_parameters=yes
- MM_SAMLSETTINGS_IDPCERTIFICATEFILE=/mattermost/config/saml-cert.crt
@@ -110,7 +115,7 @@ services:
container_name: cs-repro-keycloak
restart: unless-stopped
platform: linux/amd64
image: quay.io/keycloak/keycloak:18.0.0
image: quay.io/keycloak/keycloak:latest
volumes:
- ./volumes/keycloak:/opt/keycloak/data:rw
environment:
@@ -199,9 +204,9 @@ services:
depends_on:
postgres:
condition: service_healthy
mitmproxy:
condition: service_started
image: mattermost/mattermost-enterprise-edition:release-9.7
#mitmproxy:
# condition: service_started
image: mattermost/mattermost-enterprise-edition:release-9.11
restart: unless-stopped
security_opt:
- no-new-privileges:true
@@ -219,10 +224,10 @@ services:
- ./volumes/mattermost_2/plugins:/mattermost/plugins:rw
- ./volumes/mattermost_2/client/plugins:/mattermost/client/plugins:rw
- ./volumes/mattermost_2/bleve-indexes:/mattermost/bleve-indexes:rw
# - ./license.mattermost:/mattermost/config/license.mattermost-enterprise:ro
# - ./files/mattermost/samlCert.crt:/mattermost/config/saml-cert.crt
# - ./files/mattermost/defaultConfig.json:/mattermost/config/defaultConfig.json:ro
# - ./files/mattermost/replicaConfig.json:/mattermost/config/replicaConfig.json:ro
- ./license.mattermost:/mattermost/config/license.mattermost-enterprise:ro
- ./files/mattermost/samlCert.crt:/mattermost/config/saml-cert.crt
- ./files/mattermost/defaultConfig.json:/mattermost/config/defaultConfig.json:ro
- ./files/mattermost/replicaConfig.json:/mattermost/config/replicaConfig.json:ro
## Files are required for the mitmproxy on the box
- ./files/mitmproxy/mitmproxy-ca.pem:/etc/ssl/certs/mitmproxy-ca.pem
@@ -253,16 +258,16 @@ services:
- "8443:8443/udp"
- "8443:8443/tcp"
- "8045:8045"
mitmproxy:
container_name: cs-repro-mitmproxy
image: mitmproxy/mitmproxy
command: mitmweb --web-host 0.0.0.0 --set confdir=/certs --mode transparent
volumes:
- ./files/mitmproxy:/certs
ports:
- "8180:8080"
- "8181:8081"
restart: unless-stopped
#mitmproxy:
# container_name: cs-repro-mitmproxy
# image: mitmproxy/mitmproxy
# command: mitmweb --web-host 0.0.0.0 --set confdir=/certs --mode transparent
# volumes:
# - ./files/mitmproxy:/certs
# ports:
# - "8180:8080"
# - "8181:8081"
# restart: unless-stopped
# mysql:
# container_name: cs-repro-mysql
# image: mysql:8