BuyVM折腾记

# 碎碎念

又到了咕咕鸟语无伦次时间,BuyVM作为我入门买的小鸡,折腾并陪伴我多年(x

现在我手上的是2刀/月并且有着年付折扣的传家宝拉斯维加斯+256G存储块

这次折腾全换docker大鲸鱼了,不过忘记组混合硬盘测试了有点可惜,下次想不开,想重装的时候记得就弄吧

下面就简单贴上一些折腾过程

# 前期准备

# 添加ipv6

拿到的小鸡首先更新,然后在后台给他加个ipv6,问就是我也得有(虽然没什么用

具体可以参考BuyVM的Wiki操作

1
nano /etc/network/interfaces
1
2
3
4
  iface eth0 inet6 static
       address YOUR_IPV6_ADDRESS_HERE
       netmask 48
       gateway 2605:6400:20::1

# 添加swap分区

1
2
3
4
5
sudo fallocate -l 1G /swapfile

sudo chmod 600 /swapfile

sudo mkswap /swapfile

编辑 /etc/fstab,添加以下内容:

1
/swapfile swap swap defaults 0 0

# 安装docker

问就是一键脚本,手动装的都闲得发慌(暴论)

1
2
curl -fsSL https://get.docker.com -o get-docker.sh
sh get-docker.sh

# 开启bbr

编辑 /etc/sysctl.conf,添加以下内容:

1
2
net.core.default_qdisc=fq
net.ipv4.tcp_congestion_control=bbr

保存并使其生效 sysctl -p

# 挂载硬盘(略)

# 安装qbittorrent

有几个选择

  • linuxserver/qbittorrent(原版docker)
  • apt安装(排除此选项了)
  • hotio/qbittorrent(预装VueTorrent WebUI)
  • hotio/qflood(qb+flood WebUI,个人认为方便下载)

这里就选择hotio/qbittorrent,安装完成后,用户admin密码adminadmin。进入设置勾选Use alternative WebUI保存即可启用。

# 添加用户

1
useradd qb

# 开启container

这里附docker cli命令

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
docker run -d \
    --name qb \
    -p 8080:8080 \
    -e PUID=1000 \
    -e PGID=1000 \
    -e UMASK=002 \
    -e TZ="Asia/Shanghai" \
    -v /配置文件路径:/config \
    -v /下载文件夹路径:/app/qBittorrent/downloads \
    --restart unless-stopped \
    cr.hotio.dev/hotio/qbittorrent

# 安装Nginx Proxy Manager

懒人反代必备,功能有限

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
version: '3'
services:
  app:
    image: 'jc21/nginx-proxy-manager:latest'
    restart: unless-stopped
    ports:
      - '80:80'
      - '81:81'
      - '443:443'
    volumes:
      - ./data:/data
      - ./letsencrypt:/etc/letsencrypt
1
docker-compose up -d

通过http://127.0.0.1:81访问

默认邮箱admin@example.com

默认密码changeme

# 安装h5ai

主要用来分享吧

# 添加用户

1
useradd h5ai

# xxxxxxxxxx ServerModSetup(“1981709850”)lua

1
2
3
4
5
6
7
8
9
docker run -d --name=h5ai \
-p 8000:80 \
-v /文件目录:/h5ai \
-v /配置目录:/config \
-e PUID=1001 \
-e PGID=1001 \
-e TZ=Asia/Shanghai \
--restart unless-stopped \
awesometic/h5ai
comments powered by Disqus
使用 Hugo 构建
主题 StackJimmy 设计