Operations
Deploying Dragonfly on a Kubernetes Cluster
· β˜• 2 min read
1. Deploy NFS Storage 1.1 Configure the NFS Service on the Storage Node Install the NFS service on the storage node 1 apt-get install -y nfs-kernel-server Start the NFS service and enable it at boot 1 systemctl start nfs-server.service & systemctl enable nfs-server.service Configure the NFS shared directory 1 mkdir -p /data/nfs 1 vim /etc/exports /data/nfs *(rw,sync,no_root_squash,no_all_squash) Restart the NFS service 1 systemctl restart nfs-server.

Using the history Command
· β˜• 2 min read
1. The history Command The history command lets you view the command history of the current session. When you exit the shell, the command history is saved to the corresponding history file. For bash, the command history is saved in the ~/.bash_history file; for zsh, it is saved in ~/.zsh_history. You can also use the HISTFILE environment variable to specify the location of the history file: export HISTFILE=/data/ops/bash_history.

Using Gemini CLI on a Server
· β˜• 3 min read
1. Get the Project ID and API Key Visit https://aistudio.google.com/apikey Get the project ID and API key, and set them as environment variables 1 2 echo "export GOOGLE_CLOUD_PROJECT=" >> ~/.bashrc echo "export GEMINI_API_KEY=" >> ~/.bashrc 1 source ~/.bashrc 2. Prepare the Node.js Environment Install nvm 1 curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.40.3/install.sh |

FoundationDB Data Backup and Restore
· β˜• 2 min read
1. Set Environment Variables Set the foundationdb cluster name and version 1 2 3 4 5 export CLUSTER_NAME= export NAMESPACE= export DEPLOY_NAME=${CLUSTER_NAME}-deployment export SECRET_NAME=fdb-backup-secret export VERSION=7.1.26 Set the S3 backup bucket and credentials 1 2 3 4 5 export BUCKET= export HOST=s3.us-west-2.amazonaws.com export AK=x export SK=x export S3_BACKUP_URI="blobstore://${AK}:${SK}@${HOST}/fdb-backup?bucket=${BUCKET}&sc=0" 2. Create the Credentials 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 cat <<EOF | kubectl apply -f - apiVersion: v1 kind: Secret metadata: name: ${SECRET_NAME} namespace: ${NAMESPACE} type: Opaque stringData: credentials: | { "accounts": { "${BUCKET}@${HOST}": { "access_key": "${AK}", "secret": "${SK}", "endpoint": "${HOST}" } } } EOF 3.

Adding Scrape Credentials to Node Exporter
· β˜• 2 min read
1. Background Node Exporter is a common component in the Prometheus ecosystem for collecting host metrics, but by default it does not provide access authentication. This article describes how to add basic authentication to Node Exporter in a Kubernetes environment to improve security. 2. Configuring Credentials for Node Exporter 2.1 Generating an Encrypted Password Use the htpasswd tool to generate an encrypted password: