Skip to content
This repository has been archived by the owner on May 2, 2023. It is now read-only.

Commit

Permalink
#114 audit, query and notification merge
Browse files Browse the repository at this point in the history
  • Loading branch information
jesty authored Mar 18, 2020
2 parents 6c9db60 + 6bf2ea6 commit 453346e
Show file tree
Hide file tree
Showing 4 changed files with 29 additions and 342 deletions.
71 changes: 9 additions & 62 deletions docker-compose/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,20 +11,20 @@ services:
- POSTGRES_USER=activiti
- POSTGRES_DB=activitidb
volumes:
- "pgdata:/var/lib/postgresql/data"
- "pgdata:/var/lib/postgresql/data"
restart: unless-stopped

nginx:
nginx:
image: nginx:latest
container_name: nginx
volumes:
- ./nginx.conf:/etc/nginx/nginx.conf
ports:
- 80:80
- 80:80
- 443:443
restart: unless-stopped

rabbitmq:
rabbitmq:
container_name: rabbitmq
image: rabbitmq
ports:
Expand Down Expand Up @@ -74,7 +74,7 @@ services:
depends_on:
- nginx
- keycloak
- rabbitmq
- rabbitmq
- activiti-postgres

example-cloud-connector:
Expand All @@ -99,13 +99,15 @@ services:
SPRING_JMX_ENABLED: "false"
SPRING_RABBITMQ_HOST: "rabbitmq"
ACT_KEYCLOAK_URL: "http://${DOCKER_IP}/auth"
SERVER_SERVLET_CONTEXT_PATH: /query
SPRING_DATASOURCE_URL: jdbc:postgresql://activiti-postgres:5432/activitidb
SPRING_DATASOURCE_USERNAME: activiti
SPRING_DATASOURCE_PASSWORD: mypassword
SPRING_JPA_DATABASE_PLATFORM: org.hibernate.dialect.PostgreSQLDialect
SPRING_JPA_GENERATE_DDL: "true"
SPRING_JPA_HIBERNATE_DDL_AUTO: update
SPRING.GRAPHQL_JPA_QUERY_PATH: /notifications/graphql
GRAPHIQL_GRAPHQL_WEB_PATH: /notifications/graphql
GRAPHIQL_GRAPHQL_WS_PATH: /notifications/ws/graphql

# ACTIVITI_SECURITY_POLICIES_0_NAME: "HR Group restricted to SimpleProcess and ConnectorProcess"
# ACTIVITI_SECURITY_POLICIES_0_GROUPS: "hr"
Expand All @@ -118,67 +120,12 @@ services:
# ACTIVITI_SECURITY_POLICIES_1_SERVICENAME: "rb-my-app"
# ACTIVITI_SECURITY_POLICIES_1_KEYS: "*"
restart: unless-stopped
depends_on:
- nginx
- keycloak
- rabbitmq
- activiti-postgres

activiti-cloud-audit:
container_name: activiti-cloud-audit
image: activiti/activiti-cloud-audit:${VERSION}
environment:
# JA`VA_OPTS: "-Xdebug -Xrunjdwp:server=y,transport=dt_socket,address=8000,suspend=n -noverify"
SPRING_JMX_ENABLED: "false"
SPRING_RABBITMQ_HOST: "rabbitmq"
ACT_KEYCLOAK_URL: "http://${DOCKER_IP}/auth"
SERVER_SERVLET_CONTEXT_PATH: /audit
SPRING_DATASOURCE_URL: jdbc:postgresql://activiti-postgres:5432/activitidb
SPRING_DATASOURCE_USERNAME: activiti
SPRING_DATASOURCE_PASSWORD: mypassword
SPRING_JPA_DATABASE_PLATFORM: org.hibernate.dialect.PostgreSQLDialect
SPRING_JPA_GENERATE_DDL: "true"
SPRING_JPA_HIBERNATE_DDL_AUTO: update
# ACTIVITI_SECURITY_POLICIES_0_NAME: "HR Group restricted to SimpleProcess and ConnectorProcess"
# ACTIVITI_SECURITY_POLICIES_0_GROUPS: "hr"
# ACTIVITI_SECURITY_POLICIES_0_ACCESS: "WRITE"
# ACTIVITI_SECURITY_POLICIES_0_SERVICENAME: "rb-my-app"
# ACTIVITI_SECURITY_POLICIES_0_KEYS: "SimpleProcess,ConnectorProcess,fixSystemFailure,twoTaskProcess"
# ACTIVITI_SECURITY_POLICIES_1_NAME: "testgroup not restricted at all"
# ACTIVITI_SECURITY_POLICIES_1_GROUPS: "testgroup"
# ACTIVITI_SECURITY_POLICIES_1_ACCESS: "WRITE"
# ACTIVITI_SECURITY_POLICIES_1_SERVICENAME: "rb-my-app"
# ACTIVITI_SECURITY_POLICIES_1_KEYS: "*"
restart: unless-stopped
depends_on:
- nginx
- keycloak
- rabbitmq
- activiti-postgres

