邮箱:lee@hlds.fun
...小于 1 分钟
一个爱折腾的小小开发者 爱喝水哦
function getSelectedText() {
if (window.getSelection) { // This technique is the most likely to be standardized.
// getSelection() returns a Selection object, which we do not document.
return window.getSelection()
.toString();
} else if (document.getSelection) {
// This is an older, simpler technique that returns a string
return document.getSelection();
} else if (document.selection) {
// This is the IE-specific technique.
// We do not document the IE selection property or TextRange objects.
return document.selection.createRange()
.text;
}
}
#监控
docker run -d -p 1157:1157 -p 1158:1158 -e LANG=zh_CN.UTF-8 -e TZ=Asia/Shanghai -v /root/hertzbeat//data:/opt/hertzbeat/data -v /root/hertzbeat/logs:/opt/hertzbeat/logs -v /r
oot/hertzbeat/application.yml:/opt/hertzbeat/config/application.yml -v /root/hertzbeat/sureness.yml:/opt/hertzbeat/config/sureness.yml --restart=always --name hertzbeat tancloud/hertzbeat
# 采集器
docker run -d -e IDENTITY=custom-collector-name -e MODE=public -e MANAGER_HOST=127.0.0.1 -e MANAGER_PORT=1158 --name hertzbeat-collector tancloud/hertzbeat-collector
os:ubuntu22.04-lts
sudo apt install docker.io
# 配置docker加速
{
"registry-mirrors": [
"https://dockerproxy.com",
"https://mirror.baidubce.com",
"https://docker.m.daocloud.io",
"https://docker.nju.edu.cn",
"https://docker.mirrors.sjtug.sjtu.edu.cn",
"https://registry.docker-cn.com",
"https://mirror.ccs.tencentyun.com",
"http://hub-mirror.c.163.com"
]
}
services:
namenode:
image: bde2020/hadoop-namenode:2.0.0-hadoop3.2.1-java8
container_name: namenode
ports:
- 9870:9870
- 9000:9000
volumes:
- ./hadoop/dfs/name:/hadoop/dfs/name
- ./input:/input
environment:
- CLUSTER_NAME=test
env_file:
- ./hadoop.env
datanode:
image: bde2020/hadoop-datanode:2.0.0-hadoop3.2.1-java8
container_name: datanode
depends_on:
- namenode
volumes:
- ./hadoop/dfs/data:/hadoop/dfs/data
environment:
SERVICE_PRECONDITION: "namenode:9870"
env_file:
- ./hadoop.env
resourcemanager:
image: bde2020/hadoop-resourcemanager:2.0.0-hadoop3.2.1-java8
container_name: resourcemanager
environment:
SERVICE_PRECONDITION: "namenode:9000 namenode:9870 datanode:9864"
env_file:
- ./hadoop.env
nodemanager1:
image: bde2020/hadoop-nodemanager:2.0.0-hadoop3.2.1-java8
container_name: nodemanager
environment:
SERVICE_PRECONDITION: "namenode:9000 namenode:9870 datanode:9864 resourcemanager:8088"
env_file:
- ./hadoop.env
historyserver:
image: bde2020/hadoop-historyserver:2.0.0-hadoop3.2.1-java8
container_name: historyserver
environment:
SERVICE_PRECONDITION: "namenode:9000 namenode:9870 datanode:9864 resourcemanager:8088"
volumes:
- ./hadoop/yarn/timeline:/hadoop/yarn/timeline
env_file:
- ./hadoop.env
docker pull mongo:4.4-rc
windows指定数据存放路径
docker run --rm --name mongo -d -p 27017:27017 -v D:\Mongodb\master\data:/data/db mongo:4.4-rc
# docker-compose.yaml
version: "3"
services:
neo4j:
image: neo4j
volumes:
- ./db/neo4j/conf:/var/lib/neo4j/conf:rw
- ./db/neo4j/mnt:/var/lib/neo4j/import:rw
- ./db/neo4j/plugins:/plugins:rw
- ./db/neo4j/data:/data:rw
- ./db/neo4j/logs:/var/lib/neo4j/logs:rw
restart: always
ports:
- 7474:7474
- 7687:7687
environment:
- NEO4J_dbms_memory_heap_maxSize=4G
- NEO4J_AUTH=neo4j/123456 #修改默认用户密码
docker pull redis
docker run --name some-redis -p 6379:6379 -d redis
{
"builder": {
"gc": {
"defaultKeepStorage": "20GB",
"enabled": true
}
},
"experimental": false,
"registry-mirrors": [
"https://registry.hub.docker.com",
"https://docker.mirrors.ustc.edu.cn",
"https://mirror.baidubce.com",
"https://docker.mirrors.sjtug.sjtu.edu.cn",
"https://docker.nju.edu.cn"
]
}
https://www.docker.com/get-started
下载安装即可
docker pull mongo:latest
# 视网络情况,快的话几秒就可以拉取慢的话几分钟