标签:部署 tar kibana sudo xms env run links sof
使用 docker,很多环境可以借助 docker 去部署,没必要所有的环境都在本地安装,十分方便。
docker 部署 SqlServer 2017 linux
docker run -e 'ACCEPT_EULA=Y' -e 'MSSQL_SA_PASSWORD=<YourStrong!Passw0rd>' -p 1433:1433 --name sqlserver --restart=always -d microsoft/mssql-server-linux:2017-latest
如果希望数据持久化,可以挂载数据目录,
sudo docker run -e 'ACCEPT_EULA=Y' -e 'MSSQL_SA_PASSWORD=<YourStrong!Passw0rd>' --name 'sql1' -p 1433:1433 -v sql1data:/var/opt/mssql -d microsoft/mssql-server-linux:2017-latest
docker 部署 redis
docker run --restart=always -d -p 6379:6379 --name redis-server redis:alpine
elasticsearch 一般与 kibana 一起部署,kibana 可以提供一个ui界面方便查询,我们可以使用 docker-compose 部署一个 elasticsearch 和 kibana 实例
version: '2'
services:
elasticsearch:
image: elasticsearch:5.6
container_name: elasticsearch
ports:
- 9200:9200
ulimits:
nofile:
soft: 65536
hard: 65536
restart: always
environment:
- "ES_JAVA_OPTS=-Xms512m -Xmx512m" #specific es java memory
volumes:
- ./es/data:/usr/share/elasticsearch/data
- ./es/config/elasticsearch.yml:/usr/share/elasticsearch/config/elasticsearch.yml
mem_limit: 1g # memory limit
kibana:
image: kibana:5.6
container_name: kibana
ports:
- 5601:5601
links:
- elasticsearch:elasticsearch
depends_on:
- elasticsearch
environment:
ELASTICSEARCH_URL: http://elasticsearch:9200
遇到其他的常用工具再补充
标签:部署 tar kibana sudo xms env run links sof
原文地址:https://www.cnblogs.com/weihanli/p/deploy-develop-environment-via-docker.html