activiti-cloud-notifications-graphql:
container_name: activiti-cloud-notifications-graphql
image: activiti/activiti-cloud-notifications-graphql:${VERSION}
environment:
# JAVA_OPTS: "-Xdebug -Xrunjdwp:server=y,transport=dt_socket,address=8000,suspend=n -noverify"
SPRING_JMX_ENABLED: "false"
SPRING_RABBITMQ_HOST: "rabbitmq"
ACT_KEYCLOAK_URL: "http://${DOCKER_IP}/auth"
SPRING_DATASOURCE_URL: jdbc:postgresql://activiti-postgres:5432/activitidb
SPRING_DATASOURCE_USERNAME: activiti
SPRING_DATASOURCE_PASSWORD: mypassword
SPRING_JPA_DATABASE_PLATFORM: org.hibernate.dialect.PostgreSQLDialect
SPRING_JPA_GENERATE_DDL: "false"
SPRING_JPA_HIBERNATE_DDL_AUTO: none
SERVER_SERVLET_CONTEXT_PATH: "/notifications"
SPRING_JPA_PROPERTIES_HIBERNATE_TEMP_USE_JDBC_METADATA_DEFAULTS: "false"
restart: unless-stopped
depends_on:
- nginx
- keycloak
- rabbitmq
- activiti-postgres

activiti-cloud-modeling:
container_name: activiti-cloud-modeling
image: activiti/activiti-modeling-app:${VERSION}
Expand Down
50 changes: 20 additions & 30 deletions docker-compose/nginx.conf
Original file line number Diff line number Diff line change
Expand Up @@ -25,19 +25,7 @@ http {
}
location /rb {
resolver 127.0.0.11 ipv6=off;
set $upstream example-runtime-bundle:8080;

proxy_pass http://$upstream;
proxy_redirect off;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Host $server_name;
}
location /audit {
resolver 127.0.0.11 ipv6=off;
set $upstream activiti-cloud-audit:8080;

set $upstream example-runtime-bundle:8080;
proxy_pass http://$upstream;
proxy_redirect off;
proxy_set_header Host $host;
Expand All @@ -47,46 +35,48 @@ http {
}
location /query {
resolver 127.0.0.11 ipv6=off;
set $upstream activiti-cloud-query:8080;

proxy_pass http://$upstream;
proxy_redirect off;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Host $server_name;
}
location /notifications/graphiql {
resolver 127.0.0.11 ipv6=off;
set $upstream activiti-cloud-notifications-graphql:8080;
set $upstream activiti-cloud-query:8080;

rewrite ^/query/(.*)$ /$1 break;
proxy_pass http://$upstream;
proxy_redirect off;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Host $server_name;
}
location /notifications/graphql {
location /audit {
resolver 127.0.0.11 ipv6=off;
set $upstream activiti-cloud-notifications-graphql:8080;
set $upstream activiti-cloud-query:8080;

rewrite ^/audit/(.*)$ /$1 break;
proxy_pass http://$upstream;
proxy_redirect off;
proxy_set_header Host $host;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Host $server_name;
}
location /notifications/ws/graphql {
location /notifications/ {
resolver 127.0.0.11 ipv6=off;
set $upstream activiti-cloud-notifications-graphql:8080;
set $upstream activiti-cloud-query:8080;

rewrite ^/notifications/(.*)$ /$1 break;
proxy_pass http://$upstream;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
}
location /notifications/ws/graphql {
resolver 127.0.0.11 ipv6=off;
set $upstream activiti-cloud-query:8080;

rewrite ^/notifications/(.*)$ /$1 break;
proxy_pass http://$upstream;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
}
location ~ ^/modeling-service/?(.*)$ {
resolver 127.0.0.11 ipv6=off;
set $upstream activiti-cloud-modeling-backend:8080;
Expand Down
117 changes: 0 additions & 117 deletions docker/application-docker-compose.yml

This file was deleted.

Loading

0 comments on commit 453346e

Please sign in to comment.