剪切板(临时

debian

  • 更新和安装
    apt update && apt upgrade
    apt install curl vim
  • BBR 一键 来源
    wget -N --no-check-certificate "https://raw.githubusercontent.com/ylx2016/Linux-NetSpeed/master/tcp.sh" && chmod +x tcp.sh && ./tcp.sh
  • ssl位置
    /etc/letsencrypt/live/*.cx03.space/fullchain.pem &/privkey.pem
  • v2ray
    • 一键脚本,来源
      wget -N --no-check-certificate -q -O install.sh "https://raw.githubusercontent.com/wulabing/V2Ray_ws-tls_bash_onekey/master/install.sh" && chmod +x install.sh && bash install.sh
    • 手动
      新版配置文件位置/usr/local/etc/v2ray
  • docker 安装
    • curl -fsSL get.docker.com -o get-docker.sh
    • bash get-docker.sh
    • systemctl enable docker && systemctl start docker
  • portainer 面板安装
    • 如果没用root帐号,先docker加组
      sudo groupadd docker
      sudo usermod -aG docker 用户名
    • 用root的话
      docker volume create portainer_data
      docker run -d -p 9000:9000 --name=portainer --restart=always -v /var/run/docker.sock:/var/run/docker.sock -v portainer_data:/data portainer/portainer-ce
  • rclone
    rclone mount onedrive:/ /root/onedrive --copy-links --no-gzip-encoding --no-check-certificate --allow-other --allow-non-empty --umask 000

dnsmasq

待更新

archlinux

  • 安装 yay
<span class="hljs-meta">$ </span><span class="language-bash">sudo pacman -S git go base-devel</span>
<span class="hljs-meta">
$ </span><span class="language-bash">git <span class="hljs-built_in">clone</span> https://aur.archlinux.org/yay.git</span>
<span class="hljs-meta">
$ </span><span class="language-bash"><span class="hljs-built_in">cd</span> yay</span>
<span class="hljs-meta">
$ </span><span class="language-bash">makepkg -si</span>
  • 常用包
    • optimus-manager-qt (双显卡切换)
  • scp传文件
    scp -r root@cx03.space:/etc/nginx/conf.d /home/yura/vps

    scp -r /home/yura/vps root@cx03.space:/data

  • ssh代理
    ssh -o ProxyCommand="nc -X 5 -x 127.0.0.1:10808 %h %p" root@
  • ffmpeg 下 m3u8视频
    ffmpeg -i “你视频的M3U8 URL” 你要保存的文件名.mp4
  • 开 android 模拟器
    cd ~/Android/emulator && ./emulator -avd Pixel_2_API_30
  • 方舟挂机脚本
    cd ArknightsAutoHelper && source venv/bin/activate && python3 akhelper-gui.pyw
  • 开关图形界面
    systemctl set-default graphical.target
    systemctl set-default multi-user.target
  • 挂载本地smb
    sudo mount -t cifs [//192.168.1.1/Public/Anime](//192.168.1.1/Public/Anime) /mnt/pt -o user=admin,password=*****
  • nextlcoud-webdav
    https://yourdomain/remote.php/dav/files/user/

restic 备份

  • 新建备份位置
    restic init --repo ~/onedrive/backup
  • 进行备份
    restic -r ~/onedrive/backup --verbose backup /snap/nextcloud
  • 列出所有快照
    restic -r ~/onedrive/backup snapshots
  • 进行备份全自动版(
    restic -r ~/onedrive/backup --verbose backup /var/snap/nextcloud --password-file /root/password
  • 定期清理并重建目录
    ~/onedrive# restic -r ~/onedrive/backup forget --prune --keep-last 1