class=”markdown_views prism-github-gist”>
Common configuration and commands V1.0
- Common configuration and commands V1.0
-
- docker install ElasticSearch|Kibana
- Oracle commands
- docker install nacos
- Common commands in redis
- Common nginx commands
- nginx configuration file
- Docker common commands
- git commands
- Service remote call open-feign
- Nacos as configuration center
- Frequently used sites
- Wheel code, netty build server, custom high performance
- Unified handling of Controller exceptions
- SpringCloud gateway assertion configuration file
- Complete list of configuration files
Common configuration and commands V1.0
docker install ElasticSearch|Kibana
# Download elasticsearch image file
docker pull elasticsearch:7.4.2
# Download kibana image file
docker pull kibana:7.4.2
#Create the folder that needs to be mounted
# Put the folders required for the configuration file inside
mkdir -p /mydata/elasticsearch/config
# Folder required to put es data in it
mkdir -p /mydata/elasticsearch/data
# Put the folder required for the es plug-in inside
mkdir -p /mydata/elasticsearch/plugins
echo "http.host: 0.0.0.0">>/mydata/elasticsearch/config/elasticsearch.yml
# Command to start the container
docker run --name elasticsearch -p 9200:9200 -p 9300:9300 --privileged=true\
-e "discovery.type=single-node" \
-e ES_JAVA_OPTS="-Xms64m -Xmx128m" \
-v /mydata/elasticsearch/config/elasticsearch.yml:/usr/share/elasticsearch/config/elasticsearch.yml \
-v /mydata/elasticsearch/data:/usr/share/elasticsearch/data \
-v /mydata/elasticsearch/plugins:/usr/share/elasticsearch/plugins \
-d elasticsearch:7.4.2
#Authorize all files in this directory to 777
chmod -R 777 /mydata/elasticsearch/
# Restart docker
systemctl restart docker
docker start elasticsearch
# Start kibana
docker run --name kibana --privileged=true \
-e ELASTICSEARCH_HOSTS=http://192.168.126.20:9200 -p 5601:5601 \
-d kibana:7.4.2
# ik tokenizer installation 1. Download the compressed package
cd /mydata/elasticsearch/plugins/
wget https://github.com/medcl/elasticsearch-analysis-ik/releases/download/v7.4.2/elasticsearch-analysis-ik-7.4.2.zip
# 2. Unzip
unzip elasticsearch-analysis-ik-7.4.2.zip -d ik7.4.2
# 4. Delete
rm -rf ./*.zip
# 5. Modify permissions
chmod -R 777 ik7.4.2/
#Restart 6, es
docker restart elasticsearch
# Enter inside the container
docker exec -it containerID /bin/bash
Oracle command
drop user emp cascade</artifactId
</dependency
dependency
groupIdorg.springframework.cloud</groupId
artifactIdspring-cloud-starter-openfeign</artifactId
</dependency
dependency
groupIdorg.springframework.boot</groupId
artifactIdspring-boot-starter-test</artifactId
scopetest</scope>
exclusions
exclusion
groupIdorg.junit.vintage</groupId
artifactIdjunit-vintage-engine</artifactId
</exclusion
</exclusions
</dependency
dependency
groupIdjunit</groupId>
artifactIdjunit</artifactId>
version4.12</version>
scopetest</scope>
</dependency
</dependencies
dependencyManagement
dependencies
dependency
groupIdorg.springframework.cloud</groupId
artifactIdspring-cloud-dependencies</artifactId
version${spring-cloud.version}</version
typepom</type>
scopeimport</scope>
</dependency
</dependencies
</dependencyManagement
build
plugins
plugin
groupIdorg.springframework.boot</groupId
artifactIdspring-boot-maven-plugin</artifactId
</plugin
</plugins
</build
</project
tag”>version4.12 </version
scopetest</scope>
</dependency
</dependencies
dependencyManagement
dependencies
dependency
groupIdorg.springframework.cloud</groupId
artifactIdspring-cloud-dependencies</artifactId
version${spring-cloud.version}</version
typepom</type>
scopeimport</scope>
</dependency
</dependencies
</dependencyManagement
build
plugins
plugin
groupIdorg.springframework.boot</groupId
artifactIdspring-boot-maven-plugin</artifactId
</plugin
</plugins
</build
</project
pan class=”token punctuation”>
</plugins
</build
</project