docker info updated
This commit is contained in:
parent
4878f8bb18
commit
335204d3ee
|
@ -0,0 +1,22 @@
|
|||
# Docker Instruction
|
||||
|
||||
Instruction to generate e run storagehub docker image
|
||||
|
||||
## Dockerfile - DokerCompose
|
||||
|
||||
This image is ready to be deployed in a new environment.
|
||||
The Dockerfile generate an image without configurations (container, service etc.), all the configurations must be provided at image start time.
|
||||
In fact the docker-compose.yml requires 3 environmental variables set at start time: APP_PORT, JACKRABBIT_FOLDER, CONTAINER_SERVICE_FILE_FOLDER.
|
||||
|
||||
```
|
||||
APP_PORT=8080 JACKRABBIT_FOLDER=/data/jackrabbit CONTAINER_SERVICE_FILE_FOLDER=/etc/smartgears-config docker compose up
|
||||
```
|
||||
|
||||
## Dockerfile - DokerCompose standalone
|
||||
|
||||
The image generated from Dockerfile-standalone contains all the configuration to run on a fully isolated container.
|
||||
The docker-compose-standalone.yml contains the declaration of all the services needed (postgres and minio) teking all the configuration from the local ./docker folder
|
||||
|
||||
```
|
||||
docker compose -f docker-compose-standalone.yml up
|
||||
```
|
|
@ -1,11 +1,4 @@
|
|||
FROM d4science/smartgears-distribution:4.0.0-SNAPSHOT-java17-tomcat10.1.19
|
||||
ARG REPOUSER=admin
|
||||
ARG REPOPWD=admin
|
||||
|
||||
COPY ./target/storagehub.war /tomcat/webapps/
|
||||
COPY ./docker/jackrabbit /app/jackrabbit
|
||||
COPY ./docker/jackrabbit/bootstrap.properties /app/jackrabbit/
|
||||
COPY ./docker/storagehub.xml /tomcat/conf/Catalina/localhost/
|
||||
COPY ./docker/logback.xml /etc/
|
||||
COPY ./docker/container.ini /etc/
|
||||
RUN mkdir -p /etc/config/StorageHub
|
||||
COPY ./docker/storage-settings.properties /etc/config/StorageHub/
|
|
@ -0,0 +1,8 @@
|
|||
FROM d4science/smartgears-distribution:4.0.0-SNAPSHOT-java17-tomcat10.1.19
|
||||
COPY ./target/storagehub.war /tomcat/webapps/
|
||||
COPY ./docker/jackrabbit /app/jackrabbit
|
||||
COPY ./docker/storagehub.xml /tomcat/conf/Catalina/localhost/
|
||||
COPY ./docker/logback.xml /etc/
|
||||
COPY ./docker/container.ini /etc/
|
||||
RUN mkdir -p /etc/config/StorageHub
|
||||
COPY ./docker/storage-settings.properties /etc/config/StorageHub/
|
|
@ -10,9 +10,6 @@ compile=false
|
|||
|
||||
mvn clean package
|
||||
|
||||
docker build -t $NAME .
|
||||
|
||||
docker-compose build
|
||||
|
||||
docker-compose up
|
||||
docker-compose -f docker-compose-standalone build
|
||||
|
||||
docker-compose -f docker-compose-standalone up
|
||||
|
|
|
@ -0,0 +1,45 @@
|
|||
version: '3.7'
|
||||
services:
|
||||
postgres:
|
||||
image: postgres:16.2
|
||||
restart: always
|
||||
environment:
|
||||
- POSTGRES_DB=workspace-db
|
||||
- POSTGRES_USER=ws-db-user
|
||||
- POSTGRES_PASSWORD=dbPwd
|
||||
logging:
|
||||
options:
|
||||
max-size: 10m
|
||||
max-file: "3"
|
||||
ports:
|
||||
- '5423:5432'
|
||||
volumes:
|
||||
- ./postgres-data:/var/lib/postgresql/data
|
||||
copy the sql script to create tables
|
||||
- ./sql/create_tables.sql:/docker-entrypoint-initdb.d/create_tables.sql
|
||||
storagehub:
|
||||
build:
|
||||
dockerfile: Dockerfile-standalone
|
||||
environment:
|
||||
_JAVA_OPTIONS:
|
||||
-Xdebug
|
||||
-agentlib:jdwp=transport=dt_socket,server=y,suspend=${SUSPEND:-n},address=*:5005
|
||||
ports:
|
||||
- '8081:8080'
|
||||
- '5005:5005'
|
||||
|
||||
minio:
|
||||
image: minio/minio
|
||||
ports:
|
||||
- "9000:9000"
|
||||
- "9001:9001"
|
||||
volumes:
|
||||
- minio_storage:/data
|
||||
environment:
|
||||
MINIO_ROOT_USER: SHUBTEST
|
||||
MINIO_ROOT_PASSWORD: wJalrXUtnFEMI/K7MDENG/bPxRfiCY
|
||||
command: server --console-address ":9001" /data
|
||||
|
||||
volumes:
|
||||
minio_storage: {}
|
||||
|
|
@ -1,44 +1,10 @@
|
|||
version: '3.7'
|
||||
services:
|
||||
postgres:
|
||||
image: postgres:16.2
|
||||
restart: always
|
||||
environment:
|
||||
- POSTGRES_DB=workspace-db
|
||||
- POSTGRES_USER=ws-db-user
|
||||
- POSTGRES_PASSWORD=dbPwd
|
||||
logging:
|
||||
options:
|
||||
max-size: 10m
|
||||
max-file: "3"
|
||||
ports:
|
||||
- '5423:5432'
|
||||
volumes:
|
||||
- ./postgres-data:/var/lib/postgresql/data
|
||||
copy the sql script to create tables
|
||||
- ./sql/create_tables.sql:/docker-entrypoint-initdb.d/create_tables.sql
|
||||
storagehub:
|
||||
build: .
|
||||
environment:
|
||||
_JAVA_OPTIONS:
|
||||
-Xdebug
|
||||
-agentlib:jdwp=transport=dt_socket,server=y,suspend=${SUSPEND:-n},address=*:5005
|
||||
image: d4science/staragehub:latest
|
||||
ports:
|
||||
- '8081:8080'
|
||||
- '5005:5005'
|
||||
|
||||
minio:
|
||||
image: minio/minio
|
||||
ports:
|
||||
- "9000:9000"
|
||||
- "9001:9001"
|
||||
- '${APP_PORT}:8080'
|
||||
volumes:
|
||||
- minio_storage:/data
|
||||
environment:
|
||||
MINIO_ROOT_USER: SHUBTEST
|
||||
MINIO_ROOT_PASSWORD: wJalrXUtnFEMI/K7MDENG/bPxRfiCY
|
||||
command: server --console-address ":9001" /data
|
||||
|
||||
volumes:
|
||||
minio_storage: {}
|
||||
|
||||
- ${JACKRABBIT_FOLDER}:/app/jackrabbit
|
||||
- ${SMARTGEARS_CONFIG_FOLDER}:/etc
|
||||
|
Loading…
Reference in New Issue