Containers
Deploying ClickHouse in Containers
· ☕ 7 min read
1. ClickHouse Single Node 1.1 Configure Environment Variables 1 2 3 4 5 6 7 8 export CONTAINER_CLI=nerdctl export IMAGE=clickhouse/clickhouse-server:24 export CLICKHOUSE_INSTANCE_NAME=clickhouse export CH_DATA=/data/ops/clickhouse/$CLICKHOUSE_INSTANCE_NAME export CLICKHOUSE_PORT=9000 export CLICKHOUSE_PROMETHEUS_PORT=9363 export CLICKHOUSE_USER=default export CLICKHOUSE_PASSWORD=xxxxxx 1.2 Generate the Configuration Files 1 2 3 4 5 6 7 8 9 10 11 12 13

Deploying Redis in Containers
· ☕ 3 min read
1. Redis Single Instance Configure environment variables 1 2 3 4 5 6 7 8 9 export CONTAINER_CLI=nerdctl export IMAGE=redis:7 export REDIS_INSTANCE_NAME=redis-instance export REDIS_PASSWORD=xxxxxx export REDIS_PORT=6379 export REDIS_DATA=/data/ops/redis/$REDIS_INSTANCE_NAME mkdir -p $REDIS_DATA/data $REDIS_DATA/log Start the service 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 $CONTAINER_CLI run -d \ --name $REDIS_INSTANCE_NAME \ --restart always \ --security-opt apparmor=unconfined \ --security-opt seccomp=unconfined \ --network host \ --ulimit memlock=-1 \ --ulimit stack=67108864 \ --ulimit nofile=1048576:1048576 \ --memory-swappiness=0 \ -v $REDIS_DATA/data:/data \ -v $REDIS_DATA/log:/var/log/redis \ $IMAGE redis-server --port $REDIS_PORT --requirepass $REDIS_PASSWORD \ --maxmemory 64gb \ --maxmemory-policy noeviction \ --appendonly yes \ --appendfsync everysec Test the connection A PONG response means the connection succeeded

Containerized Deployment of a Multi-Node FoundationDB Cluster and Operations
· ☕ 5 min read
1. Generate a Cluster ID 1 cat /dev/urandom | tr -dc 'a-zA-Z0-9' | fold -w 16 | head -n 1 The examples below use CLUSTER_ID=fKbIga9RHP79OIx1. 2. On the First Node Configure environment variables 1 2 3 4 5 6 7 8 9 10 export CONTAINER_CLI=nerdctl export IMAGE=foundationdb/foundationdb:7.1.26 export CLUSTER_ID=fKbIga9RHP79OIx1 export FDB_INSTANCE_NAME=fdb_server export FDB_CLUSTER_FIRST_IP=$(hostname -I | awk '{print $1}') export FDB_PUBLIC_IP=$(hostname -I | awk '{print $1}') export FDB_PORT=4500 export FDB_DIR=/data/ops/fdb/$FDB_INSTANCE_NAME Clean up old data 1 2 3 $CONTAINER_CLI rm -f $FDB_INSTANCE_NAME mv $FDB_DIR $FDB_DIR.

Deploying the DeepSeek 3FS Storage System in Containers
· ☕ 12 min read
1. Deployment Plan Before starting the containerized deployment, a few requirements: To simplify delivery, only one image is needed For reliability, deploy as many replicas as possible Start different services through different parameters Inject configuration through environment variables and render it into configuration files Below is the deployment plan for DeepSeek 3FS:

Training a Model on the MNIST Dataset with PyTorch
· ☕ 3 min read
1. Create the Training Script Create a training script mnist.py with the following contents: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36