Sign inSign up

yeqianmen/starrocks

By yeqianmen

•Updated over 3 years ago

images for starrocks,dev or test

Image
0

200

yeqianmen/starrocks repository overview

⁠Start the Docker container

Start by mapping the ports:

docker run -p 9030:9030 -p 8030:8030 -p 8040:8040 --privileged=true -itd -e TZ=Asia/Shanghai --name starrocks yeqianmen/starrocks:2.4.4

Start by using the network environment of the host machine:

docker run  --network host  --privileged=true -itd  -e TZ=Asia/Shanghai --name starrocks yeqianmen/starrocks:2.4.4

⁠Log in to StarRocks

Log in to StarRocks after the Docker container is started.

docker exec -it starrocks bash -c 'mysql -uroot -h127.0.0.1 -P 9030'

⁠Verify the deployment

Run the following SQLs to check if StarRocks is successfully deployed in the Docker container.

CREATE DATABASE TEST;

USE TEST;

CREATE TABLE `sr_on_mac` (
 `c0` int(
11
) NULL COMMENT "",
 `c1` date NULL COMMENT "",
 `c2` datetime NULL COMMENT "",
 `c3` varchar(
65533
) NULL COMMENT ""
) ENGINE=OLAP 
DUPLICATE KEY(`c0`)
PARTITION BY RANGE (c1) (
  START ("2022-02-01") END ("2022-02-10") EVERY (INTERVAL 
1
 DAY)
)
DISTRIBUTED BY HASH(`c0`) BUCKETS 
1

PROPERTIES (
"replication_num" = "1",
"in_memory" = "false",
"storage_format" = "DEFAULT"
);

insert into sr_on_mac values (
1
, '2022-02-01', '2022-02-01 10:47:57', '111');
insert into sr_on_mac values (
2
, '2022-02-02', '2022-02-02 10:47:57', '222');
insert into sr_on_mac values (
3
, '2022-02-03', '2022-02-03 10:47:57', '333');

select * from sr_on_mac where c1 >= '2022-02-02';

If no error is returned, you have successfully deployed StarRocks in Docker.

Tag summary

Content type

Image

Digest

sha256:1fe469bd4…

Size

3 GB

Last updated

over 3 years ago

docker pull yeqianmen/starrocks:2.4.4