wget -qO- https://binaries.cockroachdb.com/cockroach-v19.1.0.src.tgz | tar xvz
cd cockroach-v19.1.0
make build
sudo make install
mkdir ~/cockroachdb
export GOPATH=~/cockroachdb/
mkdir -p $(go env GOPATH)/src/github.com/cockroachdb
cd $(go env GOPATH)/src/github.com/cockroachdb
git clone git@github.com:cockroachdb/cockroach.git
cd cockroach
make build
make build IGNORE_GOVERS=1
src/github.com/cockroachdb/cockroach/c-deps/libroach/CMakeLists.txt +84 +172
src/github.com/cockroachdb/cockroach/c-deps/rocksdb/CMakeLists.txt +251
go version : 1.15.6
nodejs version :
ubuntu20 : curl -sL https://deb.nodesource.com/setup_12.x | bash -
go version : 1.14.7 ~~1.12.17~~
nodejs version :
ubuntu20 : curl -sL https://deb.nodesource.com/setup_10.x | bash -
centos7 : curl --silent --location https://rpm.nodesource.com/setup_6.x | bash -
https://www.cockroachlabs.com/docs/stable/install-cockroachdb-linux.html#build-from-source
http://doc.cockroachchina.baidu.com/#quick-start/start-a-local-cluster/from-binary/
cockroach start --insecure --host=localhost
cockroach sql --insecure --port=26257
docker build -t cockroach-centos-docker:0.1 -t cockroach-centos-docker:latest --build-arg osver=7 .
https://hub.docker.com/r/ymxdgyx/cockroach-centos-docker
launch.json:
{
// Use IntelliSense to learn about possible attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [
{
"name": "Launch",
"type": "go",
"request": "launch",
"mode": "auto",
"program": "/home/drdb/cockroachdb/src/github.com/cockroachdb/cockroach/pkg/cmd/drdb/",
"args": ["start","--insecure","--host=localhost"],
// "showLog": true
}
]
}
Goland:
Files: pkg/cmd/cockroachdb/main.go
Program arguments: "start" "--insecure" "--host=localhost"