寒武

寒武

記錄一下新安裝Cent OS的一些配置

Restart Network Command#

service network restart

Set HTTP Proxy#

su root
vi /etc/profile
// Add the following content to the first line
export proxy="http://192.168.1.2:12345"
export http_proxy=$proxy
export https_proxy=$proxy
// Reconnect the user and test access to Google using the command
wget google.com

Time Server Synchronization#

// Install npdate tool
yum install -y ntpdate
// Adjust the time zone
cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime
yes | cp -f /usr/share/zoneinfo/Asia/Shanghai /etc/localtime
// Time synchronization
ntpdate us.pool.ntp.org
// Scheduled synchronization (every 10 minutes)
crontab -l >/tmp/crontab.bak
echo "*/10 * * * * /usr/sbin/ntpdate us.pool.ntp.org | logger -t NTP" >> /tmp/crontab.bak
crontab /tmp/crontab.bak
curl -fsSL https://get.docker.com | bash -s docker --mirror Aliyun
// Docker start
systemctl start docker
// Delete Docker image
docker rmi image_id
Delete Docker images that were not successfully created
# Show running Docker processes
docker ps
# Show the most recently created containers (including all states)
docker ps -l
Delete command
docker rm [ID]
For example
docker rm 8cb6ee1f505a

CentOS Installation Nginx Docker Image Tutorial

Nginx Reverse Proxy Settings#

server{
       listen 80;
       charset utf-8;
       server_name 192.168.112.135;

       location / {
          proxy_pass http://192.168.112.135:8080;
          proxy_redirect default;
       }
    }

Memos Installation#

docker run -d --name memos -p 5230:5230 -v ~/.memos/:/var/opt/memos neosmemo/memos:latest

Set Memos to Start on Boot#

// Docker start on boot
systemctl enable docker.service
// After the first startup of Memos, add the startup parameter
docker  update  --restart=always container_name

Start Mix Space#

cd ~/mix-space/core
docker compose up -d

This article is synchronized and updated to xLog by Mix Space
The original link is https://www.xiaozhengyang.com/posts/IT/centos


載入中......
此文章數據所有權由區塊鏈加密技術和智能合約保障僅歸創作者所有。