1, version
The latest stable version is 1.1.4, also from the description made version , blog looks for each version features the official recommended to use the latest stable version.
2, set up registration centers
2.1 Environmental ready
nacos depends on the Java Runtime Environment, make sure to install and use.
- 64-bit operating system that supports Linux / Unix / Mac / Windows, recommended Linux / Unix / Mac.
- JDK 1.8+ 64 bit download address .
2.2, download nacos
Download
Visit the official website https://nacos.io, or download the latest stable version , compressed package name nacos-server- $ version.zip.
#zip
unzip nacos-server-$version.zip
#tar
tar -xvf nacos-server-$version.tar.gz
docker
Use portainer create nacos server
After completion, click Deploy the container.
2.3, start the server
Linux/Unix/Mac
centos system:
sh startup.sh -m standalone
ubuntu system:
bash startup.sh -m standalone
standalone represents stand-alone mode, non-clustered mode
Windows
Start command:
cmd startup.cmd
Startup.cmd run or double-click the file.
3, the server closes
Linux/Unix/Mac
sh shutdown.sh
Windows
cmd shutdown.cmd
Shutdown.cmd run or double-click the file.
4, the service registration and discovery
Service Registration
curl -X POST 'http://127.0.0.1:8848/nacos/v1/ns/instance?serviceName=nacos.naming.serviceName&ip=127.0.0.1&port=8080'
Service Discovery
curl -X GET 'http://127.0.0.1:8848/nacos/v1/ns/instance/list?serviceName=nacos.naming.serviceName'
This article is [Galaxy] original architect, in an article for reprint please indicate the author and source of the obvious.
Micro-channel search [architect] Galaxy, find more exciting content.