Docker部署RestCloud ETL社区
镜像说明
nriet/restcloud:latest
- version:1.3.0
- os:slim-buster
- tomcat:基于官方镜像 tomcat:8.5.78-jdk8-openjdk-slim-buster
- jdk:openjdk-1.8.0_332
- python: 无
- other:中文语言包、中国标准时间、net-tools
nriet/restcloud:1.3.0-slim-buster
- version:1.3.0
- os:slim-buster
- tomcat:基于官方镜像 tomcat:8.5.78-jdk8-openjdk-slim-buster
- jdk:openjdk-1.8.0_332
- python: 无
- other:中文语言包、中国标准时间、net-tools
nriet/restcloud:1.3.0-slim-buster-python3
- version:1.3.0
- os:slim-buster
- tomcat:基于官方镜像 tomcat:8.5.78-jdk8-openjdk-slim-buster
- jdk:openjdk-1.8.0_332
- python: 3.9.13
- other:中文语言包、中国标准时间、net-tools
docker命令部署
- 部署mongodb
docker run --restart=always --name='mongo' -d \
-p 27017:27017 \
-e MONGO_INITDB_ROOT_USERNAME=MongoDB账号\
-e MONGO_INITDB_ROOT_PASSWORD=MongoDB密码\
-v 持久化目录:/data/db \
mongo:4.2.20-rc0-bionic
- 部署restcloud
1.自带ROOT 需要映射application.properties配置文件
docker run --restart=always --name='restcloud' -d \
-p 8080:8080 \
-e MONGODB_HOST=MongoDB地址:27017 \
-e MONGODB_USER=MongoDB账号\
-e MONGODB_PASSWORD=MongoDB密码\
-e RESTCLOUD_SN=序列号\
nriet/restcloud:latest
2.不带ROOT 需要映射ROOT
docker run --restart=always --name='restcloud' -d \
-p 8080:8080 \
-v 持久化目录/ROOT:/usr/local/tomcat/webapps/ROOT \
nriet/tomcat:8.5.78-jdk8-openjdk-slim-buster-python3
3.升级序列号需要重启restcloud容器
docker restart restcloud
Docker-compose部署
l docker-compose.yml
version: "3.9"
services:
mongo:
image: mongo:4.2.20-rc0-bionic
container_name: mongo
ports:
- "27017:27017"
volumes:
- mongo_db:/data/db
restart: always
environment:
MONGO_INITDB_ROOT_USERNAME: admin
MONGO_INITDB_ROOT_PASSWORD: admin
restcloud:
depends_on:
- mongo
image: nriet/restcloud:latest
container_name: restcloud
ports:
- "8080:8080"
restart: always
links:
- mongo
environment:
MONGODB_HOST: mongo:27017
MONGODB_USER: admin
MONGODB_PASSWORD: admin
RESTCLOUD_SN:
volumes:
mongo_db: {}
-
启动Docker Compose
# 后台启动
docker-compose up -d
文章来源:RestCloud第一期征稿活动
原文作者:史修同