# histories_fts_case_insensitive_content

c0: 20240220152630-qly715s
c2: update
c3: docker部署
c5: 2025-03-12-153830-update/20240220152634-yy4s6nv/20240220152630-qly715s.sy
c6: 1741765110
c4:
一键部署
思源	
docker run -d  -v /mnt/sata3-3/soft/images/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d -v /root/siyuan:/siyuan/workspace  -e PUID=$UID  -e PGID=$GID  -p 6806:6806 b3log/siyuan  --workspace=/siyuan/workspace/ --accessAuthCode=xxx
网心云
docker run -d --name=wxedge --restart=always --privileged --net=host  --tmpfs /run --tmpfs /tmp -v /home:/storage:rw  registry.hub.docker.com/onething1/wxedge
网迅雷
docker run -d --name=xunlei --hostname=mynas --net=host -v /mnt/sdb1/xunlei:/xunlei/data -v /mnt/sdb1/downloads:/xunlei/downloads --restart=unless-stopped --privileged cnk3x/xunlei:latest
webdav
docker run --name=webdav -d -e USERNAME=test -e PASSWORD=test -v /路径:/webdav -p 8920:80 idelsink/webdav
docker-compose部署
wordpress
version: "3.3"
  
services:
  db:
    image: mysql:8.0
    volumes:
      - ./db_data:/var/lib/mysql
    restart: always
    environment:
      MYSQL_ROOT_PASSWORD: wordpress
      MYSQL_DATABASE: wordpress
      MYSQL_USER: wordpress
      MYSQL_PASSWORD: wordpress
  
  wordpress:
    depends_on:
      - db
    image: wordpress:latest
    volumes:
      - ./wordpress_data:/var/www/html
    ports:
      - "10001:80"
    restart: always
    environment:
      WORDPRESS_DB_HOST: db
      WORDPRESS_DB_USER: wordpress
      WORDPRESS_DB_PASSWORD: wordpress
      WORDPRESS_DB_NAME: wordpress
volumes:
  db_data: {}
  wordpress_data: {}
joplin
version: '3'

services:
    db:
        image: postgres:latest
        restart: unless-stopped
        environment:
            - POSTGRES_PASSWORD=joplin
            - POSTGRES_USER=joplin
            - POSTGRES_DB=joplin
    app:
        image: joplin/server:latest
        depends_on:
            - db
        ports:
            - "22300:22300"
        restart: unless-stopped
        environment:
            - APP_PORT=22300
            - APP_BASE_URL=http://192.168.0.183:22300
            - DB_CLIENT=pg
            - POSTGRES_PASSWORD=joplin
            - POSTGRES_DATABASE=joplin
            - POSTGRES_USER=joplin
            - POSTGRES_PORT=5432
            - POSTGRES_HOST=db
数据备份 resilio部署
docker run -d   -e PUID=1000   -e PGID=1000   -e TZ=Etc/UTC   -p 8888:8888  -p 55555:55555   -v /root/siyuan1/config:/config  -v /root/siyuan1:/downloads  -v /root/siyuan1:/sync  --restart unless-stopped lscr.io/linuxserver/resilio-sync:latest
Docker安装Wireguard
docker run -d \
  --name=wg-easy \
  -e WG_HOST=123.123.123.123 (🚨这里输入服务器的公网IP) \
  -e PASSWORD=passwd123 (🚨这里输入你的密码) \
  -e WG_DEFAULT_ADDRESS=10.0.8.x （🚨默认IP地址）\
  -e WG_DEFAULT_DNS=114.114.114.114 （🚨默认DNS）\
  -e WG_ALLOWED_IPS=10.0.8.0/24 （🚨允许连接的IP段）\
  -e WG_PERSISTENT_KEEPALIVE=25 （🚨重连间隔）\
  -v ~/.wg-easy:/etc/wireguard \
  -p 51820:51820/udp \
  -p 51821:51821/tcp \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --sysctl="net.ipv4.ip_forward=1" \
  --restart unless-stopped \
  weejewel/wg-easy
samba部署
samba.tar
docker run -d --name=samba  -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=PXX"  -v "/home/example:/storage" dockurr/samba
docker run -d \
  --name=wg-easy \
  -e WG_HOST=39.174.229.143  \
  -e PASSWORD=888888  \
  -e WG_DEFAULT_ADDRESS=10.0.0.x \
  -e WG_DEFAULT_DNS=211.140.13.188 \
  -e WG_ALLOWED_IPS=10.0.0.0/24 \
  -e WG_PERSISTENT_KEEPALIVE=25 \
  -v ~/.wg-easy:/etc/wireguard \
  -p 80:51820/udp \
  -p 80:51821/tcp \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --sysctl="net.ipv4.ip_forward=1" \
  --restart unless-stopped \
  weejewel/wg-easy
docker run -d \
  --name=wg-easy \
  -e WG_HOST=192.168.50.237  \
  -e PASSWORD=  \
  -e WG_DEFAULT_ADDRESS=1.1.1.x \
  -e WG_DEFAULT_DNS=211.140.13.188 \
  -e WG_ALLOWED_IPS=1.1.1.0/24 \
  -e WG_PERSISTENT_KEEPALIVE=25 \
  -v /mnt/wg-easy:/etc/wireguard \
  -p 51820:51820/udp \
  -p 80:51821/tcp \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --sysctl="net.ipv4.ip_forward=1" \
  --restart unless-stopped \
  weejewel/wg-easy
network:
  version: 2
  renderer: networkd
  ethernets:
    eth0:
      dhcp4: false
      addresses:
        - 192.168.50.237/24  
      gateway4: 192.168.50.18  
      nameservers:
        addresses:
          - 8.8.8.8  
          - 8.8.4.4

qbittorrent部署
docker run -d \
  --name=qbittorrent \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 8080:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/sda2:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest
 需要看logs 密码
docker run -d -p 1000:9000 --name portainer --restart always -v /var/run/docker.sock:/var/run/docker.sock -v /opt/portainer:/data portainer/portainer-ce:latest


c0: 20250204202213-2virs7k
c2: update
c3: 复制修改版
c5: 2025-03-12-163303-update/20250204202137-3g13i3l/20250204202213-2virs7k.sy
c6: 1741768383
c4:
通过 iPhone 镜像从 Mac 使用 iPhone
魔兽争霸:https://www.123pan.com/s/nVxFjv-fkwd3.html
dd if=openwrt-24.10.0-x86-64-generic-ext4-combined-efi.img of=/dev/sdb bs=4M
docker dockerd luci-lib-docker docker-compose
docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
dd if=/dev/sda of=/root/openwrt24.img bs=4M status=progress

docker run -d  -v /mnt/sda1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d \
  --name=qbittorrent \
  -e PUID=1000 -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -e WEBUI_PORT=8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -p 80:8080 \
  -v /home/qbittorrent/:/downloads \
  --restart unless-stopped \
  linuxserver/qbittorrent

docker run -d \
  --name=qbittorrent \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 2000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/sda2:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

dd if=istoreo.img of=/dev/sda bs=4M
docker run -d --name=xunlei --hostname=mynas --net=host -v /mnt/usb1:/xunlei/data -v /mnt/usb1/downloads:/xunlei/downloads --restart=unless-stopped --privileged cnk3x/xunlei:latest
docker run -d --privileged  -v /mnt/sda2:/xunlei/downloads -p 2345:2345 cnk3x/xunlei
docker run -d -v /mnt/usb1/siyuan:/siyuan/workspace  -e PUID=$UID  -e PGID=$GID  -p 6806:6806 b3log/siyuan  --workspace=/siyuan/workspace/ --accessAuthCode=xxx
docker run -d --name=siyuan -v /mnt/usb1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d --name syncthing  --restart always -p 3000:8384 -p 22000:22000/tcp -p 22000:22000/udp  -p 21027:21027/udp -v /mnt/config-sync:/var/syncthing/config -v /mnt:/var/syncthing/data syncthing/syncthing
docker run -d \
  --name syncthing \
  --restart always \
  -p 8384:8384 \
  -p 22000:22000/tcp \
  -p 22000:22000/udp \
  -p 21027:21027/udp \
  -v /mnt/usb2/syncthing/config:/var/syncthing/config \
  -v /mnt/usb2/syncthing/:/var/syncthing/data \
  syncthing/syncthing
docker run -d --name=samba  --restart unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NNN"  -v "/mnt:/storage" dockurr/samba
opkg install fdisk block-mount unzip zerotier samba4-server samba4-utils luci-app-samba4 openssh-sftp-server openvpn-openssl luci-app-openvpn wireguard-tools kmod-wireguard luci-proto-wi
mkdir -p /tmp/introot
mkdir -p /tmp/extroot
mount --bind / /tmp/introot
mount /dev/sda3 /tmp/extroot
tar -C /tmp/introot -cvf - . | tar -C /tmp/extroot -xf -
umount /tmp/introot
umount /tmp/extroot
docker run -d --name=samba --restart=unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NBBN"  -v "/mnt/:/storage" dockurr/samba
network:
  version: 2
  renderer: networkd
  wifis:
    wlp2s0:
      dhcp4: no
      addresses:
        - 192.168.0.124/24  # 这里改成你想要的静态 IP
      gateway4: 192.168.0.8  # 你的网关 IP（通常是路由器 IP）
      nameservers:
        addresses:
          - 211.140.13.188   
          - 114.114.114.114  # 114 DNS
      access-points:
        "boci1":
          password: "a1b2c3d4"


docker run --restart always --name openwrt1 -d --network macnet --privileged --ip 192.168.0.124   openwrt /sbin/init
docker run -d \
  --name=clash \
  -v /root/clash.yaml: /root/.config/clash/config.yaml \
  -p 7890:7890 \
  -p 9090:9090 \
  --restart unless-stopped \
  dreamacro/clash

安装官方最新版本：
curl -fsSL https://get.docker.com | bash
docker import rootfs.tar.gz my-custom-image
docker run -d \
  --name openwrt \
  --network host \
  --privileged \
  openwrt
docker run --restart always --name openwrt -p 80:80 -d --network host --privileged openwrt /sbin/init
允许 ZeroTier 网络访问本地网络
sudo iptables -A FORWARD -s 192.168.192.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 192.168.0.0/24 -d 192.168.192.0/24 -j ACCEPT
如果局域网设备默认网关不是 Ubuntu，需要 NAT
sudo iptables -t nat -A POSTROUTING -s 192.168.192.0/24 -d 192.168.0.0/24 -j MASQUERADE
eroTier 网络
192.168.0.0/24 via 192.168.191.112
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
ip route add 192.168.50.0/24 via 10.8.0.1 dev tun0
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
4.新启动 OpenVPN 服务
systemctl restart openvpn
docker run -d \
  --name=wg-easy \
  -e WG_HOST=39.174.229.143  \
  -e PASSWORD=888888  \
  -e WG_DEFAULT_ADDRESS=10.0.8.x \
  -e WG_DEFAULT_DNS=211.140.13.188 \
  -e WG_ALLOWED_IPS=10.0.8.0/24 \
  -e WG_PERSISTENT_KEEPALIVE=25 \
  -v ~/wg-easy:/etc/wireguard \
  -p 51820:51820/udp \
  -p 80:51821/tcp \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --sysctl="net.ipv4.ip_forward=1" \
  --restart unless-stopped \
  weejewel/wg-easy
network:
  ethernets:
    eth0:  # 请替换为你的实际网卡名称
      dhcp4: no
      addresses:
        - 192.168.0.219/24  # 设置静态 IP
      gateway4: 192.168.0.8  # 设置网关
      nameservers:
        addresses:
          - 211.140.13.188
  version: 2
ip route add 192.168.200.0/24 via 10.8.0.1 dev tun0
iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE
iptables -A FORWARD -i tun0 -o eth1 -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A FORWARD -i eth1 -o tun0 -j ACCEPT


docker run -d \
  --name=wg-easy \
  -e WG_HOST=39.174.229.143  \
  -e WG_DEFAULT_ADDRESS=10.0.8.x \
  -e WG_DEFAULT_DNS=211.140.13.188 \
  -e WG_ALLOWED_IPS=10.0.8.0/24 \
  -e WG_PERSISTENT_KEEPALIVE=25 \
  -v ~/wg-easy:/etc/wireguard \
  -p 51820:51820/udp \
  -p 2000:51821/tcp \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --sysctl="net.ipv4.ip_forward=1" \
  --restart unless-stopped \
  weejewel/wg-easy

enp1s0    enx00e04c360351
network:
  version: 2
  renderer: networkd
  ethernets:
    eth0:
      dhcp4: yes
      dhcp6: no
    enx00e04c360351:
      addresses:
        - 10.131.61.111/24
      dhcp4: no
sudo iptables -t nat -A POSTROUTING -o enp1s0 -j MASQUERADE
sudo iptables -A FORWARD -i enx00e04c360351 -o enp1s0 -j ACCEPT
sudo iptables -A FORWARD -i enp1s0 -o enx00e04c360351 -m state --state RELATED,ESTABLISHED -j ACCEPT
ip route add 22.8.144.97 via 10.130.61.1 dev enx00e04c360351
ip route add 22.8.144.97 via 10.131.61.1 dev br-lan  
ip route add 22.8.144.97 via 10.0.0.5 dev wireguard 
22.8.144.97
ip route add 22.8.144.97 via 192.168.0.8 dev eth0
39.174.229.143
10.0.0.0/24
uci show firewall | grep '@redirect'
docker run -d \
  --name=transmission \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -p 80:9091 \
  -p 51413:51413 \
  -p 51413:51413/udp \
  -v /home/download:/downloads \
  --restart unless-stopped \
  lscr.io/linuxserver/transmission:latest

docker run --restart always --name openwrt -d --network macnet --privileged --ip 10.1.25.193 ophub/openwrt-aarch64:latest
uci set zerotier.global.enabled='1'
uci delete zerotier.earth
uci set zerotier.openwrt_network=network
uci set zerotier.openwrt_network.id='856127940c66f22d'
uci commit zerotier
ip link set  eth0 promisc on
docker network create -d macvlan --subnet=10.1.25.0/24 --gateway=10.1.25.1 -o parent=br-lan  mynet
docker run  --name openwrt --restart unless-stopped -d --network mynet    --privileged --ip 10.1.25.40  openwrt  /sbin/init


c0: 20250204202213-2virs7k
c2: update
c3: 复制修改版
c5: 2025-03-12-165518-update/20250204202137-3g13i3l/20250204202213-2virs7k.sy
c6: 1741769718
c4:
通过 iPhone 镜像从 Mac 使用 iPhone
魔兽争霸:https://www.123pan.com/s/nVxFjv-fkwd3.html
dd if=openwrt-24.10.0-x86-64-generic-ext4-combined-efi.img of=/dev/sdb bs=4M
docker dockerd luci-lib-docker docker-compose
docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
dd if=/dev/sda of=/root/openwrt24.img bs=4M status=progress

docker run -d  -v /mnt/sda1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d \
  --name=qbittorrent \
  -e PUID=1000 -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -e WEBUI_PORT=8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -p 80:8080 \
  -v /home/qbittorrent/:/downloads \
  --restart unless-stopped \
  linuxserver/qbittorrent

docker run -d \
  --name=qbittorrent \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 2000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/sda2:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

dd if=istoreo.img of=/dev/sda bs=4M
docker run -d --name=xunlei --hostname=mynas --net=host -v /mnt/usb1:/xunlei/data -v /mnt/usb1/downloads:/xunlei/downloads --restart=unless-stopped --privileged cnk3x/xunlei:latest
docker run -d --privileged  -v /mnt/sda2:/xunlei/downloads -p 2345:2345 cnk3x/xunlei
docker run -d -v /mnt/usb1/siyuan:/siyuan/workspace  -e PUID=$UID  -e PGID=$GID  -p 6806:6806 b3log/siyuan  --workspace=/siyuan/workspace/ --accessAuthCode=xxx
docker run -d --name=siyuan -v /mnt/usb1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d --name syncthing  --restart always -p 3000:8384 -p 22000:22000/tcp -p 22000:22000/udp  -p 21027:21027/udp -v /mnt/config-sync:/var/syncthing/config -v /mnt:/var/syncthing/data syncthing/syncthing
docker run -d \
  --name syncthing \
  --restart always \
  -p 8384:8384 \
  -p 22000:22000/tcp \
  -p 22000:22000/udp \
  -p 21027:21027/udp \
  -v /mnt/usb2/syncthing/config:/var/syncthing/config \
  -v /mnt/usb2/syncthing/:/var/syncthing/data \
  syncthing/syncthing
docker run -d --name=samba  --restart unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NNN"  -v "/mnt:/storage" dockurr/samba
opkg install fdisk block-mount unzip zerotier samba4-server samba4-utils luci-app-samba4 openssh-sftp-server openvpn-openssl luci-app-openvpn wireguard-tools kmod-wireguard luci-proto-wi
mkdir -p /tmp/introot
mkdir -p /tmp/extroot
mount --bind / /tmp/introot
mount /dev/sda3 /tmp/extroot
tar -C /tmp/introot -cvf - . | tar -C /tmp/extroot -xf -
umount /tmp/introot
umount /tmp/extroot
docker run -d --name=samba --restart=unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NBBN"  -v "/mnt/:/storage" dockurr/samba
network:
  version: 2
  renderer: networkd
  wifis:
    wlp2s0:
      dhcp4: no
      addresses:
        - 192.168.0.124/24  # 这里改成你想要的静态 IP
      gateway4: 192.168.0.8  # 你的网关 IP（通常是路由器 IP）
      nameservers:
        addresses:
          - 211.140.13.188   
          - 114.114.114.114  # 114 DNS
      access-points:
        "boci1":
          password: "a1b2c3d4"


docker run --restart always --name openwrt1 -d --network macnet --privileged --ip 192.168.0.124   openwrt /sbin/init
docker run -d \
  --name=clash \
  -v /root/clash.yaml: /root/.config/clash/config.yaml \
  -p 7890:7890 \
  -p 9090:9090 \
  --restart unless-stopped \
  dreamacro/clash

安装官方最新版本：
curl -fsSL https://get.docker.com | bash
docker import rootfs.tar.gz my-custom-image
docker run -d \
  --name openwrt \
  --network host \
  --privileged \
  openwrt
docker run --restart always --name openwrt -p 80:80 -d --network host --privileged openwrt /sbin/init
允许 ZeroTier 网络访问本地网络
sudo iptables -A FORWARD -s 192.168.192.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 192.168.0.0/24 -d 192.168.192.0/24 -j ACCEPT
如果局域网设备默认网关不是 Ubuntu，需要 NAT
sudo iptables -t nat -A POSTROUTING -s 192.168.192.0/24 -d 192.168.0.0/24 -j MASQUERADE
eroTier 网络
192.168.0.0/24 via 192.168.191.112
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
ip route add 192.168.50.0/24 via 10.8.0.1 dev tun0
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
4.新启动 OpenVPN 服务
systemctl restart openvpn
docker run -d \
  --name=wg-easy \
  -e WG_HOST=39.174.229.143  \
  -e PASSWORD=888888  \
  -e WG_DEFAULT_ADDRESS=10.0.8.x \
  -e WG_DEFAULT_DNS=211.140.13.188 \
  -e WG_ALLOWED_IPS=10.0.8.0/24 \
  -e WG_PERSISTENT_KEEPALIVE=25 \
  -v ~/wg-easy:/etc/wireguard \
  -p 51820:51820/udp \
  -p 80:51821/tcp \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --sysctl="net.ipv4.ip_forward=1" \
  --restart unless-stopped \
  weejewel/wg-easy
network:
  ethernets:
    eth0:  # 请替换为你的实际网卡名称
      dhcp4: no
      addresses:
        - 192.168.0.219/24  # 设置静态 IP
      gateway4: 192.168.0.8  # 设置网关
      nameservers:
        addresses:
          - 211.140.13.188
  version: 2
ip route add 192.168.200.0/24 via 10.8.0.1 dev tun0
iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE
iptables -A FORWARD -i tun0 -o eth1 -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A FORWARD -i eth1 -o tun0 -j ACCEPT


docker run -d \
  --name=wg-easy \
  -e WG_HOST=39.174.229.143  \
  -e WG_DEFAULT_ADDRESS=10.0.8.x \
  -e WG_DEFAULT_DNS=211.140.13.188 \
  -e WG_ALLOWED_IPS=10.0.8.0/24 \
  -e WG_PERSISTENT_KEEPALIVE=25 \
  -v ~/wg-easy:/etc/wireguard \
  -p 51820:51820/udp \
  -p 2000:51821/tcp \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --sysctl="net.ipv4.ip_forward=1" \
  --restart unless-stopped \
  weejewel/wg-easy

enp1s0    enx00e04c360351
network:
  version: 2
  renderer: networkd
  ethernets:
    eth0:
      dhcp4: yes
      dhcp6: no
    enx00e04c360351:
      addresses:
        - 10.131.61.111/24
      dhcp4: no
sudo iptables -t nat -A POSTROUTING -o enp1s0 -j MASQUERADE
sudo iptables -A FORWARD -i enx00e04c360351 -o enp1s0 -j ACCEPT
sudo iptables -A FORWARD -i enp1s0 -o enx00e04c360351 -m state --state RELATED,ESTABLISHED -j ACCEPT
ip route add 22.8.144.97 via 10.130.61.1 dev enx00e04c360351
ip route add 22.8.144.97 via 10.131.61.1 dev br-lan  
ip route add 22.8.144.97 via 10.0.0.5 dev wireguard 
22.8.144.97
ip route add 22.8.144.97 via 192.168.0.8 dev eth0
39.174.229.143
10.0.0.0/24
uci show firewall | grep '@redirect'
docker run -d \
  --name=transmission \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -p 80:9091 \
  -p 51413:51413 \
  -p 51413:51413/udp \
  -v /home/download:/downloads \
  --restart unless-stopped \
  lscr.io/linuxserver/transmission:latest

docker run --restart always --name openwrt -d --network macnet --privileged --ip 10.1.25.193 ophub/openwrt-aarch64:latest
uci set zerotier.global.enabled='1'
uci delete zerotier.earth
uci set zerotier.openwrt_network=network
uci set zerotier.openwrt_network.id='856127940c66f22d'
uci commit zerotier
ip link set  eth0 promisc on
docker network create -d macvlan --subnet=192.168.50.0/24 --gateway=192.168.50.1 -o parent=br-lan  mynet
docker run  --name openwrt --restart unless-stopped -d --network mynet    --privileged --ip 192.168.50.314  openwrt  /sbin/init


c0: 20250204202213-2virs7k
c2: update
c3: 复制修改版
c5: 2025-03-13-101532-update/20250204202137-3g13i3l/20250204202213-2virs7k.sy
c6: 1741832132
c4:
通过 iPhone 镜像从 Mac 使用 iPhone
魔兽争霸:https://www.123pan.com/s/nVxFjv-fkwd3.html
dd if=openwrt-24.10.0-x86-64-generic-ext4-combined-efi.img of=/dev/sdb bs=4M
docker dockerd luci-lib-docker docker-compose
docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
dd if=/dev/sda of=/root/openwrt24.img bs=4M status=progress

docker run -d  -v /mnt/sda1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d \
  --name=qbittorrent \
  -e PUID=1000 -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -e WEBUI_PORT=8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -p 80:8080 \
  -v /home/qbittorrent/:/downloads \
  --restart unless-stopped \
  linuxserver/qbittorrent

docker run -d \
  --name=qbittorrent \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 2000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/sda2:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

dd if=istoreo.img of=/dev/sda bs=4M
docker run -d --name=xunlei --hostname=mynas --net=host -v /mnt/usb1:/xunlei/data -v /mnt/usb1/downloads:/xunlei/downloads --restart=unless-stopped --privileged cnk3x/xunlei:latest
docker run -d --privileged  -v /mnt/sda2:/xunlei/downloads -p 2345:2345 cnk3x/xunlei
docker run -d -v /mnt/usb1/siyuan:/siyuan/workspace  -e PUID=$UID  -e PGID=$GID  -p 6806:6806 b3log/siyuan  --workspace=/siyuan/workspace/ --accessAuthCode=xxx
docker run -d --name=siyuan -v /mnt/usb1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d --name syncthing  --restart always -p 3000:8384 -p 22000:22000/tcp -p 22000:22000/udp  -p 21027:21027/udp -v /mnt/config-sync:/var/syncthing/config -v /mnt:/var/syncthing/data syncthing/syncthing
docker run -d \
  --name syncthing \
  --restart always \
  -p 8384:8384 \
  -p 22000:22000/tcp \
  -p 22000:22000/udp \
  -p 21027:21027/udp \
  -v /mnt/usb2/syncthing/config:/var/syncthing/config \
  -v /mnt/usb2/syncthing/:/var/syncthing/data \
  syncthing/syncthing
docker run -d --name=samba  --restart unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NNN"  -v "/mnt:/storage" dockurr/samba
opkg install fdisk block-mount unzip zerotier samba4-server samba4-utils luci-app-samba4 openssh-sftp-server openvpn-openssl luci-app-openvpn wireguard-tools kmod-wireguard luci-proto-wi
mkdir -p /tmp/introot
mkdir -p /tmp/extroot
mount --bind / /tmp/introot
mount /dev/sda3 /tmp/extroot
tar -C /tmp/introot -cvf - . | tar -C /tmp/extroot -xf -
umount /tmp/introot
umount /tmp/extroot
docker run -d --name=samba --restart=unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NBBN"  -v "/mnt/:/storage" dockurr/samba
network:
  version: 2
  renderer: networkd
  wifis:
    wlp2s0:
      dhcp4: no
      addresses:
        - 192.168.0.124/24  # 这里改成你想要的静态 IP
      gateway4: 192.168.0.8  # 你的网关 IP（通常是路由器 IP）
      nameservers:
        addresses:
          - 211.140.13.188   
          - 114.114.114.114  # 114 DNS
      access-points:
        "boci1":
          password: "a1b2c3d4"


docker run --restart always --name openwrt1 -d --network macnet --privileged --ip 192.168.0.124   openwrt /sbin/init
docker run -d \
  --name=clash \
  -v /root/clash.yaml: /root/.config/clash/config.yaml \
  -p 7890:7890 \
  -p 9090:9090 \
  --restart unless-stopped \
  dreamacro/clash

安装官方最新版本：
curl -fsSL https://get.docker.com | bash
docker import rootfs.tar.gz my-custom-image
docker run -d \
  --name openwrt \
  --network host \
  --privileged \
  openwrt
docker run --restart always --name openwrt -p 80:80 -d --network host --privileged openwrt /sbin/init
允许 ZeroTier 网络访问本地网络
sudo iptables -A FORWARD -s 192.168.192.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 192.168.0.0/24 -d 192.168.192.0/24 -j ACCEPT
如果局域网设备默认网关不是 Ubuntu，需要 NAT
sudo iptables -t nat -A POSTROUTING -s 192.168.192.0/24 -d 192.168.0.0/24 -j MASQUERADE
eroTier 网络
192.168.0.0/24 via 192.168.191.112
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
ip route add 192.168.50.0/24 via 10.8.0.1 dev tun0
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
4.新启动 OpenVPN 服务
systemctl restart openvpn
docker run -d \
  --name=wg-easy \
  -e WG_HOST=39.174.229.143  \
  -e PASSWORD=888888  \
  -e WG_DEFAULT_ADDRESS=10.0.8.x \
  -e WG_DEFAULT_DNS=211.140.13.188 \
  -e WG_ALLOWED_IPS=10.0.8.0/24 \
  -e WG_PERSISTENT_KEEPALIVE=25 \
  -v ~/wg-easy:/etc/wireguard \
  -p 51820:51820/udp \
  -p 80:51821/tcp \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --sysctl="net.ipv4.ip_forward=1" \
  --restart unless-stopped \
  weejewel/wg-easy
network:
  ethernets:
    eth0:  # 请替换为你的实际网卡名称
      dhcp4: no
      addresses:
        - 192.168.0.219/24  # 设置静态 IP
      gateway4: 192.168.0.8  # 设置网关
      nameservers:
        addresses:
          - 211.140.13.188
  version: 2
ip route add 192.168.200.0/24 via 10.8.0.1 dev tun0
iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE
iptables -A FORWARD -i tun0 -o eth1 -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A FORWARD -i eth1 -o tun0 -j ACCEPT


docker run -d \
  --name=wireguard-client \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -v /mnt/Adisk:/config \
  -v /lib/modules:/lib/modules \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  lscr.io/linuxserver/wireguard:latest

enp1s0    enx00e04c360351
network:
  version: 2
  renderer: networkd
  ethernets:
    eth0:
      dhcp4: yes
      dhcp6: no
    enx00e04c360351:
      addresses:
        - 10.131.61.111/24
      dhcp4: no
sudo iptables -t nat -A POSTROUTING -o enp1s0 -j MASQUERADE
sudo iptables -A FORWARD -i enx00e04c360351 -o enp1s0 -j ACCEPT
sudo iptables -A FORWARD -i enp1s0 -o enx00e04c360351 -m state --state RELATED,ESTABLISHED -j ACCEPT
ip route add 22.8.144.97 via 10.130.61.1 dev enx00e04c360351
ip route add 22.8.144.97 via 10.131.61.1 dev br-lan  
ip route add 22.8.144.97 via 10.0.0.5 dev wireguard 
22.8.144.97
ip route add 22.8.144.97 via 192.168.0.8 dev eth0
39.174.229.143
10.0.0.0/24
uci show firewall | grep '@redirect'
docker run -d \
  --name=transmission \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -p 80:9091 \
  -p 51413:51413 \
  -p 51413:51413/udp \
  -v /home/download:/downloads \
  --restart unless-stopped \
  lscr.io/linuxserver/transmission:latest

docker run --restart always --name openwrt -d --network macnet --privileged --ip 10.1.25.193 ophub/openwrt-aarch64:latest
uci set zerotier.global.enabled='1'
uci delete zerotier.earth
uci set zerotier.openwrt_network=network
uci set zerotier.openwrt_network.id='856127940c66f22d'
uci commit zerotier
ip link set  eth0 promisc on
docker network create -d macvlan --subnet=192.168.50.0/24 --gateway=192.168.50.1 -o parent=br-lan  mynet
docker run  --name openwrt --restart unless-stopped -d --network mynet    --privileged --ip 192.168.50.314  openwrt  /sbin/init


c0: 20250204202213-2virs7k
c2: update
c3: 复制修改版
c5: 2025-03-13-110234-update/20250204202137-3g13i3l/20250204202213-2virs7k.sy
c6: 1741834954
c4:
通过 iPhone 镜像从 Mac 使用 iPhone
魔兽争霸:https://www.123pan.com/s/nVxFjv-fkwd3.html
dd if=openwrt-24.10.0-x86-64-generic-ext4-combined-efi.img of=/dev/sdb bs=4M
docker dockerd luci-lib-docker docker-compose
docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
dd if=/dev/sda of=/root/openwrt24.img bs=4M status=progress

docker run -d  -v /mnt/sda1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d \
  --name=qbittorrent \
  -e PUID=1000 -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -e WEBUI_PORT=8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -p 80:8080 \
  -v /home/qbittorrent/:/downloads \
  --restart unless-stopped \
  linuxserver/qbittorrent

docker run -d \
  --name=qbittorrent \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 2000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/sda2:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

dd if=istoreo.img of=/dev/sda bs=4M
docker run -d --name=xunlei --hostname=mynas --net=host -v /mnt/usb1:/xunlei/data -v /mnt/usb1/downloads:/xunlei/downloads --restart=unless-stopped --privileged cnk3x/xunlei:latest
docker run -d --privileged  -v /mnt/sda2:/xunlei/downloads -p 2345:2345 cnk3x/xunlei
docker run -d -v /mnt/usb1/siyuan:/siyuan/workspace  -e PUID=$UID  -e PGID=$GID  -p 6806:6806 b3log/siyuan  --workspace=/siyuan/workspace/ --accessAuthCode=xxx
docker run -d --name=siyuan -v /mnt/usb1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d --name syncthing  --restart always -p 3000:8384 -p 22000:22000/tcp -p 22000:22000/udp  -p 21027:21027/udp -v /mnt/config-sync:/var/syncthing/config -v /mnt:/var/syncthing/data syncthing/syncthing
docker run -d \
  --name syncthing \
  --restart always \
  -p 8384:8384 \
  -p 22000:22000/tcp \
  -p 22000:22000/udp \
  -p 21027:21027/udp \
  -v /mnt/usb2/syncthing/config:/var/syncthing/config \
  -v /mnt/usb2/syncthing/:/var/syncthing/data \
  syncthing/syncthing
docker run -d --name=samba  --restart unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NNN"  -v "/mnt:/storage" dockurr/samba
opkg install fdisk block-mount unzip zerotier samba4-server samba4-utils luci-app-samba4 openssh-sftp-server openvpn-openssl luci-app-openvpn wireguard-tools kmod-wireguard luci-proto-wi
mkdir -p /tmp/introot
mkdir -p /tmp/extroot
mount --bind / /tmp/introot
mount /dev/sda3 /tmp/extroot
tar -C /tmp/introot -cvf - . | tar -C /tmp/extroot -xf -
umount /tmp/introot
umount /tmp/extroot
docker run -d --name=samba --restart=unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NBBN"  -v "/mnt/:/storage" dockurr/samba
network:
  version: 2
  renderer: networkd
  wifis:
    wlp2s0:
      dhcp4: no
      addresses:
        - 192.168.0.124/24  # 这里改成你想要的静态 IP
      gateway4: 192.168.0.8  # 你的网关 IP（通常是路由器 IP）
      nameservers:
        addresses:
          - 211.140.13.188   
          - 114.114.114.114  # 114 DNS
      access-points:
        "boci1":
          password: "a1b2c3d4"


docker run --restart always --name openwrt1 -d --network macnet --privileged --ip 192.168.0.124   openwrt /sbin/init
docker run -d \
  --name=clash \
  -v /root/clash.yaml: /root/.config/clash/config.yaml \
  -p 7890:7890 \
  -p 9090:9090 \
  --restart unless-stopped \
  dreamacro/clash

安装官方最新版本：
curl -fsSL https://get.docker.com | bash
docker import rootfs.tar.gz my-custom-image
docker run -d \
  --name openwrt \
  --network host \
  --privileged \
  openwrt
docker run --restart always --name openwrt -p 80:80 -d --network host --privileged openwrt /sbin/init
允许 ZeroTier 网络访问本地网络
sudo iptables -A FORWARD -s 192.168.192.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 192.168.0.0/24 -d 192.168.192.0/24 -j ACCEPT
如果局域网设备默认网关不是 Ubuntu，需要 NAT
sudo iptables -t nat -A POSTROUTING -s 192.168.192.0/24 -d 192.168.0.0/24 -j MASQUERADE
eroTier 网络
192.168.0.0/24 via 192.168.191.112
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
ip route add 192.168.50.0/24 via 10.8.0.1 dev tun0
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
4.新启动 OpenVPN 服务
systemctl restart openvpn
docker run -d \
  --name=wg-easy \
  -e WG_HOST=39.174.229.143  \
  -e PASSWORD=888888  \
  -e WG_DEFAULT_ADDRESS=10.0.8.x \
  -e WG_DEFAULT_DNS=211.140.13.188 \
  -e WG_ALLOWED_IPS=10.0.8.0/24 \
  -e WG_PERSISTENT_KEEPALIVE=25 \
  -v ~/wg-easy:/etc/wireguard \
  -p 51820:51820/udp \
  -p 80:51821/tcp \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --sysctl="net.ipv4.ip_forward=1" \
  --restart unless-stopped \
  weejewel/wg-easy
network:
  ethernets:
    eth0:  # 请替换为你的实际网卡名称
      dhcp4: no
      addresses:
        - 192.168.0.219/24  # 设置静态 IP
      gateway4: 192.168.0.8  # 设置网关
      nameservers:
        addresses:
          - 211.140.13.188
  version: 2
ip route add 192.168.200.0/24 via 10.8.0.1 dev tun0
iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE
iptables -A FORWARD -i tun0 -o eth1 -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A FORWARD -i eth1 -o tun0 -j ACCEPT


docker run -d \
  --name=wireguard-client1 \
  --cap-add=NET_ADMIN \
  -v /mnt/:/etc/wireguard \
  --restart unless-stopped \
  gitdebiand/wireguard-tools_frps_amd64x86

enp1s0    enx00e04c360351
network:
  version: 2
  renderer: networkd
  ethernets:
    eth0:
      dhcp4: yes
      dhcp6: no
    enx00e04c360351:
      addresses:
        - 10.131.61.111/24
      dhcp4: no
sudo iptables -t nat -A POSTROUTING -o enp1s0 -j MASQUERADE
sudo iptables -A FORWARD -i enx00e04c360351 -o enp1s0 -j ACCEPT
sudo iptables -A FORWARD -i enp1s0 -o enx00e04c360351 -m state --state RELATED,ESTABLISHED -j ACCEPT
ip route add 22.8.144.97 via 10.130.61.1 dev enx00e04c360351
ip route add 22.8.144.97 via 10.131.61.1 dev br-lan  
ip route add 22.8.144.97 via 10.0.0.5 dev wireguard 
22.8.144.97
ip route add 22.8.144.97 via 192.168.0.8 dev eth0
39.174.229.143
10.0.0.0/24
uci show firewall | grep '@redirect'
docker run -d \
  --name=transmission \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -p 80:9091 \
  -p 51413:51413 \
  -p 51413:51413/udp \
  -v /home/download:/downloads \
  --restart unless-stopped \
  lscr.io/linuxserver/transmission:latest

docker run --restart always --name openwrt -d --network macnet --privileged --ip 10.1.25.193 ophub/openwrt-aarch64:latest
uci set zerotier.global.enabled='1'
uci delete zerotier.earth
uci set zerotier.openwrt_network=network
uci set zerotier.openwrt_network.id='856127940c66f22d'
uci commit zerotier
ip link set  eth0 promisc on
docker network create -d macvlan --subnet=192.168.50.0/24 --gateway=192.168.50.1 -o parent=br-lan  mynet
docker run  --name openwrt --restart unless-stopped -d --network mynet    --privileged --ip 192.168.50.314  openwrt  /sbin/init


c0: 20250204202213-2virs7k
c2: update
c3: 复制修改版
c5: 2025-03-13-111234-update/20250204202137-3g13i3l/20250204202213-2virs7k.sy
c6: 1741835554
c4:
通过 iPhone 镜像从 Mac 使用 iPhone
魔兽争霸:https://www.123pan.com/s/nVxFjv-fkwd3.html
dd if=openwrt-24.10.0-x86-64-generic-ext4-combined-efi.img of=/dev/sdb bs=4M
docker dockerd luci-lib-docker docker-compose
docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
dd if=/dev/sda of=/root/openwrt24.img bs=4M status=progress

docker run -d  -v /mnt/sda1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d \
  --name=qbittorrent \
  -e PUID=1000 -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -e WEBUI_PORT=8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -p 80:8080 \
  -v /home/qbittorrent/:/downloads \
  --restart unless-stopped \
  linuxserver/qbittorrent

docker run -d \
  --name=qbittorrent \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 2000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/sda2:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

dd if=istoreo.img of=/dev/sda bs=4M
docker run -d --name=xunlei --hostname=mynas --net=host -v /mnt/usb1:/xunlei/data -v /mnt/usb1/downloads:/xunlei/downloads --restart=unless-stopped --privileged cnk3x/xunlei:latest
docker run -d --privileged  -v /mnt/sda2:/xunlei/downloads -p 2345:2345 cnk3x/xunlei
docker run -d -v /mnt/usb1/siyuan:/siyuan/workspace  -e PUID=$UID  -e PGID=$GID  -p 6806:6806 b3log/siyuan  --workspace=/siyuan/workspace/ --accessAuthCode=xxx
docker run -d --name=siyuan -v /mnt/usb1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d --name syncthing  --restart always -p 3000:8384 -p 22000:22000/tcp -p 22000:22000/udp  -p 21027:21027/udp -v /mnt/config-sync:/var/syncthing/config -v /mnt:/var/syncthing/data syncthing/syncthing
docker run -d \
  --name syncthing \
  --restart always \
  -p 8384:8384 \
  -p 22000:22000/tcp \
  -p 22000:22000/udp \
  -p 21027:21027/udp \
  -v /mnt/usb2/syncthing/config:/var/syncthing/config \
  -v /mnt/usb2/syncthing/:/var/syncthing/data \
  syncthing/syncthing
docker run -d --name=samba  --restart unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NNN"  -v "/mnt:/storage" dockurr/samba
opkg install fdisk block-mount unzip zerotier samba4-server samba4-utils luci-app-samba4 openssh-sftp-server openvpn-openssl luci-app-openvpn wireguard-tools kmod-wireguard luci-proto-wi
mkdir -p /tmp/introot
mkdir -p /tmp/extroot
mount --bind / /tmp/introot
mount /dev/sda3 /tmp/extroot
tar -C /tmp/introot -cvf - . | tar -C /tmp/extroot -xf -
umount /tmp/introot
umount /tmp/extroot
docker run -d --name=samba --restart=unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NBBN"  -v "/mnt/:/storage" dockurr/samba
network:
  version: 2
  renderer: networkd
  wifis:
    wlp2s0:
      dhcp4: no
      addresses:
        - 192.168.0.124/24  # 这里改成你想要的静态 IP
      gateway4: 192.168.0.8  # 你的网关 IP（通常是路由器 IP）
      nameservers:
        addresses:
          - 211.140.13.188   
          - 114.114.114.114  # 114 DNS
      access-points:
        "boci1":
          password: "a1b2c3d4"


docker run --restart always --name openwrt1 -d --network macnet --privileged --ip 192.168.0.124   openwrt /sbin/init
docker run -d \
  --name=clash \
  -v /root/clash.yaml: /root/.config/clash/config.yaml \
  -p 7890:7890 \
  -p 9090:9090 \
  --restart unless-stopped \
  dreamacro/clash

安装官方最新版本：
curl -fsSL https://get.docker.com | bash
docker import rootfs.tar.gz my-custom-image
docker run -d \
  --name openwrt \
  --network host \
  --privileged \
  openwrt
docker run --restart always --name openwrt -p 80:80 -d --network host --privileged openwrt /sbin/init
允许 ZeroTier 网络访问本地网络
sudo iptables -A FORWARD -s 192.168.192.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 192.168.0.0/24 -d 192.168.192.0/24 -j ACCEPT
如果局域网设备默认网关不是 Ubuntu，需要 NAT
sudo iptables -t nat -A POSTROUTING -s 192.168.192.0/24 -d 192.168.0.0/24 -j MASQUERADE
eroTier 网络
192.168.0.0/24 via 192.168.191.112
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
ip route add 192.168.50.0/24 via 10.8.0.1 dev tun0
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
4.新启动 OpenVPN 服务
systemctl restart openvpn
docker run -d \
  --name=wireguard-client2 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  -v /mnt/NNN.conf:/etc/wireguard/wg0.conf \
  --restart unless-stopped \
  ghcr.io/wg-net/wireguard-go:latest
network:
  ethernets:
    eth0:  # 请替换为你的实际网卡名称
      dhcp4: no
      addresses:
        - 192.168.0.219/24  # 设置静态 IP
      gateway4: 192.168.0.8  # 设置网关
      nameservers:
        addresses:
          - 211.140.13.188
  version: 2
ip route add 192.168.200.0/24 via 10.8.0.1 dev tun0
iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE
iptables -A FORWARD -i tun0 -o eth1 -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A FORWARD -i eth1 -o tun0 -j ACCEPT


docker run -d \
  --name=wireguard-client \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -v /mnt:/config \
  -v /lib/modules:/lib/modules \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  lscr.io/linuxserver/wireguard:latest

enp1s0    enx00e04c360351
network:
  version: 2
  renderer: networkd
  ethernets:
    eth0:
      dhcp4: yes
      dhcp6: no
    enx00e04c360351:
      addresses:
        - 10.131.61.111/24
      dhcp4: no
sudo iptables -t nat -A POSTROUTING -o enp1s0 -j MASQUERADE
sudo iptables -A FORWARD -i enx00e04c360351 -o enp1s0 -j ACCEPT
sudo iptables -A FORWARD -i enp1s0 -o enx00e04c360351 -m state --state RELATED,ESTABLISHED -j ACCEPT
ip route add 22.8.144.97 via 10.130.61.1 dev enx00e04c360351
ip route add 22.8.144.97 via 10.131.61.1 dev br-lan  
ip route add 22.8.144.97 via 10.0.0.5 dev wireguard 
22.8.144.97
ip route add 22.8.144.97 via 192.168.0.8 dev eth0
39.174.229.143
10.0.0.0/24
uci show firewall | grep '@redirect'
docker run -d \
  --name=transmission \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -p 80:9091 \
  -p 51413:51413 \
  -p 51413:51413/udp \
  -v /home/download:/downloads \
  --restart unless-stopped \
  lscr.io/linuxserver/transmission:latest

docker run --restart always --name openwrt -d --network macnet --privileged --ip 10.1.25.193 ophub/openwrt-aarch64:latest
uci set zerotier.global.enabled='1'
uci delete zerotier.earth
uci set zerotier.openwrt_network=network
uci set zerotier.openwrt_network.id='856127940c66f22d'
uci commit zerotier
ip link set  eth0 promisc on
docker network create -d macvlan --subnet=192.168.50.0/24 --gateway=192.168.50.1 -o parent=br-lan  mynet
docker run  --name openwrt --restart unless-stopped -d --network mynet    --privileged --ip 192.168.50.314  openwrt  /sbin/init


c0: 20250204202213-2virs7k
c2: update
c3: 复制修改版
c5: 2025-03-13-112234-update/20250204202137-3g13i3l/20250204202213-2virs7k.sy
c6: 1741836154
c4:
通过 iPhone 镜像从 Mac 使用 iPhone
魔兽争霸:https://www.123pan.com/s/nVxFjv-fkwd3.html
dd if=openwrt-24.10.0-x86-64-generic-ext4-combined-efi.img of=/dev/sdb bs=4M
docker dockerd luci-lib-docker docker-compose
docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
dd if=/dev/sda of=/root/openwrt24.img bs=4M status=progress

docker run -d  -v /mnt/sda1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d \
  --name=qbittorrent \
  -e PUID=1000 -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -e WEBUI_PORT=8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -p 80:8080 \
  -v /home/qbittorrent/:/downloads \
  --restart unless-stopped \
  linuxserver/qbittorrent

docker run -d \
  --name=qbittorrent \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 2000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/sda2:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

dd if=istoreo.img of=/dev/sda bs=4M
docker run -d --name=xunlei --hostname=mynas --net=host -v /mnt/usb1:/xunlei/data -v /mnt/usb1/downloads:/xunlei/downloads --restart=unless-stopped --privileged cnk3x/xunlei:latest
docker run -d --privileged  -v /mnt/sda2:/xunlei/downloads -p 2345:2345 cnk3x/xunlei
docker run -d -v /mnt/usb1/siyuan:/siyuan/workspace  -e PUID=$UID  -e PGID=$GID  -p 6806:6806 b3log/siyuan  --workspace=/siyuan/workspace/ --accessAuthCode=xxx
docker run -d --name=siyuan -v /mnt/usb1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d --name syncthing  --restart always -p 3000:8384 -p 22000:22000/tcp -p 22000:22000/udp  -p 21027:21027/udp -v /mnt/config-sync:/var/syncthing/config -v /mnt:/var/syncthing/data syncthing/syncthing
docker run -d \
  --name syncthing \
  --restart always \
  -p 8384:8384 \
  -p 22000:22000/tcp \
  -p 22000:22000/udp \
  -p 21027:21027/udp \
  -v /mnt/usb2/syncthing/config:/var/syncthing/config \
  -v /mnt/usb2/syncthing/:/var/syncthing/data \
  syncthing/syncthing
docker run -d --name=samba  --restart unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NNN"  -v "/mnt:/storage" dockurr/samba
opkg install fdisk block-mount unzip zerotier samba4-server samba4-utils luci-app-samba4 openssh-sftp-server openvpn-openssl luci-app-openvpn wireguard-tools kmod-wireguard luci-proto-wi
mkdir -p /tmp/introot
mkdir -p /tmp/extroot
mount --bind / /tmp/introot
mount /dev/sda3 /tmp/extroot
tar -C /tmp/introot -cvf - . | tar -C /tmp/extroot -xf -
umount /tmp/introot
umount /tmp/extroot
docker run -d --name=samba --restart=unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NBBN"  -v "/mnt/:/storage" dockurr/samba
network:
  version: 2
  renderer: networkd
  wifis:
    wlp2s0:
      dhcp4: no
      addresses:
        - 192.168.0.124/24  # 这里改成你想要的静态 IP
      gateway4: 192.168.0.8  # 你的网关 IP（通常是路由器 IP）
      nameservers:
        addresses:
          - 211.140.13.188   
          - 114.114.114.114  # 114 DNS
      access-points:
        "boci1":
          password: "a1b2c3d4"


docker run --restart always --name openwrt1 -d --network macnet --privileged --ip 192.168.0.124   openwrt /sbin/init
docker run -d \
  --name=clash \
  -v /root/clash.yaml: /root/.config/clash/config.yaml \
  -p 7890:7890 \
  -p 9090:9090 \
  --restart unless-stopped \
  dreamacro/clash

安装官方最新版本：
curl -fsSL https://get.docker.com | bash
docker import rootfs.tar.gz my-custom-image
docker run -d \
  --name openwrt \
  --network host \
  --privileged \
  openwrt
docker run --restart always --name openwrt -p 80:80 -d --network host --privileged openwrt /sbin/init
允许 ZeroTier 网络访问本地网络
sudo iptables -A FORWARD -s 192.168.192.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 192.168.0.0/24 -d 192.168.192.0/24 -j ACCEPT
如果局域网设备默认网关不是 Ubuntu，需要 NAT
sudo iptables -t nat -A POSTROUTING -s 192.168.192.0/24 -d 192.168.0.0/24 -j MASQUERADE
eroTier 网络
192.168.0.0/24 via 192.168.191.112
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
ip route add 192.168.50.0/24 via 10.8.0.1 dev tun0
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
4.新启动 OpenVPN 服务
systemctl restart openvpn
docker run -d \
  --name=wg-client \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  weejewel/wg-easy
network:
  ethernets:
    eth0:  # 请替换为你的实际网卡名称
      dhcp4: no
      addresses:
        - 192.168.0.219/24  # 设置静态 IP
      gateway4: 192.168.0.8  # 设置网关
      nameservers:
        addresses:
          - 211.140.13.188
  version: 2
ip route add 192.168.200.0/24 via 10.8.0.1 dev tun0
iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE
iptables -A FORWARD -i tun0 -o eth1 -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A FORWARD -i eth1 -o tun0 -j ACCEPT


docker run -d \
  --name=wireguard-client \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -v /mnt:/config \
  -v /lib/modules:/lib/modules \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  lscr.io/linuxserver/wireguard:latest

enp1s0    enx00e04c360351
network:
  version: 2
  renderer: networkd
  ethernets:
    eth0:
      dhcp4: yes
      dhcp6: no
    enx00e04c360351:
      addresses:
        - 10.131.61.111/24
      dhcp4: no
sudo iptables -t nat -A POSTROUTING -o enp1s0 -j MASQUERADE
sudo iptables -A FORWARD -i enx00e04c360351 -o enp1s0 -j ACCEPT
sudo iptables -A FORWARD -i enp1s0 -o enx00e04c360351 -m state --state RELATED,ESTABLISHED -j ACCEPT
ip route add 22.8.144.97 via 10.130.61.1 dev enx00e04c360351
ip route add 22.8.144.97 via 10.131.61.1 dev br-lan  
ip route add 22.8.144.97 via 10.0.0.5 dev wireguard 
22.8.144.97
ip route add 22.8.144.97 via 192.168.0.8 dev eth0
39.174.229.143
10.0.0.0/24
uci show firewall | grep '@redirect'
docker run -d \
  --name=transmission \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -p 80:9091 \
  -p 51413:51413 \
  -p 51413:51413/udp \
  -v /home/download:/downloads \
  --restart unless-stopped \
  lscr.io/linuxserver/transmission:latest

docker run --restart always --name openwrt -d --network macnet --privileged --ip 10.1.25.193 ophub/openwrt-aarch64:latest
uci set zerotier.global.enabled='1'
uci delete zerotier.earth
uci set zerotier.openwrt_network=network
uci set zerotier.openwrt_network.id='856127940c66f22d'
uci commit zerotier
ip link set  eth0 promisc on
docker network create -d macvlan --subnet=192.168.50.0/24 --gateway=192.168.50.1 -o parent=br-lan  mynet
docker run  --name openwrt --restart unless-stopped -d --network mynet    --privileged --ip 192.168.50.314  openwrt  /sbin/init


c0: 20250204202213-2virs7k
c2: update
c3: 复制修改版
c5: 2025-03-13-113234-update/20250204202137-3g13i3l/20250204202213-2virs7k.sy
c6: 1741836754
c4:
通过 iPhone 镜像从 Mac 使用 iPhone
魔兽争霸:https://www.123pan.com/s/nVxFjv-fkwd3.html
dd if=openwrt-24.10.0-x86-64-generic-ext4-combined-efi.img of=/dev/sdb bs=4M
docker dockerd luci-lib-docker docker-compose
docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
dd if=/dev/sda of=/root/openwrt24.img bs=4M status=progress

docker run -d  -v /mnt/sda1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d \
  --name=qbittorrent \
  -e PUID=1000 -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -e WEBUI_PORT=8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -p 80:8080 \
  -v /home/qbittorrent/:/downloads \
  --restart unless-stopped \
  linuxserver/qbittorrent

docker run -d \
  --name=qbittorrent \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 2000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/sda2:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

dd if=istoreo.img of=/dev/sda bs=4M
docker run -d --name=xunlei --hostname=mynas --net=host -v /mnt/usb1:/xunlei/data -v /mnt/usb1/downloads:/xunlei/downloads --restart=unless-stopped --privileged cnk3x/xunlei:latest
docker run -d --privileged  -v /mnt/sda2:/xunlei/downloads -p 2345:2345 cnk3x/xunlei
docker run -d -v /mnt/usb1/siyuan:/siyuan/workspace  -e PUID=$UID  -e PGID=$GID  -p 6806:6806 b3log/siyuan  --workspace=/siyuan/workspace/ --accessAuthCode=xxx
docker run -d --name=siyuan -v /mnt/usb1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d --name syncthing  --restart always -p 3000:8384 -p 22000:22000/tcp -p 22000:22000/udp  -p 21027:21027/udp -v /mnt/config-sync:/var/syncthing/config -v /mnt:/var/syncthing/data syncthing/syncthing
docker run -d \
  --name syncthing \
  --restart always \
  -p 8384:8384 \
  -p 22000:22000/tcp \
  -p 22000:22000/udp \
  -p 21027:21027/udp \
  -v /mnt/usb2/syncthing/config:/var/syncthing/config \
  -v /mnt/usb2/syncthing/:/var/syncthing/data \
  syncthing/syncthing
docker run -d --name=samba  --restart unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NNN"  -v "/mnt:/storage" dockurr/samba
opkg install fdisk block-mount unzip zerotier samba4-server samba4-utils luci-app-samba4 openssh-sftp-server openvpn-openssl luci-app-openvpn wireguard-tools kmod-wireguard luci-proto-wi
mkdir -p /tmp/introot
mkdir -p /tmp/extroot
mount --bind / /tmp/introot
mount /dev/sda3 /tmp/extroot
tar -C /tmp/introot -cvf - . | tar -C /tmp/extroot -xf -
umount /tmp/introot
umount /tmp/extroot
docker run -d --name=samba --restart=unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NBBN"  -v "/mnt/:/storage" dockurr/samba
network:
  version: 2
  renderer: networkd
  wifis:
    wlp2s0:
      dhcp4: no
      addresses:
        - 192.168.0.124/24  # 这里改成你想要的静态 IP
      gateway4: 192.168.0.8  # 你的网关 IP（通常是路由器 IP）
      nameservers:
        addresses:
          - 211.140.13.188   
          - 114.114.114.114  # 114 DNS
      access-points:
        "boci1":
          password: "a1b2c3d4"


docker run --restart always --name openwrt1 -d --network macnet --privileged --ip 192.168.0.124   openwrt /sbin/init
docker run -d \
  --name=clash \
  -v /root/clash.yaml: /root/.config/clash/config.yaml \
  -p 7890:7890 \
  -p 9090:9090 \
  --restart unless-stopped \
  dreamacro/clash

安装官方最新版本：
curl -fsSL https://get.docker.com | bash
docker import rootfs.tar.gz my-custom-image
docker run -d \
  --name openwrt \
  --network host \
  --privileged \
  openwrt
docker run --restart always --name openwrt -p 80:80 -d --network host --privileged openwrt /sbin/init
允许 ZeroTier 网络访问本地网络
sudo iptables -A FORWARD -s 192.168.192.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 192.168.0.0/24 -d 192.168.192.0/24 -j ACCEPT
如果局域网设备默认网关不是 Ubuntu，需要 NAT
sudo iptables -t nat -A POSTROUTING -s 192.168.192.0/24 -d 192.168.0.0/24 -j MASQUERADE
eroTier 网络
192.168.0.0/24 via 192.168.191.112
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
ip route add 192.168.50.0/24 via 10.8.0.1 dev tun0
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
4.新启动 OpenVPN 服务
systemctl restart openvpn
docker run -d \
  --name=wg-client2 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  -v /mnt/wg0:/etc/wireguard/wg0 \
  weejewel/wg-easy
docker run -d \
  --name=wg-client \
  -e WG_HOST=10.0.0.1 \
  -e PASSWORD= \
  -v /mnt/wg0:/etc/wireguard/wg0 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  weejewel/wg-easy

network:
  ethernets:
    eth0:  # 请替换为你的实际网卡名称
      dhcp4: no
      addresses:
        - 192.168.0.219/24  # 设置静态 IP
      gateway4: 192.168.0.8  # 设置网关
      nameservers:
        addresses:
          - 211.140.13.188
  version: 2
ip route add 192.168.200.0/24 via 10.8.0.1 dev tun0
iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE
iptables -A FORWARD -i tun0 -o eth1 -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A FORWARD -i eth1 -o tun0 -j ACCEPT


docker run -d \
  --name=wireguard-client \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -v /mnt:/config \
  -v /lib/modules:/lib/modules \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  lscr.io/linuxserver/wireguard:latest

enp1s0    enx00e04c360351
network:
  version: 2
  renderer: networkd
  ethernets:
    eth0:
      dhcp4: yes
      dhcp6: no
    enx00e04c360351:
      addresses:
        - 10.131.61.111/24
      dhcp4: no
sudo iptables -t nat -A POSTROUTING -o enp1s0 -j MASQUERADE
sudo iptables -A FORWARD -i enx00e04c360351 -o enp1s0 -j ACCEPT
sudo iptables -A FORWARD -i enp1s0 -o enx00e04c360351 -m state --state RELATED,ESTABLISHED -j ACCEPT
ip route add 22.8.144.97 via 10.130.61.1 dev enx00e04c360351
ip route add 22.8.144.97 via 10.131.61.1 dev br-lan  
ip route add 22.8.144.97 via 10.0.0.5 dev wireguard 
22.8.144.97
ip route add 22.8.144.97 via 192.168.0.8 dev eth0
39.174.229.143
10.0.0.0/24
uci show firewall | grep '@redirect'
docker run -d \
  --name=transmission \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -p 80:9091 \
  -p 51413:51413 \
  -p 51413:51413/udp \
  -v /home/download:/downloads \
  --restart unless-stopped \
  lscr.io/linuxserver/transmission:latest

docker run --restart always --name openwrt -d --network macnet --privileged --ip 10.1.25.193 ophub/openwrt-aarch64:latest
uci set zerotier.global.enabled='1'
uci delete zerotier.earth
uci set zerotier.openwrt_network=network
uci set zerotier.openwrt_network.id='856127940c66f22d'
uci commit zerotier
ip link set  eth0 promisc on
docker network create -d macvlan --subnet=192.168.50.0/24 --gateway=192.168.50.1 -o parent=br-lan  mynet
docker run  --name openwrt --restart unless-stopped -d --network mynet    --privileged --ip 192.168.50.314  openwrt  /sbin/init


c0: 20250204202213-2virs7k
c2: update
c3: 复制修改版
c5: 2025-03-13-114234-update/20250204202137-3g13i3l/20250204202213-2virs7k.sy
c6: 1741837354
c4:
通过 iPhone 镜像从 Mac 使用 iPhone
魔兽争霸:https://www.123pan.com/s/nVxFjv-fkwd3.html
dd if=openwrt-24.10.0-x86-64-generic-ext4-combined-efi.img of=/dev/sdb bs=4M
docker dockerd luci-lib-docker docker-compose
docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
dd if=/dev/sda of=/root/openwrt24.img bs=4M status=progress

docker run -d  -v /mnt/sda1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d \
  --name=qbittorrent \
  -e PUID=1000 -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -e WEBUI_PORT=8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -p 80:8080 \
  -v /home/qbittorrent/:/downloads \
  --restart unless-stopped \
  linuxserver/qbittorrent

docker run -d \
  --name=qbittorrent \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 2000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/sda2:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

dd if=istoreo.img of=/dev/sda bs=4M
docker run -d --name=xunlei --hostname=mynas --net=host -v /mnt/usb1:/xunlei/data -v /mnt/usb1/downloads:/xunlei/downloads --restart=unless-stopped --privileged cnk3x/xunlei:latest
docker run -d --privileged  -v /mnt/sda2:/xunlei/downloads -p 2345:2345 cnk3x/xunlei
docker run -d -v /mnt/usb1/siyuan:/siyuan/workspace  -e PUID=$UID  -e PGID=$GID  -p 6806:6806 b3log/siyuan  --workspace=/siyuan/workspace/ --accessAuthCode=xxx
docker run -d --name=siyuan -v /mnt/usb1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d --name syncthing  --restart always -p 3000:8384 -p 22000:22000/tcp -p 22000:22000/udp  -p 21027:21027/udp -v /mnt/config-sync:/var/syncthing/config -v /mnt:/var/syncthing/data syncthing/syncthing
docker run -d \
  --name syncthing \
  --restart always \
  -p 8384:8384 \
  -p 22000:22000/tcp \
  -p 22000:22000/udp \
  -p 21027:21027/udp \
  -v /mnt/usb2/syncthing/config:/var/syncthing/config \
  -v /mnt/usb2/syncthing/:/var/syncthing/data \
  syncthing/syncthing
docker run -d --name=samba  --restart unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NNN"  -v "/mnt:/storage" dockurr/samba
opkg install fdisk block-mount unzip zerotier samba4-server samba4-utils luci-app-samba4 openssh-sftp-server openvpn-openssl luci-app-openvpn wireguard-tools kmod-wireguard luci-proto-wi
mkdir -p /tmp/introot
mkdir -p /tmp/extroot
mount --bind / /tmp/introot
mount /dev/sda3 /tmp/extroot
tar -C /tmp/introot -cvf - . | tar -C /tmp/extroot -xf -
umount /tmp/introot
umount /tmp/extroot
docker run -d --name=samba --restart=unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NBBN"  -v "/mnt/:/storage" dockurr/samba
network:
  version: 2
  renderer: networkd
  wifis:
    wlp2s0:
      dhcp4: no
      addresses:
        - 192.168.0.124/24  # 这里改成你想要的静态 IP
      gateway4: 192.168.0.8  # 你的网关 IP（通常是路由器 IP）
      nameservers:
        addresses:
          - 211.140.13.188   
          - 114.114.114.114  # 114 DNS
      access-points:
        "boci1":
          password: "a1b2c3d4"


docker run --restart always --name openwrt1 -d --network macnet --privileged --ip 192.168.0.124   openwrt /sbin/init
docker run -d \
  --name=clash \
  -v /root/clash.yaml: /root/.config/clash/config.yaml \
  -p 7890:7890 \
  -p 9090:9090 \
  --restart unless-stopped \
  dreamacro/clash

安装官方最新版本：
curl -fsSL https://get.docker.com | bash
docker import rootfs.tar.gz my-custom-image
docker run -d \
  --name openwrt \
  --network host \
  --privileged \
  openwrt
docker run --restart always --name openwrt -p 80:80 -d --network host --privileged openwrt /sbin/init
允许 ZeroTier 网络访问本地网络
sudo iptables -A FORWARD -s 192.168.192.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 192.168.0.0/24 -d 192.168.192.0/24 -j ACCEPT
如果局域网设备默认网关不是 Ubuntu，需要 NAT
sudo iptables -t nat -A POSTROUTING -s 192.168.192.0/24 -d 192.168.0.0/24 -j MASQUERADE
eroTier 网络
192.168.0.0/24 via 192.168.191.112
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
ip route add 192.168.50.0/24 via 10.8.0.1 dev tun0
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
4.新启动 OpenVPN 服务
systemctl restart openvpn
docker run -d \
  --name=wg-client2 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  -v /mnt/wg0:/etc/wireguard/wg0 \
  weejewel/wg-easy
docker run -d \
  --name=wg-client \
  -e WG_HOST=10.0.0.1 \
  -e PASSWORD= \
  -v /mnt/Adisk/wireguard/:/etc/wireguard/ \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  weejewel/wg-easy

network:
  ethernets:
    eth0:  # 请替换为你的实际网卡名称
      dhcp4: no
      addresses:
        - 192.168.0.219/24  # 设置静态 IP
      gateway4: 192.168.0.8  # 设置网关
      nameservers:
        addresses:
          - 211.140.13.188
  version: 2
ip route add 192.168.200.0/24 via 10.8.0.1 dev tun0
iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE
iptables -A FORWARD -i tun0 -o eth1 -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A FORWARD -i eth1 -o tun0 -j ACCEPT


docker run -d \
  --name=wireguard-client \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -v /mnt:/config \
  -v /lib/modules:/lib/modules \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  lscr.io/linuxserver/wireguard:latest

enp1s0    enx00e04c360351
network:
  version: 2
  renderer: networkd
  ethernets:
    eth0:
      dhcp4: yes
      dhcp6: no
    enx00e04c360351:
      addresses:
        - 10.131.61.111/24
      dhcp4: no
sudo iptables -t nat -A POSTROUTING -o enp1s0 -j MASQUERADE
sudo iptables -A FORWARD -i enx00e04c360351 -o enp1s0 -j ACCEPT
sudo iptables -A FORWARD -i enp1s0 -o enx00e04c360351 -m state --state RELATED,ESTABLISHED -j ACCEPT
ip route add 22.8.144.97 via 10.130.61.1 dev enx00e04c360351
ip route add 22.8.144.97 via 10.131.61.1 dev br-lan  
ip route add 22.8.144.97 via 10.0.0.5 dev wireguard 
22.8.144.97
ip route add 22.8.144.97 via 192.168.0.8 dev eth0
39.174.229.143
10.0.0.0/24
uci show firewall | grep '@redirect'
docker run -d \
  --name=transmission \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -p 80:9091 \
  -p 51413:51413 \
  -p 51413:51413/udp \
  -v /home/download:/downloads \
  --restart unless-stopped \
  lscr.io/linuxserver/transmission:latest

docker run --restart always --name openwrt -d --network macnet --privileged --ip 10.1.25.193 ophub/openwrt-aarch64:latest
uci set zerotier.global.enabled='1'
uci delete zerotier.earth
uci set zerotier.openwrt_network=network
uci set zerotier.openwrt_network.id='856127940c66f22d'
uci commit zerotier
ip link set  eth0 promisc on
docker network create -d macvlan --subnet=192.168.50.0/24 --gateway=192.168.50.1 -o parent=br-lan  mynet
docker run  --name openwrt --restart unless-stopped -d --network mynet    --privileged --ip 192.168.50.314  openwrt  /sbin/init


c0: 20240220152630-qly715s
c2: update
c3: docker部署
c5: 2025-03-13-125234-update/20240220152634-yy4s6nv/20240220152630-qly715s.sy
c6: 1741841554
c4:
一键部署
思源	
docker run -d  -v /mnt/sata3-3/soft/images/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d -v /root/siyuan:/siyuan/workspace  -e PUID=$UID  -e PGID=$GID  -p 6806:6806 b3log/siyuan  --workspace=/siyuan/workspace/ --accessAuthCode=xxx
网心云
docker run -d --name=wxedge --restart=always --privileged --net=host  --tmpfs /run --tmpfs /tmp -v /home:/storage:rw  registry.hub.docker.com/onething1/wxedge
网迅雷
docker run -d --name=xunlei --hostname=mynas --net=host -v /mnt/sdb1/xunlei:/xunlei/data -v /mnt/sdb1/downloads:/xunlei/downloads --restart=unless-stopped --privileged cnk3x/xunlei:latest
webdav
docker run --name=webdav -d -e USERNAME=test -e PASSWORD=test -v /路径:/webdav -p 8920:80 idelsink/webdav
docker-compose部署
wordpress
version: "3.3"
  
services:
  db:
    image: mysql:8.0
    volumes:
      - ./db_data:/var/lib/mysql
    restart: always
    environment:
      MYSQL_ROOT_PASSWORD: wordpress
      MYSQL_DATABASE: wordpress
      MYSQL_USER: wordpress
      MYSQL_PASSWORD: wordpress
  
  wordpress:
    depends_on:
      - db
    image: wordpress:latest
    volumes:
      - ./wordpress_data:/var/www/html
    ports:
      - "10001:80"
    restart: always
    environment:
      WORDPRESS_DB_HOST: db
      WORDPRESS_DB_USER: wordpress
      WORDPRESS_DB_PASSWORD: wordpress
      WORDPRESS_DB_NAME: wordpress
volumes:
  db_data: {}
  wordpress_data: {}
joplin
version: '3'

services:
    db:
        image: postgres:latest
        restart: unless-stopped
        environment:
            - POSTGRES_PASSWORD=joplin
            - POSTGRES_USER=joplin
            - POSTGRES_DB=joplin
    app:
        image: joplin/server:latest
        depends_on:
            - db
        ports:
            - "22300:22300"
        restart: unless-stopped
        environment:
            - APP_PORT=22300
            - APP_BASE_URL=http://192.168.0.183:22300
            - DB_CLIENT=pg
            - POSTGRES_PASSWORD=joplin
            - POSTGRES_DATABASE=joplin
            - POSTGRES_USER=joplin
            - POSTGRES_PORT=5432
            - POSTGRES_HOST=db
数据备份 resilio部署
docker run -d   -e PUID=1000   -e PGID=1000   -e TZ=Etc/UTC   -p 8888:8888  -p 55555:55555   -v /root/siyuan1/config:/config  -v /root/siyuan1:/downloads  -v /root/siyuan1:/sync  --restart unless-stopped lscr.io/linuxserver/resilio-sync:latest
Docker安装Wireguard
docker run -d \
  --name=wg-easy \
  -e WG_HOST=123.123.123.123 (🚨这里输入服务器的公网IP) \
  -e PASSWORD=passwd123 (🚨这里输入你的密码) \
  -e WG_DEFAULT_ADDRESS=10.0.8.x （🚨默认IP地址）\
  -e WG_DEFAULT_DNS=114.114.114.114 （🚨默认DNS）\
  -e WG_ALLOWED_IPS=10.0.8.0/24 （🚨允许连接的IP段）\
  -e WG_PERSISTENT_KEEPALIVE=25 （🚨重连间隔）\
  -v ~/.wg-easy:/etc/wireguard \
  -p 51820:51820/udp \
  -p 51821:51821/tcp \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --sysctl="net.ipv4.ip_forward=1" \
  --restart unless-stopped \
  weejewel/wg-easy
客户端部署
docker run -d \
  --name=wg-client \
  -e WG_HOST=10.0.0.1 \
  -e PASSWORD= \
  -v /mnt/Adisk/wireguard/:/etc/wireguard/ \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  weejewel/wg-easy
samba部署
samba.tar
docker run -d --name=samba  -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=PXX"  -v "/home/example:/storage" dockurr/samba
docker run -d \
  --name=wg-easy \
  -e WG_HOST=39.174.229.143  \
  -e PASSWORD=888888  \
  -e WG_DEFAULT_ADDRESS=10.0.0.x \
  -e WG_DEFAULT_DNS=211.140.13.188 \
  -e WG_ALLOWED_IPS=10.0.0.0/24 \
  -e WG_PERSISTENT_KEEPALIVE=25 \
  -v ~/.wg-easy:/etc/wireguard \
  -p 80:51820/udp \
  -p 80:51821/tcp \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --sysctl="net.ipv4.ip_forward=1" \
  --restart unless-stopped \
  weejewel/wg-easy
docker run -d \
  --name=wg-easy \
  -e WG_HOST=192.168.50.237  \
  -e PASSWORD=  \
  -e WG_DEFAULT_ADDRESS=1.1.1.x \
  -e WG_DEFAULT_DNS=211.140.13.188 \
  -e WG_ALLOWED_IPS=1.1.1.0/24 \
  -e WG_PERSISTENT_KEEPALIVE=25 \
  -v /mnt/wg-easy:/etc/wireguard \
  -p 51820:51820/udp \
  -p 80:51821/tcp \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --sysctl="net.ipv4.ip_forward=1" \
  --restart unless-stopped \
  weejewel/wg-easy
network:
  version: 2
  renderer: networkd
  ethernets:
    eth0:
      dhcp4: false
      addresses:
        - 192.168.50.237/24  
      gateway4: 192.168.50.18  
      nameservers:
        addresses:
          - 8.8.8.8  
          - 8.8.4.4

qbittorrent部署
docker run -d \
  --name=qbittorrent \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 8080:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/sda2:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest
 需要看logs 密码
docker run -d -p 1000:9000 --name portainer --restart always -v /var/run/docker.sock:/var/run/docker.sock -v /opt/portainer:/data portainer/portainer-ce:latest


c0: 20250204202213-2virs7k
c2: update
c3: 复制修改版
c5: 2025-03-13-131234-update/20250204202137-3g13i3l/20250204202213-2virs7k.sy
c6: 1741842754
c4:
通过 iPhone 镜像从 Mac 使用 iPhone
魔兽争霸:https://www.123pan.com/s/nVxFjv-fkwd3.html
dd if=openwrt-24.10.0-x86-64-generic-ext4-combined-efi.img of=/dev/sdb bs=4M
docker dockerd luci-lib-docker docker-compose
docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
dd if=/dev/sda of=/root/openwrt24.img bs=4M status=progress

docker run -d  -v /mnt/sda1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d \
  --name=qbittorrent \
  -e PUID=1000 -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -e WEBUI_PORT=8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -p 80:8080 \
  -v /home/qbittorrent/:/downloads \
  --restart unless-stopped \
  linuxserver/qbittorrent

docker run -d \
  --name=qbittorrent \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 2000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/sda2:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

dd if=istoreo.img of=/dev/sda bs=4M
docker run -d --name=xunlei --hostname=mynas --net=host -v /mnt/usb1:/xunlei/data -v /mnt/usb1/downloads:/xunlei/downloads --restart=unless-stopped --privileged cnk3x/xunlei:latest
docker run -d --privileged  -v /mnt/sda2:/xunlei/downloads -p 2345:2345 cnk3x/xunlei
docker run -d -v /mnt/usb1/siyuan:/siyuan/workspace  -e PUID=$UID  -e PGID=$GID  -p 6806:6806 b3log/siyuan  --workspace=/siyuan/workspace/ --accessAuthCode=xxx
docker run -d --name=siyuan -v /mnt/usb1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d --name syncthing  --restart always -p 3000:8384 -p 22000:22000/tcp -p 22000:22000/udp  -p 21027:21027/udp -v /mnt/config-sync:/var/syncthing/config -v /mnt:/var/syncthing/data syncthing/syncthing
docker run -d \
  --name syncthing \
  --restart always \
  -p 8384:8384 \
  -p 22000:22000/tcp \
  -p 22000:22000/udp \
  -p 21027:21027/udp \
  -v /mnt/usb2/syncthing/config:/var/syncthing/config \
  -v /mnt/usb2/syncthing/:/var/syncthing/data \
  syncthing/syncthing
docker run -d --name=samba  --restart unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NNN"  -v "/mnt:/storage" dockurr/samba
opkg install fdisk block-mount unzip zerotier samba4-server samba4-utils luci-app-samba4 openssh-sftp-server openvpn-openssl luci-app-openvpn wireguard-tools kmod-wireguard luci-proto-wi
mkdir -p /tmp/introot
mkdir -p /tmp/extroot
mount --bind / /tmp/introot
mount /dev/sda3 /tmp/extroot
tar -C /tmp/introot -cvf - . | tar -C /tmp/extroot -xf -
umount /tmp/introot
umount /tmp/extroot
docker run -d --name=samba --restart=unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NBBN"  -v "/mnt/:/storage" dockurr/samba
network:
  version: 2
  renderer: networkd
  wifis:
    wlp2s0:
      dhcp4: no
      addresses:
        - 192.168.0.124/24  # 这里改成你想要的静态 IP
      gateway4: 192.168.0.8  # 你的网关 IP（通常是路由器 IP）
      nameservers:
        addresses:
          - 211.140.13.188   
          - 114.114.114.114  # 114 DNS
      access-points:
        "boci1":
          password: "a1b2c3d4"


docker run --restart always --name openwrt1 -d --network macnet --privileged --ip 192.168.0.124   openwrt /sbin/init
docker run -d \
  --name=clash \
  -v /root/clash.yaml: /root/.config/clash/config.yaml \
  -p 7890:7890 \
  -p 9090:9090 \
  --restart unless-stopped \
  dreamacro/clash

安装官方最新版本：
curl -fsSL https://get.docker.com | bash
docker import rootfs.tar.gz my-custom-image
docker run -d \
  --name openwrt \
  --network host \
  --privileged \
  openwrt
docker run --restart always --name openwrt -p 80:80 -d --network host --privileged openwrt /sbin/init
允许 ZeroTier 网络访问本地网络
sudo iptables -A FORWARD -s 192.168.192.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 192.168.0.0/24 -d 192.168.192.0/24 -j ACCEPT
如果局域网设备默认网关不是 Ubuntu，需要 NAT
sudo iptables -t nat -A POSTROUTING -s 192.168.192.0/24 -d 192.168.0.0/24 -j MASQUERADE
eroTier 网络
192.168.0.0/24 via 192.168.191.112
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
ip route add 192.168.50.0/24 via 10.8.0.1 dev tun0
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
4.新启动 OpenVPN 服务
systemctl restart openvpn
docker run -d \
  --name=wg-client2 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  -v /mnt/wg0:/etc/wireguard/wg0 \
  weejewel/wg-easy
docker run -d \
  --name=wg-wireguard \
  -e WG_HOST=10.0.0.1 \
  -e PASSWORD= \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  weejewel/wg-easy

network:
  ethernets:
    eth0:  # 请替换为你的实际网卡名称
      dhcp4: no
      addresses:
        - 192.168.0.219/24  # 设置静态 IP
      gateway4: 192.168.0.8  # 设置网关
      nameservers:
        addresses:
          - 211.140.13.188
  version: 2
ip route add 192.168.200.0/24 via 10.8.0.1 dev tun0
iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE
iptables -A FORWARD -i tun0 -o eth1 -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A FORWARD -i eth1 -o tun0 -j ACCEPT


docker run -d \
  --name=wireguard-client \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -v /mnt:/config \
  -v /lib/modules:/lib/modules \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  lscr.io/linuxserver/wireguard:latest

enp1s0    enx00e04c360351
network:
  version: 2
  renderer: networkd
  ethernets:
    eth0:
      dhcp4: yes
      dhcp6: no
    enx00e04c360351:
      addresses:
        - 10.131.61.111/24
      dhcp4: no
sudo iptables -t nat -A POSTROUTING -o enp1s0 -j MASQUERADE
sudo iptables -A FORWARD -i enx00e04c360351 -o enp1s0 -j ACCEPT
sudo iptables -A FORWARD -i enp1s0 -o enx00e04c360351 -m state --state RELATED,ESTABLISHED -j ACCEPT
ip route add 22.8.144.97 via 10.130.61.1 dev enx00e04c360351
ip route add 22.8.144.97 via 10.131.61.1 dev br-lan  
ip route add 22.8.144.97 via 10.0.0.5 dev wireguard 
22.8.144.97
ip route add 22.8.144.97 via 192.168.0.8 dev eth0
39.174.229.143
10.0.0.0/24
uci show firewall | grep '@redirect'
docker run -d \
  --name=transmission \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -p 80:9091 \
  -p 51413:51413 \
  -p 51413:51413/udp \
  -v /home/download:/downloads \
  --restart unless-stopped \
  lscr.io/linuxserver/transmission:latest

docker run --restart always --name openwrt -d --network macnet --privileged --ip 10.1.25.193 ophub/openwrt-aarch64:latest
uci set zerotier.global.enabled='1'
uci delete zerotier.earth
uci set zerotier.openwrt_network=network
uci set zerotier.openwrt_network.id='856127940c66f22d'
uci commit zerotier
ip link set  eth0 promisc on
docker network create -d macvlan --subnet=192.168.50.0/24 --gateway=192.168.50.1 -o parent=br-lan  mynet
docker run  --name openwrt --restart unless-stopped -d --network mynet    --privileged --ip 192.168.50.314  openwrt  /sbin/init


c0: 20250204202213-2virs7k
c2: update
c3: 复制修改版
c5: 2025-03-13-133234-update/20250204202137-3g13i3l/20250204202213-2virs7k.sy
c6: 1741843954
c4:
通过 iPhone 镜像从 Mac 使用 iPhone
魔兽争霸:https://www.123pan.com/s/nVxFjv-fkwd3.html
dd if=openwrt-24.10.0-x86-64-generic-ext4-combined-efi.img of=/dev/sdb bs=4M
docker dockerd luci-lib-docker docker-compose
docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
dd if=/dev/sda of=/root/openwrt24.img bs=4M status=progress

docker run -d  -v /mnt/sda1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d \
  --name=qbittorrent \
  -e PUID=1000 -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -e WEBUI_PORT=8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -p 80:8080 \
  -v /home/qbittorrent/:/downloads \
  --restart unless-stopped \
  linuxserver/qbittorrent

docker run -d \
  --name=qbittorrent \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 2000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/sda2:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

dd if=istoreo.img of=/dev/sda bs=4M
docker run -d --name=xunlei --hostname=mynas --net=host -v /mnt/usb1:/xunlei/data -v /mnt/usb1/downloads:/xunlei/downloads --restart=unless-stopped --privileged cnk3x/xunlei:latest
docker run -d --privileged  -v /mnt/sda2:/xunlei/downloads -p 2345:2345 cnk3x/xunlei
docker run -d -v /mnt/usb1/siyuan:/siyuan/workspace  -e PUID=$UID  -e PGID=$GID  -p 6806:6806 b3log/siyuan  --workspace=/siyuan/workspace/ --accessAuthCode=xxx
docker run -d --name=siyuan -v /mnt/usb1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d --name syncthing  --restart always -p 3000:8384 -p 22000:22000/tcp -p 22000:22000/udp  -p 21027:21027/udp -v /mnt/config-sync:/var/syncthing/config -v /mnt:/var/syncthing/data syncthing/syncthing
docker run -d \
  --name syncthing \
  --restart always \
  -p 8384:8384 \
  -p 22000:22000/tcp \
  -p 22000:22000/udp \
  -p 21027:21027/udp \
  -v /mnt/usb2/syncthing/config:/var/syncthing/config \
  -v /mnt/usb2/syncthing/:/var/syncthing/data \
  syncthing/syncthing
docker run -d --name=samba  --restart unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NNN"  -v "/mnt:/storage" dockurr/samba
opkg install fdisk block-mount unzip zerotier samba4-server samba4-utils luci-app-samba4 openssh-sftp-server openvpn-openssl luci-app-openvpn wireguard-tools kmod-wireguard luci-proto-wi
mkdir -p /tmp/introot
mkdir -p /tmp/extroot
mount --bind / /tmp/introot
mount /dev/sda3 /tmp/extroot
tar -C /tmp/introot -cvf - . | tar -C /tmp/extroot -xf -
umount /tmp/introot
umount /tmp/extroot
docker run -d --name=samba --restart=unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NBBN"  -v "/mnt/:/storage" dockurr/samba
network:
  version: 2
  renderer: networkd
  wifis:
    wlp2s0:
      dhcp4: no
      addresses:
        - 192.168.0.124/24  # 这里改成你想要的静态 IP
      gateway4: 192.168.0.8  # 你的网关 IP（通常是路由器 IP）
      nameservers:
        addresses:
          - 211.140.13.188   
          - 114.114.114.114  # 114 DNS
      access-points:
        "boci1":
          password: "a1b2c3d4"


docker run --restart always --name openwrt1 -d --network macnet --privileged --ip 192.168.0.124   openwrt /sbin/init
docker run -d \
  --name=clash \
  -v /root/clash.yaml: /root/.config/clash/config.yaml \
  -p 7890:7890 \
  -p 9090:9090 \
  --restart unless-stopped \
  dreamacro/clash

安装官方最新版本：
curl -fsSL https://get.docker.com | bash
docker import rootfs.tar.gz my-custom-image
docker run -d \
  --name openwrt \
  --network host \
  --privileged \
  openwrt
docker run --restart always --name openwrt -p 80:80 -d --network host --privileged openwrt /sbin/init
允许 ZeroTier 网络访问本地网络
sudo iptables -A FORWARD -s 192.168.192.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 192.168.0.0/24 -d 192.168.192.0/24 -j ACCEPT
如果局域网设备默认网关不是 Ubuntu，需要 NAT
sudo iptables -t nat -A POSTROUTING -s 192.168.192.0/24 -d 192.168.0.0/24 -j MASQUERADE
eroTier 网络
192.168.0.0/24 via 192.168.191.112
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
ip route add 192.168.50.0/24 via 10.8.0.1 dev tun0
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
4.新启动 OpenVPN 服务
systemctl restart openvpn
docker run -d \
  --name=wg-client2 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  -v /mnt/wg0:/etc/wireguard/wg0 \
  weejewel/wg-easy
docker run -d \
  --name=wg-wireguard \
  -e WG_HOST=10.0.0.1 \
  -e PASSWORD= \
  --network host \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  weejewel/wg-easy

network:
  ethernets:
    eth0:  # 请替换为你的实际网卡名称
      dhcp4: no
      addresses:
        - 192.168.0.219/24  # 设置静态 IP
      gateway4: 192.168.0.8  # 设置网关
      nameservers:
        addresses:
          - 211.140.13.188
  version: 2
ip route add 192.168.200.0/24 via 10.8.0.1 dev tun0
iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE
iptables -A FORWARD -i tun0 -o eth1 -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A FORWARD -i eth1 -o tun0 -j ACCEPT


docker run -d \
  --name=wireguard-client \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -v /mnt:/config \
  -v /lib/modules:/lib/modules \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  lscr.io/linuxserver/wireguard:latest

enp1s0    enx00e04c360351
network:
  version: 2
  renderer: networkd
  ethernets:
    eth0:
      dhcp4: yes
      dhcp6: no
    enx00e04c360351:
      addresses:
        - 10.131.61.111/24
      dhcp4: no
sudo iptables -t nat -A POSTROUTING -o enp1s0 -j MASQUERADE
sudo iptables -A FORWARD -i enx00e04c360351 -o enp1s0 -j ACCEPT
sudo iptables -A FORWARD -i enp1s0 -o enx00e04c360351 -m state --state RELATED,ESTABLISHED -j ACCEPT
ip route add 22.8.144.97 via 10.130.61.1 dev enx00e04c360351
ip route add 22.8.144.97 via 10.131.61.1 dev br-lan  
ip route add 22.8.144.97 via 10.0.0.5 dev wireguard 
22.8.144.97
ip route add 22.8.144.97 via 192.168.0.8 dev eth0
39.174.229.143
10.0.0.0/24
uci show firewall | grep '@redirect'
docker run -d \
  --name=transmission \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -p 80:9091 \
  -p 51413:51413 \
  -p 51413:51413/udp \
  -v /home/download:/downloads \
  --restart unless-stopped \
  lscr.io/linuxserver/transmission:latest

docker run --restart always --name openwrt -d --network macnet --privileged --ip 10.1.25.193 ophub/openwrt-aarch64:latest
uci set zerotier.global.enabled='1'
uci delete zerotier.earth
uci set zerotier.openwrt_network=network
uci set zerotier.openwrt_network.id='856127940c66f22d'
uci commit zerotier
ip link set  eth0 promisc on
docker network create -d macvlan --subnet=192.168.50.0/24 --gateway=192.168.50.1 -o parent=br-lan  mynet
docker run  --name openwrt --restart unless-stopped -d --network mynet    --privileged --ip 192.168.50.314  openwrt  /sbin/init


c0: 20250204202213-2virs7k
c2: update
c3: 复制修改版
c5: 2025-03-13-135234-update/20250204202137-3g13i3l/20250204202213-2virs7k.sy
c6: 1741845154
c4:
通过 iPhone 镜像从 Mac 使用 iPhone
魔兽争霸:https://www.123pan.com/s/nVxFjv-fkwd3.html
dd if=openwrt-24.10.0-x86-64-generic-ext4-combined-efi.img of=/dev/sdb bs=4M
docker dockerd luci-lib-docker docker-compose
docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
dd if=/dev/sda of=/root/openwrt24.img bs=4M status=progress

docker run -d  -v /mnt/sda1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d \
  --name=qbittorrent \
  -e PUID=1000 -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -e WEBUI_PORT=8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -p 80:8080 \
  -v /home/qbittorrent/:/downloads \
  --restart unless-stopped \
  linuxserver/qbittorrent

docker run -d \
  --name=qbittorrent \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 2000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/sda2:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

dd if=istoreo.img of=/dev/sda bs=4M
docker run -d --name=xunlei --hostname=mynas --net=host -v /mnt/usb1:/xunlei/data -v /mnt/usb1/downloads:/xunlei/downloads --restart=unless-stopped --privileged cnk3x/xunlei:latest
docker run -d --privileged  -v /mnt/sda2:/xunlei/downloads -p 2345:2345 cnk3x/xunlei
docker run -d -v /mnt/usb1/siyuan:/siyuan/workspace  -e PUID=$UID  -e PGID=$GID  -p 6806:6806 b3log/siyuan  --workspace=/siyuan/workspace/ --accessAuthCode=xxx
docker run -d --name=siyuan -v /mnt/usb1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d --name syncthing  --restart always -p 3000:8384 -p 22000:22000/tcp -p 22000:22000/udp  -p 21027:21027/udp -v /mnt/config-sync:/var/syncthing/config -v /mnt:/var/syncthing/data syncthing/syncthing
docker run -d \
  --name syncthing \
  --restart always \
  -p 8384:8384 \
  -p 22000:22000/tcp \
  -p 22000:22000/udp \
  -p 21027:21027/udp \
  -v /mnt/usb2/syncthing/config:/var/syncthing/config \
  -v /mnt/usb2/syncthing/:/var/syncthing/data \
  syncthing/syncthing
docker run -d --name=samba  --restart unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NNN"  -v "/mnt:/storage" dockurr/samba
opkg install fdisk block-mount unzip zerotier samba4-server samba4-utils luci-app-samba4 openssh-sftp-server openvpn-openssl luci-app-openvpn wireguard-tools kmod-wireguard luci-proto-wi
mkdir -p /tmp/introot
mkdir -p /tmp/extroot
mount --bind / /tmp/introot
mount /dev/sda3 /tmp/extroot
tar -C /tmp/introot -cvf - . | tar -C /tmp/extroot -xf -
umount /tmp/introot
umount /tmp/extroot
docker run -d --name=samba --restart=unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NBBN"  -v "/mnt/:/storage" dockurr/samba
network:
  version: 2
  renderer: networkd
  wifis:
    wlp2s0:
      dhcp4: no
      addresses:
        - 192.168.0.124/24  # 这里改成你想要的静态 IP
      gateway4: 192.168.0.8  # 你的网关 IP（通常是路由器 IP）
      nameservers:
        addresses:
          - 211.140.13.188   
          - 114.114.114.114  # 114 DNS
      access-points:
        "boci1":
          password: "a1b2c3d4"


docker run --restart always --name openwrt1 -d --network macnet --privileged --ip 192.168.0.124   openwrt /sbin/init
docker run -d \
  --name=clash \
  -v /root/clash.yaml: /root/.config/clash/config.yaml \
  -p 7890:7890 \
  -p 9090:9090 \
  --restart unless-stopped \
  dreamacro/clash

安装官方最新版本：
curl -fsSL https://get.docker.com | bash
docker import rootfs.tar.gz my-custom-image
docker run -d \
  --name openwrt \
  --network host \
  --privileged \
  openwrt
docker run --restart always --name openwrt -p 80:80 -d --network host --privileged openwrt /sbin/init
允许 ZeroTier 网络访问本地网络
sudo iptables -A FORWARD -s 192.168.192.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 192.168.0.0/24 -d 192.168.192.0/24 -j ACCEPT
如果局域网设备默认网关不是 Ubuntu，需要 NAT
sudo iptables -t nat -A POSTROUTING -s 192.168.192.0/24 -d 192.168.0.0/24 -j MASQUERADE
eroTier 网络
192.168.0.0/24 via 192.168.191.112
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
ip route add 192.168.50.0/24 via 10.8.0.1 dev tun0
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
4.新启动 OpenVPN 服务
systemctl restart openvpn
docker run -d \
  --name=wg-client2 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  -v /mnt/wg0:/etc/wireguard/wg0 \
  weejewel/wg-easy
docker run -d \
  --name=wg-wireguard \
  -e WG_HOST=10.0.0.1 \
  -e PASSWORD= \
  --network host \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy

network:
  ethernets:
    eth0:  # 请替换为你的实际网卡名称
      dhcp4: no
      addresses:
        - 192.168.0.219/24  # 设置静态 IP
      gateway4: 192.168.0.8  # 设置网关
      nameservers:
        addresses:
          - 211.140.13.188
  version: 2
ip route add 192.168.200.0/24 via 10.8.0.1 dev tun0
iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE
iptables -A FORWARD -i tun0 -o eth1 -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A FORWARD -i eth1 -o tun0 -j ACCEPT


docker run -d \
  --name=wireguard-client \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -v /mnt:/config \
  -v /lib/modules:/lib/modules \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  lscr.io/linuxserver/wireguard:latest

enp1s0    enx00e04c360351
network:
  version: 2
  renderer: networkd
  ethernets:
    eth0:
      dhcp4: yes
      dhcp6: no
    enx00e04c360351:
      addresses:
        - 10.131.61.111/24
      dhcp4: no
sudo iptables -t nat -A POSTROUTING -o enp1s0 -j MASQUERADE
sudo iptables -A FORWARD -i enx00e04c360351 -o enp1s0 -j ACCEPT
sudo iptables -A FORWARD -i enp1s0 -o enx00e04c360351 -m state --state RELATED,ESTABLISHED -j ACCEPT
ip route add 22.8.144.97 via 10.130.61.1 dev enx00e04c360351
ip route add 22.8.144.97 via 10.131.61.1 dev br-lan  
ip route add 22.8.144.97 via 10.0.0.5 dev wireguard 
22.8.144.97
ip route add 22.8.144.97 via 192.168.0.8 dev eth0
39.174.229.143
10.0.0.0/24
uci show firewall | grep '@redirect'
docker run -d \
  --name=transmission \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -p 80:9091 \
  -p 51413:51413 \
  -p 51413:51413/udp \
  -v /home/download:/downloads \
  --restart unless-stopped \
  lscr.io/linuxserver/transmission:latest

docker run --restart always --name openwrt -d --network macnet --privileged --ip 10.1.25.193 ophub/openwrt-aarch64:latest
uci set zerotier.global.enabled='1'
uci delete zerotier.earth
uci set zerotier.openwrt_network=network
uci set zerotier.openwrt_network.id='856127940c66f22d'
uci commit zerotier
ip link set  eth0 promisc on
docker network create -d macvlan --subnet=192.168.50.0/24 --gateway=192.168.50.1 -o parent=br-lan  mynet
docker run  --name openwrt --restart unless-stopped -d --network mynet    --privileged --ip 192.168.50.314  openwrt  /sbin/init


c0: 20250204202213-2virs7k
c2: update
c3: 复制修改版
c5: 2025-03-13-140234-update/20250204202137-3g13i3l/20250204202213-2virs7k.sy
c6: 1741845754
c4:
通过 iPhone 镜像从 Mac 使用 iPhone
魔兽争霸:https://www.123pan.com/s/nVxFjv-fkwd3.html
dd if=openwrt-24.10.0-x86-64-generic-ext4-combined-efi.img of=/dev/sdb bs=4M
docker dockerd luci-lib-docker docker-compose
docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
dd if=/dev/sda of=/root/openwrt24.img bs=4M status=progress

docker run -d  -v /mnt/sda1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d \
  --name=qbittorrent \
  -e PUID=1000 -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -e WEBUI_PORT=8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -p 80:8080 \
  -v /home/qbittorrent/:/downloads \
  --restart unless-stopped \
  linuxserver/qbittorrent

docker run -d \
  --name=qbittorrent \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 2000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/sda2:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

dd if=istoreo.img of=/dev/sda bs=4M
docker run -d --name=xunlei --hostname=mynas --net=host -v /mnt/usb1:/xunlei/data -v /mnt/usb1/downloads:/xunlei/downloads --restart=unless-stopped --privileged cnk3x/xunlei:latest
docker run -d --privileged  -v /mnt/sda2:/xunlei/downloads -p 2345:2345 cnk3x/xunlei
docker run -d -v /mnt/usb1/siyuan:/siyuan/workspace  -e PUID=$UID  -e PGID=$GID  -p 6806:6806 b3log/siyuan  --workspace=/siyuan/workspace/ --accessAuthCode=xxx
docker run -d --name=siyuan -v /mnt/usb1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d --name syncthing  --restart always -p 3000:8384 -p 22000:22000/tcp -p 22000:22000/udp  -p 21027:21027/udp -v /mnt/config-sync:/var/syncthing/config -v /mnt:/var/syncthing/data syncthing/syncthing
docker run -d \
  --name syncthing \
  --restart always \
  -p 8384:8384 \
  -p 22000:22000/tcp \
  -p 22000:22000/udp \
  -p 21027:21027/udp \
  -v /mnt/usb2/syncthing/config:/var/syncthing/config \
  -v /mnt/usb2/syncthing/:/var/syncthing/data \
  syncthing/syncthing
docker run -d --name=samba  --restart unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NNN"  -v "/mnt:/storage" dockurr/samba
opkg install fdisk block-mount unzip zerotier samba4-server samba4-utils luci-app-samba4 openssh-sftp-server openvpn-openssl luci-app-openvpn wireguard-tools kmod-wireguard luci-proto-wi
mkdir -p /tmp/introot
mkdir -p /tmp/extroot
mount --bind / /tmp/introot
mount /dev/sda3 /tmp/extroot
tar -C /tmp/introot -cvf - . | tar -C /tmp/extroot -xf -
umount /tmp/introot
umount /tmp/extroot
docker run -d --name=samba --restart=unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NBBN"  -v "/mnt/:/storage" dockurr/samba
network:
  version: 2
  renderer: networkd
  wifis:
    wlp2s0:
      dhcp4: no
      addresses:
        - 192.168.0.124/24  # 这里改成你想要的静态 IP
      gateway4: 192.168.0.8  # 你的网关 IP（通常是路由器 IP）
      nameservers:
        addresses:
          - 211.140.13.188   
          - 114.114.114.114  # 114 DNS
      access-points:
        "boci1":
          password: "a1b2c3d4"


docker run --restart always --name openwrt1 -d --network macnet --privileged --ip 192.168.0.124   openwrt /sbin/init
docker run -d \
  --name=clash \
  -v /root/clash.yaml: /root/.config/clash/config.yaml \
  -p 7890:7890 \
  -p 9090:9090 \
  --restart unless-stopped \
  dreamacro/clash

安装官方最新版本：
curl -fsSL https://get.docker.com | bash
docker import rootfs.tar.gz my-custom-image
docker run -d \
  --name openwrt \
  --network host \
  --privileged \
  openwrt
docker run --restart always --name openwrt -p 80:80 -d --network host --privileged openwrt /sbin/init
允许 ZeroTier 网络访问本地网络
sudo iptables -A FORWARD -s 192.168.192.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 192.168.0.0/24 -d 192.168.192.0/24 -j ACCEPT
如果局域网设备默认网关不是 Ubuntu，需要 NAT
sudo iptables -t nat -A POSTROUTING -s 192.168.192.0/24 -d 192.168.0.0/24 -j MASQUERADE
eroTier 网络
192.168.0.0/24 via 192.168.191.112
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
ip route add 192.168.50.0/24 via 10.8.0.1 dev tun0
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
4.新启动 OpenVPN 服务
systemctl restart openvpn
docker run -d \
  --name=wg-client2 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  -v /mnt/wg0:/etc/wireguard/wg0 \
  weejewel/wg-easy
docker run -d \
  --name=wg-wireguard \
  -e WG_HOST=10.0.0.1 \
  -e PASSWORD= \
  --network host \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
docker run -d \
  --name=wg-easy3 \
  --network host \
  --privileged \
  -e WG_HOST=39.174.229.143 \
  -e PASSWORD= \
  -e WG_PERSISTENT_KEEPALIVE=25 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
network:
  ethernets:
    eth0:  # 请替换为你的实际网卡名称
      dhcp4: no
      addresses:
        - 192.168.0.219/24  # 设置静态 IP
      gateway4: 192.168.0.8  # 设置网关
      nameservers:
        addresses:
          - 211.140.13.188
  version: 2
ip route add 192.168.200.0/24 via 10.8.0.1 dev tun0
iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE
iptables -A FORWARD -i tun0 -o eth1 -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A FORWARD -i eth1 -o tun0 -j ACCEPT


docker run -d \
  --name=wireguard-client \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -v /mnt:/config \
  -v /lib/modules:/lib/modules \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  lscr.io/linuxserver/wireguard:latest

enp1s0    enx00e04c360351
network:
  version: 2
  renderer: networkd
  ethernets:
    eth0:
      dhcp4: yes
      dhcp6: no
    enx00e04c360351:
      addresses:
        - 10.131.61.111/24
      dhcp4: no
sudo iptables -t nat -A POSTROUTING -o enp1s0 -j MASQUERADE
sudo iptables -A FORWARD -i enx00e04c360351 -o enp1s0 -j ACCEPT
sudo iptables -A FORWARD -i enp1s0 -o enx00e04c360351 -m state --state RELATED,ESTABLISHED -j ACCEPT
ip route add 22.8.144.97 via 10.130.61.1 dev enx00e04c360351
ip route add 22.8.144.97 via 10.131.61.1 dev br-lan  
ip route add 22.8.144.97 via 10.0.0.5 dev wireguard 
22.8.144.97
ip route add 22.8.144.97 via 192.168.0.8 dev eth0
39.174.229.143
10.0.0.0/24
uci show firewall | grep '@redirect'
docker run -d \
  --name=transmission \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -p 80:9091 \
  -p 51413:51413 \
  -p 51413:51413/udp \
  -v /home/download:/downloads \
  --restart unless-stopped \
  lscr.io/linuxserver/transmission:latest

docker run --restart always --name openwrt -d --network macnet --privileged --ip 10.1.25.193 ophub/openwrt-aarch64:latest
uci set zerotier.global.enabled='1'
uci delete zerotier.earth
uci set zerotier.openwrt_network=network
uci set zerotier.openwrt_network.id='856127940c66f22d'
uci commit zerotier
ip link set  eth0 promisc on
docker network create -d macvlan --subnet=192.168.50.0/24 --gateway=192.168.50.1 -o parent=br-lan  mynet
docker run  --name openwrt --restart unless-stopped -d --network mynet    --privileged --ip 192.168.50.314  openwrt  /sbin/init


c0: 20250204202213-2virs7k
c2: update
c3: 复制修改版
c5: 2025-03-13-152234-update/20250204202137-3g13i3l/20250204202213-2virs7k.sy
c6: 1741850554
c4:
通过 iPhone 镜像从 Mac 使用 iPhone
魔兽争霸:https://www.123pan.com/s/nVxFjv-fkwd3.html
dd if=openwrt-24.10.0-x86-64-generic-ext4-combined-efi.img of=/dev/sdb bs=4M
docker dockerd luci-lib-docker docker-compose
docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
dd if=/dev/sda of=/root/openwrt24.img bs=4M status=progress

docker run -d  -v /mnt/sda1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d \
  --name=qbittorrent \
  -e PUID=1000 -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -e WEBUI_PORT=8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -p 80:8080 \
  -v /home/qbittorrent/:/downloads \
  --restart unless-stopped \
  linuxserver/qbittorrent

docker run -d \
  --name=qbittorrent \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 2000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/sda2:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

dd if=istoreo.img of=/dev/sda bs=4M
docker run -d --name=xunlei --hostname=mynas --net=host -v /mnt/usb1:/xunlei/data -v /mnt/usb1/downloads:/xunlei/downloads --restart=unless-stopped --privileged cnk3x/xunlei:latest
docker run -d --privileged  -v /mnt/sda2:/xunlei/downloads -p 2345:2345 cnk3x/xunlei
docker run -d -v /mnt/usb1/siyuan:/siyuan/workspace  -e PUID=$UID  -e PGID=$GID  -p 6806:6806 b3log/siyuan  --workspace=/siyuan/workspace/ --accessAuthCode=xxx
docker run -d --name=siyuan -v /mnt/usb1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d --name syncthing  --restart always -p 3000:8384 -p 22000:22000/tcp -p 22000:22000/udp  -p 21027:21027/udp -v /mnt/config-sync:/var/syncthing/config -v /mnt:/var/syncthing/data syncthing/syncthing
docker run -d \
  --name syncthing \
  --restart always \
  -p 8384:8384 \
  -p 22000:22000/tcp \
  -p 22000:22000/udp \
  -p 21027:21027/udp \
  -v /mnt/usb2/syncthing/config:/var/syncthing/config \
  -v /mnt/usb2/syncthing/:/var/syncthing/data \
  syncthing/syncthing
docker run -d --name=samba  --restart unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NNN"  -v "/mnt:/storage" dockurr/samba
opkg install fdisk block-mount unzip zerotier samba4-server samba4-utils luci-app-samba4 openssh-sftp-server openvpn-openssl luci-app-openvpn wireguard-tools kmod-wireguard luci-proto-wi
mkdir -p /tmp/introot
mkdir -p /tmp/extroot
mount --bind / /tmp/introot
mount /dev/sda3 /tmp/extroot
tar -C /tmp/introot -cvf - . | tar -C /tmp/extroot -xf -
umount /tmp/introot
umount /tmp/extroot
docker run -d --name=samba --restart=unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NBBN"  -v "/mnt/:/storage" dockurr/samba
network:
  version: 2
  renderer: networkd
  wifis:
    wlp2s0:
      dhcp4: no
      addresses:
        - 192.168.0.124/24  # 这里改成你想要的静态 IP
      gateway4: 192.168.0.8  # 你的网关 IP（通常是路由器 IP）
      nameservers:
        addresses:
          - 211.140.13.188   
          - 114.114.114.114  # 114 DNS
      access-points:
        "boci1":
          password: "a1b2c3d4"


docker run --restart always --name openwrt1 -d --network macnet --privileged --ip 192.168.0.124   openwrt /sbin/init
docker run -d \
  --name=clash \
  -v /root/clash.yaml: /root/.config/clash/config.yaml \
  -p 7890:7890 \
  -p 9090:9090 \
  --restart unless-stopped \
  dreamacro/clash

安装官方最新版本：
curl -fsSL https://get.docker.com | bash
docker import rootfs.tar.gz my-custom-image
docker run -d \
  --name openwrt \
  --network host \
  --privileged \
  openwrt
docker run --restart always --name openwrt -p 80:80 -d --network host --privileged openwrt /sbin/init
允许 ZeroTier 网络访问本地网络
sudo iptables -A FORWARD -s 192.168.192.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 192.168.0.0/24 -d 192.168.192.0/24 -j ACCEPT
如果局域网设备默认网关不是 Ubuntu，需要 NAT
sudo iptables -t nat -A POSTROUTING -s 192.168.192.0/24 -d 192.168.0.0/24 -j MASQUERADE
eroTier 网络
192.168.0.0/24 via 192.168.191.112
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
ip route add 192.168.50.0/24 via 10.8.0.1 dev tun0
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
4.新启动 OpenVPN 服务
systemctl restart openvpn
docker run -d \
  --name=wg-client2 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  -v /mnt/wg0:/etc/wireguard/wg0 \
  weejewel/wg-easy
docker run -d \
  --name=wg-wireguard \
  -e WG_HOST=10.0.0.1 \
  -e PASSWORD= \
  --network host \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
docker run -d \
  --name=wg-easy3 \
  --network host \
  --privileged \
  -e WG_HOST=39.174.229.143 \
  -e PASSWORD= \
  -e WG_PERSISTENT_KEEPALIVE=25 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
network:
  ethernets:
    eth0:  # 请替换为你的实际网卡名称
      dhcp4: no
      addresses:
        - 192.168.0.219/24  # 设置静态 IP
      gateway4: 192.168.0.8  # 设置网关
      nameservers:
        addresses:
          - 211.140.13.188
  version: 2
ip route add 192.168.200.0/24 via 10.8.0.1 dev tun0
iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE
iptables -A FORWARD -i tun0 -o eth1 -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A FORWARD -i eth1 -o tun0 -j ACCEPT


docker run -d \
  --name=wireguard-client \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -v /mnt:/config \
  -v /lib/modules:/lib/modules \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  lscr.io/linuxserver/wireguard:latest

enp1s0    enx00e04c360351
network:
  version: 2
  renderer: networkd
  ethernets:
    eth0:
      dhcp4: yes
      dhcp6: no
    enx00e04c360351:
      addresses:
        - 10.131.61.111/24
      dhcp4: no
sudo iptables -t nat -A POSTROUTING -o enp1s0 -j MASQUERADE
sudo iptables -A FORWARD -i enx00e04c360351 -o enp1s0 -j ACCEPT
sudo iptables -A FORWARD -i enp1s0 -o enx00e04c360351 -m state --state RELATED,ESTABLISHED -j ACCEPT
ip route add 22.8.144.97 via 10.130.61.1 dev enx00e04c360351
ip route add 22.8.144.97 via 10.131.61.1 dev br-lan  
ip route add 22.8.144.97 via 10.0.0.5 dev wireguard 
22.8.144.97
ip route add 22.8.144.97 via 192.168.0.8 dev eth0
39.174.229.143
10.0.0.0/24
uci show firewall | grep '@redirect'
docker run -d \
  --name=transmission \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -p 80:9091 \
  -p 51413:51413 \
  -p 51413:51413/udp \
  -v /home/download:/downloads \
  --restart unless-stopped \
  lscr.io/linuxserver/transmission:latest

docker run --restart always --name openwrt -d --network macnet --privileged --ip 10.1.25.193 ophub/openwrt-aarch64:latest
uci set zerotier.global.enabled='1'
uci delete zerotier.earth
uci set zerotier.openwrt_network=network
uci set zerotier.openwrt_network.id='856127940c66f22d'
uci commit zerotier
ip link set  eth0 promisc on
docker network create -d macvlan --subnet=192.168.50.0/24 --gateway=192.168.50.1 -o parent=br-lan  mynet
docker run  --name openwrt --restart unless-stopped -d --network mynet    --privileged --ip 192.168.50.314  openwrt  /sbin/init
docker run -d \
  --name=resilio-sync \
  -p 8888:8888 \
  -p 55555:55555 \
  -v /mnt/sda1/resilio:/mnt/sync \
  -v /mnt/sda1/resilio-config:/config \
  --restart unless-stopped \
  resilio/sync


c0: 20250204202213-2virs7k
c2: update
c3: 复制修改版
c5: 2025-03-13-171234-update/20250204202137-3g13i3l/20250204202213-2virs7k.sy
c6: 1741857154
c4:
通过 iPhone 镜像从 Mac 使用 iPhone
魔兽争霸:https://www.123pan.com/s/nVxFjv-fkwd3.html
dd if=openwrt-24.10.0-x86-64-generic-ext4-combined-efi.img of=/dev/sdb bs=4M
docker dockerd luci-lib-docker docker-compose
docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
dd if=/dev/sda of=/root/openwrt24.img bs=4M status=progress

docker run -d  -v /mnt/sda1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d \
  --name=qbittorrent \
  -e PUID=1000 -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -e WEBUI_PORT=8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -p 80:8080 \
  -v /home/qbittorrent/:/downloads \
  --restart unless-stopped \
  linuxserver/qbittorrent

docker run -d \
  --name=qbittorrent \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 2000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/sda2:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

dd if=istoreo.img of=/dev/sda bs=4M
docker run -d --name=xunlei --hostname=mynas --net=host -v /mnt/usb1:/xunlei/data -v /mnt/usb1/downloads:/xunlei/downloads --restart=unless-stopped --privileged cnk3x/xunlei:latest
docker run -d --privileged  -v /mnt/sda2:/xunlei/downloads -p 2345:2345 cnk3x/xunlei
docker run -d -v /mnt/usb1/siyuan:/siyuan/workspace  -e PUID=$UID  -e PGID=$GID  -p 6806:6806 b3log/siyuan  --workspace=/siyuan/workspace/ --accessAuthCode=xxx
docker run -d --name=siyuan -v /mnt/usb1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d --name syncthing  --restart always -p 3000:8384 -p 22000:22000/tcp -p 22000:22000/udp  -p 21027:21027/udp -v /mnt/config-sync:/var/syncthing/config -v /mnt:/var/syncthing/data syncthing/syncthing
docker run -d \
  --name syncthing \
  --restart always \
  -p 8384:8384 \
  -p 22000:22000/tcp \
  -p 22000:22000/udp \
  -p 21027:21027/udp \
  -v /mnt/usb2/syncthing/config:/var/syncthing/config \
  -v /mnt/usb2/syncthing/:/var/syncthing/data \
  syncthing/syncthing
docker run -d --name=samba  --restart unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NNN"  -v "/mnt:/storage" dockurr/samba
opkg install fdisk block-mount unzip zerotier samba4-server samba4-utils luci-app-samba4 openssh-sftp-server openvpn-openssl luci-app-openvpn wireguard-tools kmod-wireguard luci-proto-wi
mkdir -p /tmp/introot
mkdir -p /tmp/extroot
mount --bind / /tmp/introot
mount /dev/sda3 /tmp/extroot
tar -C /tmp/introot -cvf - . | tar -C /tmp/extroot -xf -
umount /tmp/introot
umount /tmp/extroot
docker run -d --name=samba --restart=unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NBBN"  -v "/mnt/:/storage" dockurr/samba
network:
  version: 2
  renderer: networkd
  wifis:
    wlp2s0:
      dhcp4: no
      addresses:
        - 192.168.0.124/24  # 这里改成你想要的静态 IP
      gateway4: 192.168.0.8  # 你的网关 IP（通常是路由器 IP）
      nameservers:
        addresses:
          - 211.140.13.188   
          - 114.114.114.114  # 114 DNS
      access-points:
        "boci1":
          password: "a1b2c3d4"


docker run --restart always --name openwrt1 -d --network macnet --privileged --ip 192.168.0.124   openwrt /sbin/init
docker run -d \
  --name=clash \
  -v /root/clash.yaml: /root/.config/clash/config.yaml \
  -p 7890:7890 \
  -p 9090:9090 \
  --restart unless-stopped \
  dreamacro/clash

安装官方最新版本：
curl -fsSL https://get.docker.com | bash
docker import rootfs.tar.gz my-custom-image
docker run -d \
  --name openwrt \
  --network host \
  --privileged \
  openwrt
docker run --restart always --name openwrt -p 80:80 -d --network host --privileged openwrt /sbin/init
允许 ZeroTier 网络访问本地网络
sudo iptables -A FORWARD -s 192.168.192.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 192.168.0.0/24 -d 192.168.192.0/24 -j ACCEPT
如果局域网设备默认网关不是 Ubuntu，需要 NAT
sudo iptables -t nat -A POSTROUTING -s 192.168.192.0/24 -d 192.168.0.0/24 -j MASQUERADE
eroTier 网络
192.168.0.0/24 via 192.168.191.112
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
ip route add 192.168.50.0/24 via 10.8.0.1 dev tun0
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
4.新启动 OpenVPN 服务
systemctl restart openvpn
docker run -d \
  --name=wg-client2 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  -v /mnt/wg0:/etc/wireguard/wg0 \
  weejewel/wg-easy
docker run -d \
  --name=wg-wireguard \
  -e WG_HOST=10.0.0.1 \
  -e PASSWORD= \
  --network host \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
docker run -d \
  --name=wg-easy3 \
  --network host \
  --privileged \
  -e WG_HOST=39.174.229.143 \
  -e PASSWORD= \
  -e WG_PERSISTENT_KEEPALIVE=25 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
network:
  ethernets:
    eth0:  # 请替换为你的实际网卡名称
      dhcp4: no
      addresses:
        - 192.168.0.219/24  # 设置静态 IP
      gateway4: 192.168.0.8  # 设置网关
      nameservers:
        addresses:
          - 211.140.13.188
  version: 2
ip route add 192.168.200.0/24 via 10.8.0.1 dev tun0
iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE
iptables -A FORWARD -i tun0 -o eth1 -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A FORWARD -i eth1 -o tun0 -j ACCEPT


docker run -d \
  --name=wireguard-client \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -v /mnt:/config \
  -v /lib/modules:/lib/modules \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  lscr.io/linuxserver/wireguard:latest

enp1s0    enx00e04c360351
network:
  version: 2
  renderer: networkd
  ethernets:
    eth0:
      dhcp4: yes
      dhcp6: no
    enx00e04c360351:
      addresses:
        - 10.131.61.111/24
      dhcp4: no
sudo iptables -t nat -A POSTROUTING -o enp1s0 -j MASQUERADE
sudo iptables -A FORWARD -i enx00e04c360351 -o enp1s0 -j ACCEPT
sudo iptables -A FORWARD -i enp1s0 -o enx00e04c360351 -m state --state RELATED,ESTABLISHED -j ACCEPT
ip route add 22.8.144.97 via 10.130.61.1 dev enx00e04c360351
ip route add 22.8.144.97 via 10.131.61.1 dev br-lan  
ip route add 22.8.144.97 via 10.0.0.5 dev wireguard 
22.8.144.97
ip route add 22.8.144.97 via 192.168.0.8 dev eth0
39.174.229.143
10.0.0.0/24
uci show firewall | grep '@redirect'
docker run -d \
  --name=transmission \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -p 80:9091 \
  -p 51413:51413 \
  -p 51413:51413/udp \
  -v /home/download:/downloads \
  --restart unless-stopped \
  lscr.io/linuxserver/transmission:latest

docker run --restart always --name openwrt -d --network macnet --privileged --ip 10.1.25.193 ophub/openwrt-aarch64:latest
uci set zerotier.global.enabled='1'
uci delete zerotier.earth
uci set zerotier.openwrt_network=network
uci set zerotier.openwrt_network.id='856127940c66f22d'
uci commit zerotier
ip link set  eth0 promisc on
docker network create -d macvlan --subnet=192.168.50.0/24 --gateway=192.168.50.1 -o parent=br-lan  mynet
docker run  --name openwrt --restart unless-stopped -d --network mynet    --privileged --ip 192.168.50.314  openwrt  /sbin/init
docker run -d \
  --name=resilio-sync \
  -p 8888:8888 \
  -p 55555:55555 \
  -v /mnt/sda1/resilio:/mnt/sync \
  -v /mnt/sda1/resilio-config:/config \
  --restart unless-stopped \
  resilio/sync

src/gz openwrt_core https://downloads.openwrt.org/releases/24.10.0 /packages/x86_64/core
src/gz openwrt_base https://downloads.openwrt.org/releases/24.10.0 /packages/x86_64/base
src/gz openwrt_luci https://downloads.openwrt.org/releases/24.10.0 /packages/x86_64/luci
src/gz openwrt_packages https://downloads.openwrt.org/releases/24.10.0 /packages/x86_64/packages
src/gz openwrt_routing https://downloads.openwrt.org/releases/24.10.0 /packages/x86_64/routing
src/gz openwrt_telephony https://downloads.openwrt.org/releases/24.10.0 /packages/x86_64/telephony


c0: 20250204202213-2virs7k
c2: update
c3: 复制修改版
c5: 2025-03-13-204234-update/20250204202137-3g13i3l/20250204202213-2virs7k.sy
c6: 1741869754
c4:
通过 iPhone 镜像从 Mac 使用 iPhone
魔兽争霸:https://www.123pan.com/s/nVxFjv-fkwd3.html
dd if=openwrt-24.10.0-x86-64-generic-ext4-combined-efi.img of=/dev/sdb bs=4M
docker dockerd luci-lib-docker docker-compose
docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
dd if=/dev/sda of=/root/openwrt24.img bs=4M status=progress

docker run -d  -v /mnt/sda1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d \
  --name=qbittorrent \
  -e PUID=1000 -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -e WEBUI_PORT=8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -p 80:8080 \
  -v /home/qbittorrent/:/downloads \
  --restart unless-stopped \
  linuxserver/qbittorrent

docker run -d \
  --name=qbittorrent \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 2000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/sda2:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

dd if=istoreo.img of=/dev/sda bs=4M
docker run -d --name=xunlei --hostname=mynas --net=host -v /mnt/usb1:/xunlei/data -v /mnt/usb1/downloads:/xunlei/downloads --restart=unless-stopped --privileged cnk3x/xunlei:latest
docker run -d --privileged  -v /mnt/sda2:/xunlei/downloads -p 2345:2345 cnk3x/xunlei
docker run -d -v /mnt/usb1/siyuan:/siyuan/workspace  -e PUID=$UID  -e PGID=$GID  -p 6806:6806 b3log/siyuan  --workspace=/siyuan/workspace/ --accessAuthCode=xxx
docker run -d --name=siyuan -v /mnt/usb1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d --name syncthing  --restart always -p 3000:8384 -p 22000:22000/tcp -p 22000:22000/udp  -p 21027:21027/udp -v /mnt/config-sync:/var/syncthing/config -v /mnt:/var/syncthing/data syncthing/syncthing
docker run -d \
  --name syncthing \
  --restart always \
  -p 8384:8384 \
  -p 22000:22000/tcp \
  -p 22000:22000/udp \
  -p 21027:21027/udp \
  -v /mnt/usb2/syncthing/config:/var/syncthing/config \
  -v /mnt/usb2/syncthing/:/var/syncthing/data \
  syncthing/syncthing
docker run -d --name=samba  --restart unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NNN"  -v "/mnt:/storage" dockurr/samba
opkg install fdisk block-mount unzip zerotier samba4-server samba4-utils luci-app-samba4 openssh-sftp-server openvpn-openssl luci-app-openvpn wireguard-tools kmod-wireguard luci-proto-wi
mkdir -p /tmp/introot
mkdir -p /tmp/extroot
mount --bind / /tmp/introot
mount /dev/sda3 /tmp/extroot
tar -C /tmp/introot -cvf - . | tar -C /tmp/extroot -xf -
umount /tmp/introot
umount /tmp/extroot
docker run -d --name=samba --restart=unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NBBN"  -v "/mnt/:/storage" dockurr/samba
network:
  version: 2
  renderer: networkd
  wifis:
    wlp2s0:
      dhcp4: no
      addresses:
        - 192.168.0.124/24  # 这里改成你想要的静态 IP
      gateway4: 192.168.0.8  # 你的网关 IP（通常是路由器 IP）
      nameservers:
        addresses:
          - 211.140.13.188   
          - 114.114.114.114  # 114 DNS
      access-points:
        "boci1":
          password: "a1b2c3d4"


docker run --restart always --name openwrt1 -d --network macnet --privileged --ip 192.168.0.124   openwrt /sbin/init
docker run -d \
  --name=clash \
  -v /root/clash.yaml: /root/.config/clash/config.yaml \
  -p 7890:7890 \
  -p 9090:9090 \
  --restart unless-stopped \
  dreamacro/clash

安装官方最新版本：
curl -fsSL https://get.docker.com | bash
docker import rootfs.tar.gz my-custom-image
docker run -d \
  --name openwrt \
  --network host \
  --privileged \
  openwrt
docker run --restart always --name openwrt -p 80:80 -d --network host --privileged openwrt /sbin/init
允许 ZeroTier 网络访问本地网络
sudo iptables -A FORWARD -s 192.168.192.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 192.168.0.0/24 -d 192.168.192.0/24 -j ACCEPT
如果局域网设备默认网关不是 Ubuntu，需要 NAT
sudo iptables -t nat -A POSTROUTING -s 192.168.192.0/24 -d 192.168.0.0/24 -j MASQUERADE
eroTier 网络
192.168.0.0/24 via 192.168.191.112
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
ip route add 192.168.50.0/24 via 10.8.0.1 dev tun0
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
4.新启动 OpenVPN 服务
systemctl restart openvpn
docker run -d \
  --name=wg-client2 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  -v /mnt/wg0:/etc/wireguard/wg0 \
  weejewel/wg-easy
docker run -d \
  --name=wg-wireguard \
  -e WG_HOST=10.0.0.1 \
  -e PASSWORD= \
  --network host \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
docker run -d \
  --name=wg-easy3 \
  --network host \
  --privileged \
  -e WG_HOST=39.174.229.143 \
  -e PASSWORD= \
  -e WG_PERSISTENT_KEEPALIVE=25 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
network:
  ethernets:
    eth0:  # 请替换为你的实际网卡名称
      dhcp4: no
      addresses:
        - 192.168.0.219/24  # 设置静态 IP
      gateway4: 192.168.0.8  # 设置网关
      nameservers:
        addresses:
          - 211.140.13.188
  version: 2
ip route add 192.168.200.0/24 via 10.8.0.1 dev tun0
iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE
iptables -A FORWARD -i tun0 -o eth1 -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A FORWARD -i eth1 -o tun0 -j ACCEPT


docker run -d \
  --name=wireguard-client \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -v /mnt:/config \
  -v /lib/modules:/lib/modules \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  lscr.io/linuxserver/wireguard:latest

enp1s0    enx00e04c360351
network:
  version: 2
  renderer: networkd
  ethernets:
    eth0:
      dhcp4: yes
      dhcp6: no
    enx00e04c360351:
      addresses:
        - 10.131.61.111/24
      dhcp4: no
sudo iptables -t nat -A POSTROUTING -o enp1s0 -j MASQUERADE
sudo iptables -A FORWARD -i enx00e04c360351 -o enp1s0 -j ACCEPT
sudo iptables -A FORWARD -i enp1s0 -o enx00e04c360351 -m state --state RELATED,ESTABLISHED -j ACCEPT
ip route add 22.8.144.97 via 10.130.61.1 dev enx00e04c360351
ip route add 22.8.144.97 via 10.131.61.1 dev br-lan  
ip route add 22.8.144.97 via 10.0.0.5 dev wireguard 
22.8.144.97
ip route add 22.8.144.97 via 192.168.0.8 dev eth0
39.174.229.143
10.0.0.0/24
uci show firewall | grep '@redirect'
docker run -d \
  --name=transmission \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -p 80:9091 \
  -p 51413:51413 \
  -p 51413:51413/udp \
  -v /home/download:/downloads \
  --restart unless-stopped \
  lscr.io/linuxserver/transmission:latest

docker run --restart always --name openwrt -d --network macnet --privileged --ip 10.1.25.193 ophub/openwrt-aarch64:latest
uci set zerotier.global.enabled='1'
uci delete zerotier.earth
uci set zerotier.openwrt_network=network
uci set zerotier.openwrt_network.id='856127940c66f22d'
uci commit zerotier
ip link set  eth0 promisc on
docker network create -d macvlan --subnet=192.168.50.0/24 --gateway=192.168.50.1 -o parent=br-lan  mynet
docker run  --name openwrt --restart unless-stopped -d --network mynet    --privileged --ip 192.168.50.314  openwrt  /sbin/init
docker run -d \
  --name=resilio-sync \
  -p 8888:8888 \
  -p 55555:55555 \
  -v /mnt/sda1/resilio:/mnt/sync \
  -v /mnt/sda1/resilio-config:/config \
  --restart unless-stopped \
  resilio/sync

[Interface]
PrivateKey = OO5201M+3VC3BpIZY7MGhMbZkIBlmGyzegh5sgWPjVU=
Address = 10.0.8.6/24
DNS = 211.140.13.188


[Peer]
PublicKey = klRBbxYnJUMuKBLewfTwaQdj08w9JoeipgZyhahyynU=
PresharedKey = NNwo3pswYpeHmrZV3aWoHT+aBCUq0VDMVDErAY4Z+7Y=
AllowedIPs = 10.0.8.0/24,10.1.25.0/24
PersistentKeepalive = 25
Endpoint = 39.174.229.143:51820


c0: 20250204202213-2virs7k
c2: update
c3: 复制修改版
c5: 2025-03-14-103234-update/20250204202137-3g13i3l/20250204202213-2virs7k.sy
c6: 1741919554
c4:
通过 iPhone 镜像从 Mac 使用 iPhone
魔兽争霸:https://www.123pan.com/s/nVxFjv-fkwd3.html
dd if=openwrt-24.10.0-x86-64-generic-ext4-combined-efi.img of=/dev/sdb bs=4M
docker dockerd luci-lib-docker docker-compose
docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
dd if=/dev/sda of=/root/openwrt24.img bs=4M status=progress

docker run -d  -v /mnt/sda1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d \
  --name=qbittorrent \
  -e PUID=1000 -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -e WEBUI_PORT=8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -p 80:8080 \
  -v /home/qbittorrent/:/downloads \
  --restart unless-stopped \
  linuxserver/qbittorrent

docker run -d \
  --name=qbittorrent \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 2000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/sda2:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

dd if=istoreo.img of=/dev/sda bs=4M
docker run -d --name=xunlei --hostname=mynas --net=host -v /mnt/usb1:/xunlei/data -v /mnt/usb1/downloads:/xunlei/downloads --restart=unless-stopped --privileged cnk3x/xunlei:latest
docker run -d --privileged  -v /mnt/sda2:/xunlei/downloads -p 2345:2345 cnk3x/xunlei
docker run -d -v /mnt/usb1/siyuan:/siyuan/workspace  -e PUID=$UID  -e PGID=$GID  -p 6806:6806 b3log/siyuan  --workspace=/siyuan/workspace/ --accessAuthCode=xxx
docker run -d --name=siyuan -v /mnt/usb1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d --name syncthing  --restart always -p 3000:8384 -p 22000:22000/tcp -p 22000:22000/udp  -p 21027:21027/udp -v /mnt/config-sync:/var/syncthing/config -v /mnt:/var/syncthing/data syncthing/syncthing
docker run -d \
  --name syncthing \
  --restart always \
  -p 8384:8384 \
  -p 22000:22000/tcp \
  -p 22000:22000/udp \
  -p 21027:21027/udp \
  -v /mnt/usb2/syncthing/config:/var/syncthing/config \
  -v /mnt/usb2/syncthing/:/var/syncthing/data \
  syncthing/syncthing
docker run -d --name=samba  --restart unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NNN"  -v "/mnt:/storage" dockurr/samba
opkg install fdisk block-mount unzip zerotier samba4-server samba4-utils luci-app-samba4 openssh-sftp-server openvpn-openssl luci-app-openvpn wireguard-tools kmod-wireguard luci-proto-wireguard
mkdir -p /tmp/introot
mkdir -p /tmp/extroot
mount --bind / /tmp/introot
mount /dev/sda3 /tmp/extroot
tar -C /tmp/introot -cvf - . | tar -C /tmp/extroot -xf -
umount /tmp/introot
umount /tmp/extroot
docker run -d --name=samba --restart=unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NBBN"  -v "/mnt/:/storage" dockurr/samba
network:
  version: 2
  renderer: networkd
  wifis:
    wlp2s0:
      dhcp4: no
      addresses:
        - 192.168.0.124/24  # 这里改成你想要的静态 IP
      gateway4: 192.168.0.8  # 你的网关 IP（通常是路由器 IP）
      nameservers:
        addresses:
          - 211.140.13.188   
          - 114.114.114.114  # 114 DNS
      access-points:
        "boci1":
          password: "a1b2c3d4"


docker run --restart always --name openwrt1 -d --network macnet --privileged --ip 192.168.0.124   openwrt /sbin/init
docker run -d \
  --name=clash \
  -v /root/clash.yaml: /root/.config/clash/config.yaml \
  -p 7890:7890 \
  -p 9090:9090 \
  --restart unless-stopped \
  dreamacro/clash

安装官方最新版本：
curl -fsSL https://get.docker.com | bash
docker import rootfs.tar.gz my-custom-image
docker run -d \
  --name openwrt \
  --network host \
  --privileged \
  openwrt
docker run --restart always --name openwrt -p 80:80 -d --network host --privileged openwrt /sbin/init
允许 ZeroTier 网络访问本地网络
sudo iptables -A FORWARD -s 192.168.192.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 192.168.0.0/24 -d 192.168.192.0/24 -j ACCEPT
如果局域网设备默认网关不是 Ubuntu，需要 NAT
sudo iptables -t nat -A POSTROUTING -s 192.168.192.0/24 -d 192.168.0.0/24 -j MASQUERADE
eroTier 网络
192.168.0.0/24 via 192.168.191.112
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
ip route add 192.168.50.0/24 via 10.8.0.1 dev tun0
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
4.新启动 OpenVPN 服务
systemctl restart openvpn
docker run -d \
  --name=wg-client2 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  -v /mnt/wg0:/etc/wireguard/wg0 \
  weejewel/wg-easy
docker run -d \
  --name=wg-wireguard \
  -e WG_HOST=10.0.0.1 \
  -e PASSWORD= \
  --network host \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
docker run -d \
  --name=wg-easy3 \
  --network host \
  --privileged \
  -e WG_HOST=39.174.229.143 \
  -e PASSWORD= \
  -e WG_PERSISTENT_KEEPALIVE=25 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
network:
  ethernets:
    eth0:  # 请替换为你的实际网卡名称
      dhcp4: no
      addresses:
        - 192.168.0.219/24  # 设置静态 IP
      gateway4: 192.168.0.8  # 设置网关
      nameservers:
        addresses:
          - 211.140.13.188
  version: 2
ip route add 192.168.200.0/24 via 10.8.0.1 dev tun0
iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE
iptables -A FORWARD -i tun0 -o eth1 -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A FORWARD -i eth1 -o tun0 -j ACCEPT


docker run -d \
  --name=wireguard-client \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -v /mnt:/config \
  -v /lib/modules:/lib/modules \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  lscr.io/linuxserver/wireguard:latest

enp1s0    enx00e04c360351
network:
  version: 2
  renderer: networkd
  ethernets:
    eth0:
      dhcp4: yes
      dhcp6: no
    enx00e04c360351:
      addresses:
        - 10.131.61.111/24
      dhcp4: no
sudo iptables -t nat -A POSTROUTING -o enp1s0 -j MASQUERADE
sudo iptables -A FORWARD -i enx00e04c360351 -o enp1s0 -j ACCEPT
sudo iptables -A FORWARD -i enp1s0 -o enx00e04c360351 -m state --state RELATED,ESTABLISHED -j ACCEPT
ip route add 22.8.144.97 via 10.130.61.1 dev enx00e04c360351
ip route add 22.8.144.97 via 10.131.61.1 dev br-lan  
ip route add 22.8.144.97 via 10.0.0.5 dev wireguard 
22.8.144.97
ip route add 22.8.144.97 via 192.168.0.8 dev eth0
39.174.229.143
10.0.0.0/24
uci show firewall | grep '@redirect'
docker run -d \
  --name=transmission \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -p 80:9091 \
  -p 51413:51413 \
  -p 51413:51413/udp \
  -v /home/download:/downloads \
  --restart unless-stopped \
  lscr.io/linuxserver/transmission:latest

docker run --restart always --name openwrt -d --network macnet --privileged --ip 10.1.25.193 ophub/openwrt-aarch64:latest
uci set zerotier.global.enabled='1'
uci delete zerotier.earth
uci set zerotier.openwrt_network=network
uci set zerotier.openwrt_network.id='856127940c66f22d'
uci commit zerotier
ip link set  eth0 promisc on
docker network create -d macvlan --subnet=192.168.50.0/24 --gateway=192.168.50.1 -o parent=br-lan  mynet
docker run  --name openwrt --restart unless-stopped -d --network mynet    --privileged --ip 192.168.50.314  openwrt  /sbin/init
docker run -d \
  --name=resilio-sync \
  -p 8888:8888 \
  -p 55555:55555 \
  -v /mnt/sda1/resilio:/mnt/sync \
  -v /mnt/sda1/resilio-config:/config \
  --restart unless-stopped \
  resilio/sync

[Interface]
PrivateKey = OO5201M+3VC3BpIZY7MGhMbZkIBlmGyzegh5sgWPjVU=
Address = 10.0.8.6/24
DNS = 211.140.13.188


[Peer]
PublicKey = klRBbxYnJUMuKBLewfTwaQdj08w9JoeipgZyhahyynU=
PresharedKey = NNwo3pswYpeHmrZV3aWoHT+aBCUq0VDMVDErAY4Z+7Y=
AllowedIPs = 10.0.8.0/24,10.1.25.0/24
PersistentKeepalive = 25
Endpoint = 39.174.229.143:51820


c0: 20250204202213-2virs7k
c2: update
c3: 复制修改版
c5: 2025-03-14-163234-update/20250204202137-3g13i3l/20250204202213-2virs7k.sy
c6: 1741941154
c4:
通过 iPhone 镜像从 Mac 使用 iPhone
魔兽争霸:https://www.123pan.com/s/nVxFjv-fkwd3.html
dd if=openwrt-24.10.0-x86-64-generic-ext4-combined-efi.img of=/dev/sdb bs=4M
docker dockerd luci-lib-docker docker-compose
docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
dd if=/dev/sda of=/root/openwrt24.img bs=4M status=progress

docker run -d  -v /mnt/sda1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d \
  --name=qbittorrent \
  -e PUID=1000 -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -e WEBUI_PORT=8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -p 80:8080 \
  -v /home/qbittorrent/:/downloads \
  --restart unless-stopped \
  linuxserver/qbittorrent

docker run -d \
  --name=qbittorrent \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 1000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

dd if=istoreo.img of=/dev/sda bs=4M
docker run -d --name=xunlei --hostname=mynas --net=host -v /mnt/usb1:/xunlei/data -v /mnt/usb1/downloads:/xunlei/downloads --restart=unless-stopped --privileged cnk3x/xunlei:latest
docker run -d --privileged  -v /mnt/:/xunlei/downloads -p 2345:2345 cnk3x/xunlei
docker run -d -v /mnt/usb1/siyuan:/siyuan/workspace  -e PUID=$UID  -e PGID=$GID  -p 6806:6806 b3log/siyuan  --workspace=/siyuan/workspace/ --accessAuthCode=xxx
docker run -d --name=siyuan -v /mnt/usb1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d --name syncthing  --restart always -p 3000:8384 -p 22000:22000/tcp -p 22000:22000/udp  -p 21027:21027/udp -v /mnt/config-sync:/var/syncthing/config -v /mnt:/var/syncthing/data syncthing/syncthing
docker run -d \
  --name syncthing \
  --restart always \
  -p 8384:8384 \
  -p 22000:22000/tcp \
  -p 22000:22000/udp \
  -p 21027:21027/udp \
  -v /mnt/usb2/syncthing/config:/var/syncthing/config \
  -v /mnt/usb2/syncthing/:/var/syncthing/data \
  syncthing/syncthing
docker run -d --name=samba  --restart unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NNN"  -v "/mnt:/storage" dockurr/samba
opkg install fdisk block-mount unzip zerotier samba4-server samba4-utils luci-app-samba4 openssh-sftp-server openvpn-openssl luci-app-openvpn wireguard-tools kmod-wireguard luci-proto-wireguard
mkdir -p /tmp/introot
mkdir -p /tmp/extroot
mount --bind / /tmp/introot
mount /dev/sda3 /tmp/extroot
tar -C /tmp/introot -cvf - . | tar -C /tmp/extroot -xf -
umount /tmp/introot
umount /tmp/extroot
docker run -d --name=samba --restart=unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NBBN"  -v "/mnt/:/storage" dockurr/samba
network:
  version: 2
  renderer: networkd
  wifis:
    wlp2s0:
      dhcp4: no
      addresses:
        - 192.168.0.124/24  # 这里改成你想要的静态 IP
      gateway4: 192.168.0.8  # 你的网关 IP（通常是路由器 IP）
      nameservers:
        addresses:
          - 211.140.13.188   
          - 114.114.114.114  # 114 DNS
      access-points:
        "boci1":
          password: "a1b2c3d4"


docker run --restart always --name openwrt1 -d --network macnet --privileged --ip 192.168.0.124   openwrt /sbin/init
docker run -d \
  --name=clash \
  -v /root/clash.yaml: /root/.config/clash/config.yaml \
  -p 7890:7890 \
  -p 9090:9090 \
  --restart unless-stopped \
  dreamacro/clash

安装官方最新版本：
curl -fsSL https://get.docker.com | bash
docker import rootfs.tar.gz my-custom-image
docker run -d \
  --name openwrt \
  --network host \
  --privileged \
  openwrt
docker run --restart always --name openwrt -p 80:80 -d --network host --privileged openwrt /sbin/init
允许 ZeroTier 网络访问本地网络
sudo iptables -A FORWARD -s 192.168.192.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 192.168.0.0/24 -d 192.168.192.0/24 -j ACCEPT
如果局域网设备默认网关不是 Ubuntu，需要 NAT
sudo iptables -t nat -A POSTROUTING -s 192.168.192.0/24 -d 192.168.0.0/24 -j MASQUERADE
eroTier 网络
192.168.0.0/24 via 192.168.191.112
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
ip route add 192.168.50.0/24 via 10.8.0.1 dev tun0
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
4.新启动 OpenVPN 服务
systemctl restart openvpn
docker run -d \
  --name=wg-client2 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  -v /mnt/wg0:/etc/wireguard/wg0 \
  weejewel/wg-easy
docker run -d \
  --name=wg-wireguard \
  -e WG_HOST=10.0.0.1 \
  -e PASSWORD= \
  --network host \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
docker run -d \
  --name=wg-easy3 \
  --network host \
  --privileged \
  -e WG_HOST=39.174.229.143 \
  -e PASSWORD= \
  -e WG_PERSISTENT_KEEPALIVE=25 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
network:
  ethernets:
    eth0:  # 请替换为你的实际网卡名称
      dhcp4: no
      addresses:
        - 192.168.0.219/24  # 设置静态 IP
      gateway4: 192.168.0.8  # 设置网关
      nameservers:
        addresses:
          - 211.140.13.188
  version: 2
ip route add 192.168.200.0/24 via 10.8.0.1 dev tun0
iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE
iptables -A FORWARD -i tun0 -o eth1 -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A FORWARD -i eth1 -o tun0 -j ACCEPT


docker run -d \
  --name=wireguard-client \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -v /mnt:/config \
  -v /lib/modules:/lib/modules \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  lscr.io/linuxserver/wireguard:latest

enp1s0    enx00e04c360351
network:
  version: 2
  renderer: networkd
  ethernets:
    eth0:
      dhcp4: yes
      dhcp6: no
    enx00e04c360351:
      addresses:
        - 10.131.61.111/24
      dhcp4: no
sudo iptables -t nat -A POSTROUTING -o enp1s0 -j MASQUERADE
sudo iptables -A FORWARD -i enx00e04c360351 -o enp1s0 -j ACCEPT
sudo iptables -A FORWARD -i enp1s0 -o enx00e04c360351 -m state --state RELATED,ESTABLISHED -j ACCEPT
ip route add 22.8.144.97 via 10.130.61.1 dev enx00e04c360351
ip route add 22.8.144.97 via 10.131.61.1 dev br-lan  
ip route add 22.8.144.97 via 10.0.0.5 dev wireguard 
22.8.144.97
ip route add 22.8.144.97 via 192.168.0.8 dev eth0
39.174.229.143
10.0.0.0/24
uci show firewall | grep '@redirect'
docker run -d \
  --name=transmission \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -p 80:9091 \
  -p 51413:51413 \
  -p 51413:51413/udp \
  -v /home/download:/downloads \
  --restart unless-stopped \
  lscr.io/linuxserver/transmission:latest

docker run --restart always --name openwrt -d --network macnet --privileged --ip 10.1.25.193 ophub/openwrt-aarch64:latest
uci set zerotier.global.enabled='1'
uci delete zerotier.earth
uci set zerotier.openwrt_network=network
uci set zerotier.openwrt_network.id='856127940c66f22d'
uci commit zerotier
ip link set  eth0 promisc on
docker network create -d macvlan --subnet=192.168.50.0/24 --gateway=192.168.50.1 -o parent=br-lan  mynet
docker run  --name openwrt --restart unless-stopped -d --network mynet    --privileged --ip 192.168.50.314  openwrt  /sbin/init
docker run -d \
  --name=resilio-sync \
  -p 8888:8888 \
  -p 55555:55555 \
  -v /mnt/sda1/resilio:/mnt/sync \
  -v /mnt/sda1/resilio-config:/config \
  --restart unless-stopped \
  resilio/sync

[Interface]
PrivateKey = OO5201M+3VC3BpIZY7MGhMbZkIBlmGyzegh5sgWPjVU=
Address = 10.0.8.6/24
DNS = 211.140.13.188


[Peer]
PublicKey = klRBbxYnJUMuKBLewfTwaQdj08w9JoeipgZyhahyynU=
PresharedKey = NNwo3pswYpeHmrZV3aWoHT+aBCUq0VDMVDErAY4Z+7Y=
AllowedIPs = 10.0.8.0/24,10.1.25.0/24
PersistentKeepalive = 25
Endpoint = 39.174.229.143:51820


c0: 20250204202213-2virs7k
c2: update
c3: 复制修改版
c5: 2025-03-14-164234-update/20250204202137-3g13i3l/20250204202213-2virs7k.sy
c6: 1741941754
c4:
通过 iPhone 镜像从 Mac 使用 iPhone
魔兽争霸:https://www.123pan.com/s/nVxFjv-fkwd3.html
dd if=openwrt-24.10.0-x86-64-generic-ext4-combined-efi.img of=/dev/sdb bs=4M
docker dockerd luci-lib-docker docker-compose
docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
dd if=/dev/sda of=/root/openwrt24.img bs=4M status=progress

docker run -d  -v /mnt/sda1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d \
  --name=qbittorrent \
  -e PUID=1000 -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -e WEBUI_PORT=8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -p 80:8080 \
  -v /home/qbittorrent/:/downloads \
  --restart unless-stopped \
  linuxserver/qbittorrent

docker run -d \
  --name=qbittorrent \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 1000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

dd if=istoreo.img of=/dev/sda bs=4M
docker run -d --name=xunlei --hostname=mynas --net=host -v /mnt/usb1:/xunlei/data -v /mnt/usb1/downloads:/xunlei/downloads --restart=unless-stopped --privileged cnk3x/xunlei:latest
docker run -d --privileged  -v /mnt/:/xunlei/downloads -p 2345:2345 cnk3x/xunlei
docker run -d -v /mnt/usb1/siyuan:/siyuan/workspace  -e PUID=$UID  -e PGID=$GID  -p 6806:6806 b3log/siyuan  --workspace=/siyuan/workspace/ --accessAuthCode=xxx
docker run -d --name=siyuan -v /mnt/usb1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d --name syncthing  --restart always -p 3000:8384 -p 22000:22000/tcp -p 22000:22000/udp  -p 21027:21027/udp -v /mnt/config-sync:/var/syncthing/config -v /mnt:/var/syncthing/data syncthing/syncthing
docker run -d \
  --name syncthing \
  --restart always \
  -p 8384:8384 \
  -p 22000:22000/tcp \
  -p 22000:22000/udp \
  -p 21027:21027/udp \
  -v /mnt/usb2/syncthing/config:/var/syncthing/config \
  -v /mnt/usb2/syncthing/:/var/syncthing/data \
  syncthing/syncthing
docker run -d --name=samba  --restart unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NNN"  -v "/mnt:/storage" dockurr/samba
opkg install fdisk block-mount unzip zerotier samba4-server samba4-utils luci-app-samba4 openssh-sftp-server openvpn-openssl luci-app-openvpn wireguard-tools kmod-wireguard luci-proto-wireguard
mkdir -p /tmp/introot
mkdir -p /tmp/extroot
mount --bind / /tmp/introot
mount /dev/sda3 /tmp/extroot
tar -C /tmp/introot -cvf - . | tar -C /tmp/extroot -xf -
umount /tmp/introot
umount /tmp/extroot
docker run -d --name=samba --restart=unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NBBN"  -v "/mnt/:/storage" dockurr/samba
network:
  version: 2
  renderer: networkd
  wifis:
    wlp2s0:
      dhcp4: no
      addresses:
        - 192.168.0.124/24  # 这里改成你想要的静态 IP
      gateway4: 192.168.0.8  # 你的网关 IP（通常是路由器 IP）
      nameservers:
        addresses:
          - 211.140.13.188   
          - 114.114.114.114  # 114 DNS
      access-points:
        "boci1":
          password: "a1b2c3d4"

docker run --name=webdav -d -e USERNAME=test -e PASSWORD=test -v /mnt:/webdav -p 8920:80 idelsink/webdav
docker run --restart always --name openwrt1 -d --network macnet --privileged --ip 192.168.0.124   openwrt /sbin/init
docker run -d \
  --name=clash \
  -v /root/clash.yaml: /root/.config/clash/config.yaml \
  -p 7890:7890 \
  -p 9090:9090 \
  --restart unless-stopped \
  dreamacro/clash

安装官方最新版本：
curl -fsSL https://get.docker.com | bash
docker import rootfs.tar.gz my-custom-image
docker run -d \
  --name openwrt \
  --network host \
  --privileged \
  openwrt
docker run --restart always --name openwrt -p 80:80 -d --network host --privileged openwrt /sbin/init
允许 ZeroTier 网络访问本地网络
sudo iptables -A FORWARD -s 192.168.192.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 192.168.0.0/24 -d 192.168.192.0/24 -j ACCEPT
如果局域网设备默认网关不是 Ubuntu，需要 NAT
sudo iptables -t nat -A POSTROUTING -s 192.168.192.0/24 -d 192.168.0.0/24 -j MASQUERADE
eroTier 网络
192.168.0.0/24 via 192.168.191.112
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
ip route add 192.168.50.0/24 via 10.8.0.1 dev tun0
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
4.新启动 OpenVPN 服务
systemctl restart openvpn
docker run -d \
  --name=wg-client2 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  -v /mnt/wg0:/etc/wireguard/wg0 \
  weejewel/wg-easy
docker run -d \
  --name=wg-wireguard \
  -e WG_HOST=10.0.0.1 \
  -e PASSWORD= \
  --network host \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
docker run -d \
  --name=wg-easy3 \
  --network host \
  --privileged \
  -e WG_HOST=39.174.229.143 \
  -e PASSWORD= \
  -e WG_PERSISTENT_KEEPALIVE=25 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
network:
  ethernets:
    eth0:  # 请替换为你的实际网卡名称
      dhcp4: no
      addresses:
        - 192.168.0.219/24  # 设置静态 IP
      gateway4: 192.168.0.8  # 设置网关
      nameservers:
        addresses:
          - 211.140.13.188
  version: 2
ip route add 192.168.200.0/24 via 10.8.0.1 dev tun0
iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE
iptables -A FORWARD -i tun0 -o eth1 -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A FORWARD -i eth1 -o tun0 -j ACCEPT


docker run -d \
  --name=wireguard-client \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -v /mnt:/config \
  -v /lib/modules:/lib/modules \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  lscr.io/linuxserver/wireguard:latest

enp1s0    enx00e04c360351
network:
  version: 2
  renderer: networkd
  ethernets:
    eth0:
      dhcp4: yes
      dhcp6: no
    enx00e04c360351:
      addresses:
        - 10.131.61.111/24
      dhcp4: no
sudo iptables -t nat -A POSTROUTING -o enp1s0 -j MASQUERADE
sudo iptables -A FORWARD -i enx00e04c360351 -o enp1s0 -j ACCEPT
sudo iptables -A FORWARD -i enp1s0 -o enx00e04c360351 -m state --state RELATED,ESTABLISHED -j ACCEPT
ip route add 22.8.144.97 via 10.130.61.1 dev enx00e04c360351
ip route add 22.8.144.97 via 10.131.61.1 dev br-lan  
ip route add 22.8.144.97 via 10.0.0.5 dev wireguard 
22.8.144.97
ip route add 22.8.144.97 via 192.168.0.8 dev eth0
39.174.229.143
10.0.0.0/24
uci show firewall | grep '@redirect'
docker run -d \
  --name=transmission \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -p 80:9091 \
  -p 51413:51413 \
  -p 51413:51413/udp \
  -v /home/download:/downloads \
  --restart unless-stopped \
  lscr.io/linuxserver/transmission:latest

docker run --restart always --name openwrt -d --network macnet --privileged --ip 10.1.25.193 ophub/openwrt-aarch64:latest
uci set zerotier.global.enabled='1'
uci delete zerotier.earth
uci set zerotier.openwrt_network=network
uci set zerotier.openwrt_network.id='856127940c66f22d'
uci commit zerotier
ip link set  eth0 promisc on
docker network create -d macvlan --subnet=192.168.50.0/24 --gateway=192.168.50.1 -o parent=br-lan  mynet
docker run  --name openwrt --restart unless-stopped -d --network mynet    --privileged --ip 192.168.50.314  openwrt  /sbin/init
docker run -d \
  --name=resilio-sync \
  -p 8888:8888 \
  -p 55555:55555 \
  -v /mnt/sda1/resilio:/mnt/sync \
  -v /mnt/sda1/resilio-config:/config \
  --restart unless-stopped \
  resilio/sync

[Interface]
PrivateKey = OO5201M+3VC3BpIZY7MGhMbZkIBlmGyzegh5sgWPjVU=
Address = 10.0.8.6/24
DNS = 211.140.13.188


[Peer]
PublicKey = klRBbxYnJUMuKBLewfTwaQdj08w9JoeipgZyhahyynU=
PresharedKey = NNwo3pswYpeHmrZV3aWoHT+aBCUq0VDMVDErAY4Z+7Y=
AllowedIPs = 10.0.8.0/24,10.1.25.0/24
PersistentKeepalive = 25
Endpoint = 39.174.229.143:51820


c0: 20250204202213-2virs7k
c2: update
c3: 复制修改版
c5: 2025-03-14-165234-update/20250204202137-3g13i3l/20250204202213-2virs7k.sy
c6: 1741942354
c4:
通过 iPhone 镜像从 Mac 使用 iPhone
魔兽争霸:https://www.123pan.com/s/nVxFjv-fkwd3.html
dd if=openwrt-24.10.0-x86-64-generic-ext4-combined-efi.img of=/dev/sdb bs=4M
docker dockerd luci-lib-docker docker-compose
docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
dd if=/dev/sda of=/root/openwrt24.img bs=4M status=progress

docker run -d  -v /mnt/sda1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d \
  --name=qbittorrent \
  -e PUID=1000 -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -e WEBUI_PORT=8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -p 80:8080 \
  -v /home/qbittorrent/:/downloads \
  --restart unless-stopped \
  linuxserver/qbittorrent

docker run -d \
  --name=qbittorrent \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 1000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

dd if=istoreo.img of=/dev/sda bs=4M
docker run -d --name=xunlei --hostname=mynas --net=host -v /mnt/usb1:/xunlei/data -v /mnt/usb1/downloads:/xunlei/downloads --restart=unless-stopped --privileged cnk3x/xunlei:latest
docker run -d --privileged  -v /mnt/:/xunlei/downloads -p 2345:2345 cnk3x/xunlei
docker run -d -v /mnt/usb1/siyuan:/siyuan/workspace  -e PUID=$UID  -e PGID=$GID  -p 6806:6806 b3log/siyuan  --workspace=/siyuan/workspace/ --accessAuthCode=xxx
docker run -d --name=siyuan -v /mnt/usb1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d --name syncthing  --restart always -p 3000:8384 -p 22000:22000/tcp -p 22000:22000/udp  -p 21027:21027/udp -v /mnt/config-sync:/var/syncthing/config -v /mnt:/var/syncthing/data syncthing/syncthing
docker run -d \
  --name syncthing \
  --restart always \
  -p 8384:8384 \
  -p 22000:22000/tcp \
  -p 22000:22000/udp \
  -p 21027:21027/udp \
  -v /mnt/usb2/syncthing/config:/var/syncthing/config \
  -v /mnt/usb2/syncthing/:/var/syncthing/data \
  syncthing/syncthing
docker run -d --name=samba  --restart unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NNN"  -v "/mnt:/storage" dockurr/samba
opkg install fdisk block-mount unzip zerotier samba4-server samba4-utils luci-app-samba4 openssh-sftp-server openvpn-openssl luci-app-openvpn wireguard-tools kmod-wireguard luci-proto-wireguard
mkdir -p /tmp/introot
mkdir -p /tmp/extroot
mount --bind / /tmp/introot
mount /dev/sda3 /tmp/extroot
tar -C /tmp/introot -cvf - . | tar -C /tmp/extroot -xf -
umount /tmp/introot
umount /tmp/extroot
docker run -d --name=samba --restart=unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NBBN"  -v "/mnt/:/storage" dockurr/samba
network:
  version: 2
  renderer: networkd
  wifis:
    wlp2s0:
      dhcp4: no
      addresses:
        - 192.168.0.124/24  # 这里改成你想要的静态 IP
      gateway4: 192.168.0.8  # 你的网关 IP（通常是路由器 IP）
      nameservers:
        addresses:
          - 211.140.13.188   
          - 114.114.114.114  # 114 DNS
      access-points:
        "boci1":
          password: "a1b2c3d4"

docker run --name=webdav -d -e USERNAME=test920 -e PASSWORD=test -v /mnt:/webdav -p 8920:80 idelsink/webdav
docker run --restart always --name openwrt1 -d --network macnet --privileged --ip 192.168.0.124   openwrt /sbin/init
docker run -d \
  --name=clash \
  -v /root/clash.yaml: /root/.config/clash/config.yaml \
  -p 7890:7890 \
  -p 9090:9090 \
  --restart unless-stopped \
  dreamacro/clash

安装官方最新版本：
curl -fsSL https://get.docker.com | bash
docker import rootfs.tar.gz my-custom-image
docker run -d \
  --name openwrt \
  --network host \
  --privileged \
  openwrt
docker run --restart always --name openwrt -p 80:80 -d --network host --privileged openwrt /sbin/init
允许 ZeroTier 网络访问本地网络
sudo iptables -A FORWARD -s 192.168.192.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 192.168.0.0/24 -d 192.168.192.0/24 -j ACCEPT
如果局域网设备默认网关不是 Ubuntu，需要 NAT
sudo iptables -t nat -A POSTROUTING -s 192.168.192.0/24 -d 192.168.0.0/24 -j MASQUERADE
eroTier 网络
192.168.0.0/24 via 192.168.191.112
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
ip route add 192.168.50.0/24 via 10.8.0.1 dev tun0
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
4.新启动 OpenVPN 服务
systemctl restart openvpn
docker run -d \
  --name=wg-client2 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  -v /mnt/wg0:/etc/wireguard/wg0 \
  weejewel/wg-easy
docker run -d \
  --name=wg-wireguard \
  -e WG_HOST=10.0.0.1 \
  -e PASSWORD= \
  --network host \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
docker run -d \
  --name=wg-easy3 \
  --network host \
  --privileged \
  -e WG_HOST=39.174.229.143 \
  -e PASSWORD= \
  -e WG_PERSISTENT_KEEPALIVE=25 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
network:
  ethernets:
    eth0:  # 请替换为你的实际网卡名称
      dhcp4: no
      addresses:
        - 192.168.0.219/24  # 设置静态 IP
      gateway4: 192.168.0.8  # 设置网关
      nameservers:
        addresses:
          - 211.140.13.188
  version: 2
ip route add 192.168.200.0/24 via 10.8.0.1 dev tun0
iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE
iptables -A FORWARD -i tun0 -o eth1 -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A FORWARD -i eth1 -o tun0 -j ACCEPT


docker run -d \
  --name=wireguard-client \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -v /mnt:/config \
  -v /lib/modules:/lib/modules \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  lscr.io/linuxserver/wireguard:latest

enp1s0    enx00e04c360351
network:
  version: 2
  renderer: networkd
  ethernets:
    eth0:
      dhcp4: yes
      dhcp6: no
    enx00e04c360351:
      addresses:
        - 10.131.61.111/24
      dhcp4: no
sudo iptables -t nat -A POSTROUTING -o enp1s0 -j MASQUERADE
sudo iptables -A FORWARD -i enx00e04c360351 -o enp1s0 -j ACCEPT
sudo iptables -A FORWARD -i enp1s0 -o enx00e04c360351 -m state --state RELATED,ESTABLISHED -j ACCEPT
ip route add 22.8.144.97 via 10.130.61.1 dev enx00e04c360351
ip route add 22.8.144.97 via 10.131.61.1 dev br-lan  
ip route add 22.8.144.97 via 10.0.0.5 dev wireguard 
22.8.144.97
ip route add 22.8.144.97 via 192.168.0.8 dev eth0
39.174.229.143
10.0.0.0/24
uci show firewall | grep '@redirect'
docker run -d \
  --name=transmission \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -p 80:9091 \
  -p 51413:51413 \
  -p 51413:51413/udp \
  -v /home/download:/downloads \
  --restart unless-stopped \
  lscr.io/linuxserver/transmission:latest

docker run --restart always --name openwrt -d --network macnet --privileged --ip 10.1.25.193 ophub/openwrt-aarch64:latest
uci set zerotier.global.enabled='1'
uci delete zerotier.earth
uci set zerotier.openwrt_network=network
uci set zerotier.openwrt_network.id='856127940c66f22d'
uci commit zerotier
ip link set  eth0 promisc on
docker network create -d macvlan --subnet=192.168.50.0/24 --gateway=192.168.50.1 -o parent=br-lan  mynet
docker run  --name openwrt --restart unless-stopped -d --network mynet    --privileged --ip 192.168.50.314  openwrt  /sbin/init
docker run -d \
  --name=resilio-sync \
  -p 8888:8888 \
  -p 55555:55555 \
  -v /mnt/sda1/resilio:/mnt/sync \
  -v /mnt/sda1/resilio-config:/config \
  --restart unless-stopped \
  resilio/sync

[Interface]
PrivateKey = OO5201M+3VC3BpIZY7MGhMbZkIBlmGyzegh5sgWPjVU=
Address = 10.0.8.6/24
DNS = 211.140.13.188


[Peer]
PublicKey = klRBbxYnJUMuKBLewfTwaQdj08w9JoeipgZyhahyynU=
PresharedKey = NNwo3pswYpeHmrZV3aWoHT+aBCUq0VDMVDErAY4Z+7Y=
AllowedIPs = 10.0.8.0/24,10.1.25.0/24
PersistentKeepalive = 25
Endpoint = 39.174.229.143:51820


c0: 20250204202213-2virs7k
c2: update
c3: 复制修改版
c5: 2025-03-14-172234-update/20250204202137-3g13i3l/20250204202213-2virs7k.sy
c6: 1741944154
c4:
通过 iPhone 镜像从 Mac 使用 iPhone
魔兽争霸:https://www.123pan.com/s/nVxFjv-fkwd3.html
dd if=openwrt-24.10.0-x86-64-generic-ext4-combined-efi.img of=/dev/sdb bs=4M
docker dockerd luci-lib-docker docker-compose
docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
dd if=/dev/sda of=/root/openwrt24.img bs=4M status=progress

docker run -d  -v /mnt/sda1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d \
  --name=qbittorrent \
  -e PUID=1000 -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -e WEBUI_PORT=8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -p 80:8080 \
  -v /home/qbittorrent/:/downloads \
  --restart unless-stopped \
  linuxserver/qbittorrent

docker run -d \
  --name=qbittorrent \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 1000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

dd if=istoreo.img of=/dev/sda bs=4M
docker run -d --name=xunlei --hostname=mynas --net=host -v /mnt/usb1:/xunlei/data -v /mnt/usb1/downloads:/xunlei/downloads --restart=unless-stopped --privileged cnk3x/xunlei:latest
docker run -d --privileged  -v /mnt/:/xunlei/downloads -p 2345:2345 cnk3x/xunlei
docker run -d -v /mnt/usb1/siyuan:/siyuan/workspace  -e PUID=$UID  -e PGID=$GID  -p 6806:6806 b3log/siyuan  --workspace=/siyuan/workspace/ --accessAuthCode=xxx
docker run -d --name=siyuan -v /mnt/usb1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d --name syncthing  --restart always -p 3000:8384 -p 22000:22000/tcp -p 22000:22000/udp  -p 21027:21027/udp -v /mnt/config-sync:/var/syncthing/config -v /mnt:/var/syncthing/data syncthing/syncthing
docker run -d \
  --name syncthing \
  --restart always \
  -p 8384:8384 \
  -p 22000:22000/tcp \
  -p 22000:22000/udp \
  -p 21027:21027/udp \
  -v /mnt/usb2/syncthing/config:/var/syncthing/config \
  -v /mnt/usb2/syncthing/:/var/syncthing/data \
  syncthing/syncthing
docker run -d --name=samba  --restart unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NNN"  -v "/mnt:/storage" dockurr/samba
opkg install fdisk block-mount unzip zerotier samba4-server samba4-utils luci-app-samba4 openssh-sftp-server openvpn-openssl luci-app-openvpn wireguard-tools kmod-wireguard luci-proto-wireguard
mkdir -p /tmp/introot
mkdir -p /tmp/extroot
mount --bind / /tmp/introot
mount /dev/sda3 /tmp/extroot
tar -C /tmp/introot -cvf - . | tar -C /tmp/extroot -xf -
umount /tmp/introot
umount /tmp/extroot
docker run -d --name=samba --restart=unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NBBN"  -v "/mnt/:/storage" dockurr/samba
network:
  version: 2
  renderer: networkd
  wifis:
    wlp2s0:
      dhcp4: no
      addresses:
        - 192.168.0.124/24  # 这里改成你想要的静态 IP
      gateway4: 192.168.0.8  # 你的网关 IP（通常是路由器 IP）
      nameservers:
        addresses:
          - 211.140.13.188   
          - 114.114.114.114  # 114 DNS
      access-points:
        "boci1":
          password: "a1b2c3d4"

docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
docker run --restart always --name openwrt1 -d --network macnet --privileged --ip 192.168.0.124   openwrt /sbin/init
docker run -d \
  --name=clash \
  -v /root/clash.yaml: /root/.config/clash/config.yaml \
  -p 7890:7890 \
  -p 9090:9090 \
  --restart unless-stopped \
  dreamacro/clash

安装官方最新版本：
curl -fsSL https://get.docker.com | bash
docker import rootfs.tar.gz my-custom-image
docker run -d \
  --name openwrt \
  --network host \
  --privileged \
  openwrt
docker run --restart always --name openwrt -p 80:80 -d --network host --privileged openwrt /sbin/init
允许 ZeroTier 网络访问本地网络
sudo iptables -A FORWARD -s 192.168.192.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 192.168.0.0/24 -d 192.168.192.0/24 -j ACCEPT
如果局域网设备默认网关不是 Ubuntu，需要 NAT
sudo iptables -t nat -A POSTROUTING -s 192.168.192.0/24 -d 192.168.0.0/24 -j MASQUERADE
eroTier 网络
192.168.0.0/24 via 192.168.191.112
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
ip route add 192.168.50.0/24 via 10.8.0.1 dev tun0
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
4.新启动 OpenVPN 服务
systemctl restart openvpn
docker run -d \
  --name=wg-client2 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  -v /mnt/wg0:/etc/wireguard/wg0 \
  weejewel/wg-easy
docker run -d \
  --name=wg-wireguard \
  -e WG_HOST=10.0.0.1 \
  -e PASSWORD= \
  --network host \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
docker run -d \
  --name=wg-easy3 \
  --network host \
  --privileged \
  -e WG_HOST=39.174.229.143 \
  -e PASSWORD= \
  -e WG_PERSISTENT_KEEPALIVE=25 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
network:
  ethernets:
    eth0:  # 请替换为你的实际网卡名称
      dhcp4: no
      addresses:
        - 192.168.0.219/24  # 设置静态 IP
      gateway4: 192.168.0.8  # 设置网关
      nameservers:
        addresses:
          - 211.140.13.188
  version: 2
ip route add 192.168.200.0/24 via 10.8.0.1 dev tun0
iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE
iptables -A FORWARD -i tun0 -o eth1 -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A FORWARD -i eth1 -o tun0 -j ACCEPT


docker run -d \
  --name=wireguard-client \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -v /mnt:/config \
  -v /lib/modules:/lib/modules \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  lscr.io/linuxserver/wireguard:latest

enp1s0    enx00e04c360351
network:
  version: 2
  renderer: networkd
  ethernets:
    eth0:
      dhcp4: yes
      dhcp6: no
    enx00e04c360351:
      addresses:
        - 10.131.61.111/24
      dhcp4: no
sudo iptables -t nat -A POSTROUTING -o enp1s0 -j MASQUERADE
sudo iptables -A FORWARD -i enx00e04c360351 -o enp1s0 -j ACCEPT
sudo iptables -A FORWARD -i enp1s0 -o enx00e04c360351 -m state --state RELATED,ESTABLISHED -j ACCEPT
ip route add 22.8.144.97 via 10.130.61.1 dev enx00e04c360351
ip route add 22.8.144.97 via 10.131.61.1 dev br-lan  
ip route add 22.8.144.97 via 10.0.0.5 dev wireguard 
22.8.144.97
ip route add 22.8.144.97 via 192.168.0.8 dev eth0
39.174.229.143
10.0.0.0/24
uci show firewall | grep '@redirect'
docker run -d \
  --name=transmission \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -p 80:9091 \
  -p 51413:51413 \
  -p 51413:51413/udp \
  -v /home/download:/downloads \
  --restart unless-stopped \
  lscr.io/linuxserver/transmission:latest

docker run --restart always --name openwrt -d --network macnet --privileged --ip 10.1.25.193 ophub/openwrt-aarch64:latest
uci set zerotier.global.enabled='1'
uci delete zerotier.earth
uci set zerotier.openwrt_network=network
uci set zerotier.openwrt_network.id='856127940c66f22d'
uci commit zerotier
ip link set  eth0 promisc on
docker network create -d macvlan --subnet=192.168.50.0/24 --gateway=192.168.50.1 -o parent=br-lan  mynet
docker run  --name openwrt --restart unless-stopped -d --network mynet    --privileged --ip 192.168.50.314  openwrt  /sbin/init
docker run -d \
  --name=resilio-sync \
  -p 8888:8888 \
  -p 55555:55555 \
  -v /mnt/sda1/resilio:/mnt/sync \
  -v /mnt/sda1/resilio-config:/config \
  --restart unless-stopped \
  resilio/sync

[Interface]
PrivateKey = OO5201M+3VC3BpIZY7MGhMbZkIBlmGyzegh5sgWPjVU=
Address = 10.0.8.6/24
DNS = 211.140.13.188


[Peer]
PublicKey = klRBbxYnJUMuKBLewfTwaQdj08w9JoeipgZyhahyynU=
PresharedKey = NNwo3pswYpeHmrZV3aWoHT+aBCUq0VDMVDErAY4Z+7Y=
AllowedIPs = 10.0.8.0/24,10.1.25.0/24
PersistentKeepalive = 25
Endpoint = 39.174.229.143:51820


c0: 20250204202213-2virs7k
c2: update
c3: 复制修改版
c5: 2025-03-15-083234-update/20250204202137-3g13i3l/20250204202213-2virs7k.sy
c6: 1741998754
c4:
通过 iPhone 镜像从 Mac 使用 iPhone
魔兽争霸:https://www.123pan.com/s/nVxFjv-fkwd3.html
dd if=openwrt-24.10.0-armsr-armv8-generic-ext4-combined-efi.img of=/dev/mmcblk2 bs=4M
docker dockerd luci-lib-docker docker-compose
docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
dd if=/dev/sda of=/root/openwrt24.img bs=4M status=progress

docker run -d  -v /mnt/sda1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d \
  --name=qbittorrent \
  -e PUID=1000 -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -e WEBUI_PORT=8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -p 80:8080 \
  -v /home/qbittorrent/:/downloads \
  --restart unless-stopped \
  linuxserver/qbittorrent

docker run -d \
  --name=qbittorrent \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 1000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

dd if=istoreo.img of=/dev/sda bs=4M
docker run -d --name=xunlei --hostname=mynas --net=host -v /mnt/usb1:/xunlei/data -v /mnt/usb1/downloads:/xunlei/downloads --restart=unless-stopped --privileged cnk3x/xunlei:latest
docker run -d --privileged  -v /mnt/:/xunlei/downloads -p 2345:2345 cnk3x/xunlei
docker run -d -v /mnt/usb1/siyuan:/siyuan/workspace  -e PUID=$UID  -e PGID=$GID  -p 6806:6806 b3log/siyuan  --workspace=/siyuan/workspace/ --accessAuthCode=xxx
docker run -d --name=siyuan -v /mnt/usb1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d --name syncthing  --restart always -p 3000:8384 -p 22000:22000/tcp -p 22000:22000/udp  -p 21027:21027/udp -v /mnt/config-sync:/var/syncthing/config -v /mnt:/var/syncthing/data syncthing/syncthing
docker run -d \
  --name syncthing \
  --restart always \
  -p 8384:8384 \
  -p 22000:22000/tcp \
  -p 22000:22000/udp \
  -p 21027:21027/udp \
  -v /mnt/usb2/syncthing/config:/var/syncthing/config \
  -v /mnt/usb2/syncthing/:/var/syncthing/data \
  syncthing/syncthing
docker run -d --name=samba  --restart unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NNN"  -v "/mnt:/storage" dockurr/samba
opkg install fdisk block-mount unzip zerotier samba4-server samba4-utils luci-app-samba4 openssh-sftp-server openvpn-openssl luci-app-openvpn wireguard-tools kmod-wireguard luci-proto-wireguard
mkdir -p /tmp/introot
mkdir -p /tmp/extroot
mount --bind / /tmp/introot
mount /dev/sda3 /tmp/extroot
tar -C /tmp/introot -cvf - . | tar -C /tmp/extroot -xf -
umount /tmp/introot
umount /tmp/extroot
docker run -d --name=samba --restart=unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NBBN"  -v "/mnt/:/storage" dockurr/samba
network:
  version: 2
  renderer: networkd
  wifis:
    wlp2s0:
      dhcp4: no
      addresses:
        - 192.168.0.124/24  # 这里改成你想要的静态 IP
      gateway4: 192.168.0.8  # 你的网关 IP（通常是路由器 IP）
      nameservers:
        addresses:
          - 211.140.13.188   
          - 114.114.114.114  # 114 DNS
      access-points:
        "boci1":
          password: "a1b2c3d4"

docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
docker run --restart always --name openwrt1 -d --network macnet --privileged --ip 192.168.0.124   openwrt /sbin/init
docker run -d \
  --name=clash \
  -v /root/clash.yaml: /root/.config/clash/config.yaml \
  -p 7890:7890 \
  -p 9090:9090 \
  --restart unless-stopped \
  dreamacro/clash

安装官方最新版本：
curl -fsSL https://get.docker.com | bash
docker import rootfs.tar.gz my-custom-image
docker run -d \
  --name openwrt \
  --network host \
  --privileged \
  openwrt
docker run --restart always --name openwrt -p 80:80 -d --network host --privileged openwrt /sbin/init
允许 ZeroTier 网络访问本地网络
sudo iptables -A FORWARD -s 192.168.192.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 192.168.0.0/24 -d 192.168.192.0/24 -j ACCEPT
如果局域网设备默认网关不是 Ubuntu，需要 NAT
sudo iptables -t nat -A POSTROUTING -s 192.168.192.0/24 -d 192.168.0.0/24 -j MASQUERADE
eroTier 网络
192.168.0.0/24 via 192.168.191.112
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
ip route add 192.168.50.0/24 via 10.8.0.1 dev tun0
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
4.新启动 OpenVPN 服务
systemctl restart openvpn
docker run -d \
  --name=wg-client2 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  -v /mnt/wg0:/etc/wireguard/wg0 \
  weejewel/wg-easy
docker run -d \
  --name=wg-wireguard \
  -e WG_HOST=10.0.0.1 \
  -e PASSWORD= \
  --network host \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
docker run -d \
  --name=wg-easy3 \
  --network host \
  --privileged \
  -e WG_HOST=39.174.229.143 \
  -e PASSWORD= \
  -e WG_PERSISTENT_KEEPALIVE=25 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
network:
  ethernets:
    eth0:  # 请替换为你的实际网卡名称
      dhcp4: no
      addresses:
        - 192.168.0.219/24  # 设置静态 IP
      gateway4: 192.168.0.8  # 设置网关
      nameservers:
        addresses:
          - 211.140.13.188
  version: 2
ip route add 192.168.200.0/24 via 10.8.0.1 dev tun0
iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE
iptables -A FORWARD -i tun0 -o eth1 -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A FORWARD -i eth1 -o tun0 -j ACCEPT


docker run -d \
  --name=wireguard-client \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -v /mnt:/config \
  -v /lib/modules:/lib/modules \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  lscr.io/linuxserver/wireguard:latest

enp1s0    enx00e04c360351
network:
  version: 2
  renderer: networkd
  ethernets:
    eth0:
      dhcp4: yes
      dhcp6: no
    enx00e04c360351:
      addresses:
        - 10.131.61.111/24
      dhcp4: no
sudo iptables -t nat -A POSTROUTING -o enp1s0 -j MASQUERADE
sudo iptables -A FORWARD -i enx00e04c360351 -o enp1s0 -j ACCEPT
sudo iptables -A FORWARD -i enp1s0 -o enx00e04c360351 -m state --state RELATED,ESTABLISHED -j ACCEPT
ip route add 22.8.144.97 via 10.130.61.1 dev enx00e04c360351
ip route add 22.8.144.97 via 10.131.61.1 dev br-lan  
ip route add 22.8.144.97 via 10.0.0.5 dev wireguard 
22.8.144.97
ip route add 22.8.144.97 via 192.168.0.8 dev eth0
39.174.229.143
10.0.0.0/24
uci show firewall | grep '@redirect'
docker run -d \
  --name=transmission \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -p 80:9091 \
  -p 51413:51413 \
  -p 51413:51413/udp \
  -v /home/download:/downloads \
  --restart unless-stopped \
  lscr.io/linuxserver/transmission:latest

docker run --restart always --name openwrt -d --network macnet --privileged --ip 10.1.25.193 ophub/openwrt-aarch64:latest
uci set zerotier.global.enabled='1'
uci delete zerotier.earth
uci set zerotier.openwrt_network=network
uci set zerotier.openwrt_network.id='856127940c66f22d'
uci commit zerotier
ip link set  eth0 promisc on
docker network create -d macvlan --subnet=192.168.50.0/24 --gateway=192.168.50.1 -o parent=br-lan  mynet
docker run  --name openwrt --restart unless-stopped -d --network mynet    --privileged --ip 192.168.50.314  openwrt  /sbin/init
docker run -d \
  --name=resilio-sync \
  -p 8888:8888 \
  -p 55555:55555 \
  -v /mnt/sda1/resilio:/mnt/sync \
  -v /mnt/sda1/resilio-config:/config \
  --restart unless-stopped \
  resilio/sync

[Interface]
PrivateKey = OO5201M+3VC3BpIZY7MGhMbZkIBlmGyzegh5sgWPjVU=
Address = 10.0.8.6/24
DNS = 211.140.13.188


[Peer]
PublicKey = klRBbxYnJUMuKBLewfTwaQdj08w9JoeipgZyhahyynU=
PresharedKey = NNwo3pswYpeHmrZV3aWoHT+aBCUq0VDMVDErAY4Z+7Y=
AllowedIPs = 10.0.8.0/24,10.1.25.0/24
PersistentKeepalive = 25
Endpoint = 39.174.229.143:51820


c0: 20250204202213-2virs7k
c2: update
c3: 复制修改版
c5: 2025-03-15-104234-update/20250204202137-3g13i3l/20250204202213-2virs7k.sy
c6: 1742006554
c4:
通过 iPhone 镜像从 Mac 使用 iPhone
魔兽争霸:https://www.123pan.com/s/nVxFjv-fkwd3.html
dd if=openwrt-24.10.0-armsr-armv8-generic-ext4-combined-efi.img of=/dev/mmcblk2 bs=4M
docker dockerd luci-lib-docker docker-compose
docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
dd if=/dev/sda of=/root/openwrt24.img bs=4M status=progress

docker run -d  -v /mnt/usb1_2-1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d \
  --name=qbittorrent \
  -e PUID=1000 -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -e WEBUI_PORT=8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -p 80:8080 \
  -v /home/qbittorrent/:/downloads \
  --restart unless-stopped \
  linuxserver/qbittorrent

docker run -d \
  --name=qbittorrent \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 1000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

dd if=istoreo.img of=/dev/sda bs=4M
docker run -d --name=xunlei --hostname=mynas --net=host -v /mnt/usb1:/xunlei/data -v /mnt/usb1/downloads:/xunlei/downloads --restart=unless-stopped --privileged cnk3x/xunlei:latest
docker run -d --privileged  -v /mnt/:/xunlei/downloads -p 2345:2345 cnk3x/xunlei
docker run -d -v /mnt/usb1/siyuan:/siyuan/workspace  -e PUID=$UID  -e PGID=$GID  -p 6806:6806 b3log/siyuan  --workspace=/siyuan/workspace/ --accessAuthCode=xxx
docker run -d --name=siyuan -v /mnt/usb1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d --name syncthing  --restart always -p 3000:8384 -p 22000:22000/tcp -p 22000:22000/udp  -p 21027:21027/udp -v /mnt/config-sync:/var/syncthing/config -v /mnt:/var/syncthing/data syncthing/syncthing
docker run -d \
  --name syncthing \
  --restart always \
  -p 8384:8384 \
  -p 22000:22000/tcp \
  -p 22000:22000/udp \
  -p 21027:21027/udp \
  -v /mnt/usb2/syncthing/config:/var/syncthing/config \
  -v /mnt/usb2/syncthing/:/var/syncthing/data \
  syncthing/syncthing
docker run -d --name=samba  --restart unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NNN"  -v "/mnt:/storage" dockurr/samba
opkg install fdisk block-mount unzip zerotier samba4-server samba4-utils luci-app-samba4 openssh-sftp-server openvpn-openssl luci-app-openvpn wireguard-tools kmod-wireguard luci-proto-wireguard
mkdir -p /tmp/introot
mkdir -p /tmp/extroot
mount --bind / /tmp/introot
mount /dev/sda3 /tmp/extroot
tar -C /tmp/introot -cvf - . | tar -C /tmp/extroot -xf -
umount /tmp/introot
umount /tmp/extroot
docker run -d --name=samba --restart=unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NBBN"  -v "/mnt/:/storage" dockurr/samba
network:
  version: 2
  renderer: networkd
  wifis:
    wlp2s0:
      dhcp4: no
      addresses:
        - 192.168.0.124/24  # 这里改成你想要的静态 IP
      gateway4: 192.168.0.8  # 你的网关 IP（通常是路由器 IP）
      nameservers:
        addresses:
          - 211.140.13.188   
          - 114.114.114.114  # 114 DNS
      access-points:
        "boci1":
          password: "a1b2c3d4"

docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
docker run --restart always --name openwrt1 -d --network macnet --privileged --ip 192.168.0.124   openwrt /sbin/init
docker run -d \
  --name=clash \
  -v /root/clash.yaml: /root/.config/clash/config.yaml \
  -p 7890:7890 \
  -p 9090:9090 \
  --restart unless-stopped \
  dreamacro/clash

安装官方最新版本：
curl -fsSL https://get.docker.com | bash
docker import rootfs.tar.gz my-custom-image
docker run -d \
  --name openwrt \
  --network host \
  --privileged \
  openwrt
docker run --restart always --name openwrt -p 80:80 -d --network host --privileged openwrt /sbin/init
允许 ZeroTier 网络访问本地网络
sudo iptables -A FORWARD -s 192.168.192.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 192.168.0.0/24 -d 192.168.192.0/24 -j ACCEPT
如果局域网设备默认网关不是 Ubuntu，需要 NAT
sudo iptables -t nat -A POSTROUTING -s 192.168.192.0/24 -d 192.168.0.0/24 -j MASQUERADE
eroTier 网络
192.168.0.0/24 via 192.168.191.112
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
ip route add 192.168.50.0/24 via 10.8.0.1 dev tun0
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
4.新启动 OpenVPN 服务
systemctl restart openvpn
docker run -d \
  --name=wg-client2 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  -v /mnt/wg0:/etc/wireguard/wg0 \
  weejewel/wg-easy
docker run -d \
  --name=wg-wireguard \
  -e WG_HOST=10.0.0.1 \
  -e PASSWORD= \
  --network host \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
docker run -d \
  --name=wg-easy3 \
  --network host \
  --privileged \
  -e WG_HOST=39.174.229.143 \
  -e PASSWORD= \
  -e WG_PERSISTENT_KEEPALIVE=25 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
network:
  ethernets:
    eth0:  # 请替换为你的实际网卡名称
      dhcp4: no
      addresses:
        - 192.168.0.219/24  # 设置静态 IP
      gateway4: 192.168.0.8  # 设置网关
      nameservers:
        addresses:
          - 211.140.13.188
  version: 2
ip route add 192.168.200.0/24 via 10.8.0.1 dev tun0
iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE
iptables -A FORWARD -i tun0 -o eth1 -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A FORWARD -i eth1 -o tun0 -j ACCEPT


docker run -d \
  --name=wireguard-client \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -v /mnt:/config \
  -v /lib/modules:/lib/modules \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  lscr.io/linuxserver/wireguard:latest

enp1s0    enx00e04c360351
network:
  version: 2
  renderer: networkd
  ethernets:
    eth0:
      dhcp4: yes
      dhcp6: no
    enx00e04c360351:
      addresses:
        - 10.131.61.111/24
      dhcp4: no
sudo iptables -t nat -A POSTROUTING -o enp1s0 -j MASQUERADE
sudo iptables -A FORWARD -i enx00e04c360351 -o enp1s0 -j ACCEPT
sudo iptables -A FORWARD -i enp1s0 -o enx00e04c360351 -m state --state RELATED,ESTABLISHED -j ACCEPT
ip route add 22.8.144.97 via 10.130.61.1 dev enx00e04c360351
ip route add 22.8.144.97 via 10.131.61.1 dev br-lan  
ip route add 22.8.144.97 via 10.0.0.5 dev wireguard 
22.8.144.97
ip route add 22.8.144.97 via 192.168.0.8 dev eth0
39.174.229.143
10.0.0.0/24
uci show firewall | grep '@redirect'
docker run -d \
  --name=transmission \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -p 80:9091 \
  -p 51413:51413 \
  -p 51413:51413/udp \
  -v /home/download:/downloads \
  --restart unless-stopped \
  lscr.io/linuxserver/transmission:latest

docker run --restart always --name openwrt -d --network macnet --privileged --ip 10.1.25.193 ophub/openwrt-aarch64:latest
uci set zerotier.global.enabled='1'
uci delete zerotier.earth
uci set zerotier.openwrt_network=network
uci set zerotier.openwrt_network.id='856127940c66f22d'
uci commit zerotier
ip link set  eth0 promisc on
docker network create -d macvlan --subnet=192.168.50.0/24 --gateway=192.168.50.1 -o parent=br-lan  mynet
docker run  --name openwrt --restart unless-stopped -d --network mynet    --privileged --ip 192.168.50.314  openwrt  /sbin/init
docker run -d \
  --name=resilio-sync \
  -p 8888:8888 \
  -p 55555:55555 \
  -v /mnt/sda1/resilio:/mnt/sync \
  -v /mnt/sda1/resilio-config:/config \
  --restart unless-stopped \
  resilio/sync

[Interface]
PrivateKey = OO5201M+3VC3BpIZY7MGhMbZkIBlmGyzegh5sgWPjVU=
Address = 10.0.8.6/24
DNS = 211.140.13.188


[Peer]
PublicKey = klRBbxYnJUMuKBLewfTwaQdj08w9JoeipgZyhahyynU=
PresharedKey = NNwo3pswYpeHmrZV3aWoHT+aBCUq0VDMVDErAY4Z+7Y=
AllowedIPs = 10.0.8.0/24,10.1.25.0/24
PersistentKeepalive = 25
Endpoint = 39.174.229.143:51820


c0: 20250204202213-2virs7k
c2: update
c3: 复制修改版
c5: 2025-03-15-110234-update/20250204202137-3g13i3l/20250204202213-2virs7k.sy
c6: 1742007754
c4:
通过 iPhone 镜像从 Mac 使用 iPhone
魔兽争霸:https://www.123pan.com/s/nVxFjv-fkwd3.html
dd if=openwrt-24.10.0-armsr-armv8-generic-ext4-combined-efi.img of=/dev/mmcblk2 bs=4M
docker dockerd luci-lib-docker docker-compose
docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
dd if=/dev/sda of=/root/openwrt24.img bs=4M status=progress

docker run -d  -v /mnt/usb1_2-1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d \
  --name=qbittorrent \
  -e PUID=1000 -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -e WEBUI_PORT=8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -p 80:8080 \
  -v /home/qbittorrent/:/downloads \
  --restart unless-stopped \
  linuxserver/qbittorrent

docker run -d \
  --name=qbittorrent \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 1000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

dd if=istoreo.img of=/dev/sda bs=4M
docker run -d --name=xunlei --hostname=NNN1 --net=host -v /mnt/usb1_2-2:/xunlei/data -v /mnt/usb1_2-2:/xunlei/downloads --restart=unless-stopped --privileged cnk3x/xunlei:latest
docker run -d --privileged  -v /mnt/:/xunlei/downloads -p 2345:2345 cnk3x/xunlei
docker run -d -v /mnt/usb1/siyuan:/siyuan/workspace  -e PUID=$UID  -e PGID=$GID  -p 6806:6806 b3log/siyuan  --workspace=/siyuan/workspace/ --accessAuthCode=xxx
docker run -d --name=siyuan -v /mnt/usb1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d --name syncthing  --restart always -p 3000:8384 -p 22000:22000/tcp -p 22000:22000/udp  -p 21027:21027/udp -v /mnt/config-sync:/var/syncthing/config -v /mnt:/var/syncthing/data syncthing/syncthing
docker run -d \
  --name syncthing \
  --restart always \
  -p 8384:8384 \
  -p 22000:22000/tcp \
  -p 22000:22000/udp \
  -p 21027:21027/udp \
  -v /mnt/usb2/syncthing/config:/var/syncthing/config \
  -v /mnt/usb2/syncthing/:/var/syncthing/data \
  syncthing/syncthing
docker run -d --name=samba  --restart unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NNN"  -v "/mnt:/storage" dockurr/samba
opkg install fdisk block-mount unzip zerotier samba4-server samba4-utils luci-app-samba4 openssh-sftp-server openvpn-openssl luci-app-openvpn wireguard-tools kmod-wireguard luci-proto-wireguard
mkdir -p /tmp/introot
mkdir -p /tmp/extroot
mount --bind / /tmp/introot
mount /dev/sda3 /tmp/extroot
tar -C /tmp/introot -cvf - . | tar -C /tmp/extroot -xf -
umount /tmp/introot
umount /tmp/extroot
docker run -d --name=samba --restart=unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NBBN"  -v "/mnt/:/storage" dockurr/samba
network:
  version: 2
  renderer: networkd
  wifis:
    wlp2s0:
      dhcp4: no
      addresses:
        - 192.168.0.124/24  # 这里改成你想要的静态 IP
      gateway4: 192.168.0.8  # 你的网关 IP（通常是路由器 IP）
      nameservers:
        addresses:
          - 211.140.13.188   
          - 114.114.114.114  # 114 DNS
      access-points:
        "boci1":
          password: "a1b2c3d4"

docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
docker run --restart always --name openwrt1 -d --network macnet --privileged --ip 192.168.0.124   openwrt /sbin/init
docker run -d \
  --name=clash \
  -v /root/clash.yaml: /root/.config/clash/config.yaml \
  -p 7890:7890 \
  -p 9090:9090 \
  --restart unless-stopped \
  dreamacro/clash

安装官方最新版本：
curl -fsSL https://get.docker.com | bash
docker import rootfs.tar.gz my-custom-image
docker run -d \
  --name openwrt \
  --network host \
  --privileged \
  openwrt
docker run --restart always --name openwrt -p 80:80 -d --network host --privileged openwrt /sbin/init
允许 ZeroTier 网络访问本地网络
sudo iptables -A FORWARD -s 192.168.192.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 192.168.0.0/24 -d 192.168.192.0/24 -j ACCEPT
如果局域网设备默认网关不是 Ubuntu，需要 NAT
sudo iptables -t nat -A POSTROUTING -s 192.168.192.0/24 -d 192.168.0.0/24 -j MASQUERADE
eroTier 网络
192.168.0.0/24 via 192.168.191.112
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
ip route add 192.168.50.0/24 via 10.8.0.1 dev tun0
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
4.新启动 OpenVPN 服务
systemctl restart openvpn
docker run -d \
  --name=wg-client2 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  -v /mnt/wg0:/etc/wireguard/wg0 \
  weejewel/wg-easy
docker run -d \
  --name=wg-wireguard \
  -e WG_HOST=10.0.0.1 \
  -e PASSWORD= \
  --network host \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
docker run -d \
  --name=wg-easy3 \
  --network host \
  --privileged \
  -e WG_HOST=39.174.229.143 \
  -e PASSWORD= \
  -e WG_PERSISTENT_KEEPALIVE=25 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
network:
  ethernets:
    eth0:  # 请替换为你的实际网卡名称
      dhcp4: no
      addresses:
        - 192.168.0.219/24  # 设置静态 IP
      gateway4: 192.168.0.8  # 设置网关
      nameservers:
        addresses:
          - 211.140.13.188
  version: 2
ip route add 192.168.200.0/24 via 10.8.0.1 dev tun0
iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE
iptables -A FORWARD -i tun0 -o eth1 -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A FORWARD -i eth1 -o tun0 -j ACCEPT


docker run -d \
  --name=wireguard-client \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -v /mnt:/config \
  -v /lib/modules:/lib/modules \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  lscr.io/linuxserver/wireguard:latest

enp1s0    enx00e04c360351
network:
  version: 2
  renderer: networkd
  ethernets:
    eth0:
      dhcp4: yes
      dhcp6: no
    enx00e04c360351:
      addresses:
        - 10.131.61.111/24
      dhcp4: no
sudo iptables -t nat -A POSTROUTING -o enp1s0 -j MASQUERADE
sudo iptables -A FORWARD -i enx00e04c360351 -o enp1s0 -j ACCEPT
sudo iptables -A FORWARD -i enp1s0 -o enx00e04c360351 -m state --state RELATED,ESTABLISHED -j ACCEPT
ip route add 22.8.144.97 via 10.130.61.1 dev enx00e04c360351
ip route add 22.8.144.97 via 10.131.61.1 dev br-lan  
ip route add 22.8.144.97 via 10.0.0.5 dev wireguard 
22.8.144.97
ip route add 22.8.144.97 via 192.168.0.8 dev eth0
39.174.229.143
10.0.0.0/24
uci show firewall | grep '@redirect'
docker run -d \
  --name=transmission \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -p 80:9091 \
  -p 51413:51413 \
  -p 51413:51413/udp \
  -v /home/download:/downloads \
  --restart unless-stopped \
  lscr.io/linuxserver/transmission:latest

docker run --restart always --name openwrt -d --network macnet --privileged --ip 10.1.25.193 ophub/openwrt-aarch64:latest
uci set zerotier.global.enabled='1'
uci delete zerotier.earth
uci set zerotier.openwrt_network=network
uci set zerotier.openwrt_network.id='856127940c66f22d'
uci commit zerotier
ip link set  eth0 promisc on
docker network create -d macvlan --subnet=192.168.50.0/24 --gateway=192.168.50.1 -o parent=br-lan  mynet
docker run  --name openwrt --restart unless-stopped -d --network mynet    --privileged --ip 192.168.50.314  openwrt  /sbin/init
docker run -d \
  --name=resilio-sync \
  -p 8888:8888 \
  -p 55555:55555 \
  -v /mnt/sda1/resilio:/mnt/sync \
  -v /mnt/sda1/resilio-config:/config \
  --restart unless-stopped \
  resilio/sync

[Interface]
PrivateKey = OO5201M+3VC3BpIZY7MGhMbZkIBlmGyzegh5sgWPjVU=
Address = 10.0.8.6/24
DNS = 211.140.13.188


[Peer]
PublicKey = klRBbxYnJUMuKBLewfTwaQdj08w9JoeipgZyhahyynU=
PresharedKey = NNwo3pswYpeHmrZV3aWoHT+aBCUq0VDMVDErAY4Z+7Y=
AllowedIPs = 10.0.8.0/24,10.1.25.0/24
PersistentKeepalive = 25
Endpoint = 39.174.229.143:51820


c0: 20250204202213-2virs7k
c2: update
c3: 复制修改版
c5: 2025-03-15-111234-update/20250204202137-3g13i3l/20250204202213-2virs7k.sy
c6: 1742008354
c4:
通过 iPhone 镜像从 Mac 使用 iPhone
魔兽争霸:https://www.123pan.com/s/nVxFjv-fkwd3.html
dd if=openwrt-24.10.0-armsr-armv8-generic-ext4-combined-efi.img of=/dev/mmcblk2 bs=4M
docker dockerd luci-lib-docker docker-compose
docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
dd if=/dev/sda of=/root/openwrt24.img bs=4M status=progress

docker run -d  -v /mnt/usb1_2-1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d \
  --name=qbittorrent \
  -e PUID=1000 -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -e WEBUI_PORT=8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -p 1000:8080 \
  -v /home/qbittorrent/:/downloads \
  --restart unless-stopped \
  linuxserver/qbittorrent

docker run -d \
  --name=qbittorrent \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 1000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/usb1_2-2:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

dd if=istoreo.img of=/dev/sda bs=4M
docker run -d --name=xunlei --hostname=NNN1 --net=host -v /mnt/usb1_2-2:/xunlei/data -v /mnt/usb1_2-2:/xunlei/downloads --restart=unless-stopped --privileged cnk3x/xunlei:latest
docker run -d --privileged  -v /mnt/:/xunlei/downloads -p 2345:2345 cnk3x/xunlei
docker run -d -v /mnt/usb1/siyuan:/siyuan/workspace  -e PUID=$UID  -e PGID=$GID  -p 6806:6806 b3log/siyuan  --workspace=/siyuan/workspace/ --accessAuthCode=xxx
docker run -d --name=siyuan -v /mnt/usb1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d --name syncthing  --restart always -p 3000:8384 -p 22000:22000/tcp -p 22000:22000/udp  -p 21027:21027/udp -v /mnt/config-sync:/var/syncthing/config -v /mnt:/var/syncthing/data syncthing/syncthing
docker run -d \
  --name syncthing \
  --restart always \
  -p 8384:8384 \
  -p 22000:22000/tcp \
  -p 22000:22000/udp \
  -p 21027:21027/udp \
  -v /mnt/usb2/syncthing/config:/var/syncthing/config \
  -v /mnt/usb2/syncthing/:/var/syncthing/data \
  syncthing/syncthing
docker run -d --name=samba  --restart unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NNN"  -v "/mnt:/storage" dockurr/samba
opkg install fdisk block-mount unzip zerotier samba4-server samba4-utils luci-app-samba4 openssh-sftp-server openvpn-openssl luci-app-openvpn wireguard-tools kmod-wireguard luci-proto-wireguard
mkdir -p /tmp/introot
mkdir -p /tmp/extroot
mount --bind / /tmp/introot
mount /dev/sda3 /tmp/extroot
tar -C /tmp/introot -cvf - . | tar -C /tmp/extroot -xf -
umount /tmp/introot
umount /tmp/extroot
docker run -d --name=samba --restart=unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NBBN"  -v "/mnt/:/storage" dockurr/samba
network:
  version: 2
  renderer: networkd
  wifis:
    wlp2s0:
      dhcp4: no
      addresses:
        - 192.168.0.124/24  # 这里改成你想要的静态 IP
      gateway4: 192.168.0.8  # 你的网关 IP（通常是路由器 IP）
      nameservers:
        addresses:
          - 211.140.13.188   
          - 114.114.114.114  # 114 DNS
      access-points:
        "boci1":
          password: "a1b2c3d4"

docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
docker run --restart always --name openwrt1 -d --network macnet --privileged --ip 192.168.0.124   openwrt /sbin/init
docker run -d \
  --name=clash \
  -v /root/clash.yaml: /root/.config/clash/config.yaml \
  -p 7890:7890 \
  -p 9090:9090 \
  --restart unless-stopped \
  dreamacro/clash

安装官方最新版本：
curl -fsSL https://get.docker.com | bash
docker import rootfs.tar.gz my-custom-image
docker run -d \
  --name openwrt \
  --network host \
  --privileged \
  openwrt
docker run --restart always --name openwrt -p 80:80 -d --network host --privileged openwrt /sbin/init
允许 ZeroTier 网络访问本地网络
sudo iptables -A FORWARD -s 192.168.192.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 192.168.0.0/24 -d 192.168.192.0/24 -j ACCEPT
如果局域网设备默认网关不是 Ubuntu，需要 NAT
sudo iptables -t nat -A POSTROUTING -s 192.168.192.0/24 -d 192.168.0.0/24 -j MASQUERADE
eroTier 网络
192.168.0.0/24 via 192.168.191.112
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
ip route add 192.168.50.0/24 via 10.8.0.1 dev tun0
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
4.新启动 OpenVPN 服务
systemctl restart openvpn
docker run -d \
  --name=wg-client2 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  -v /mnt/wg0:/etc/wireguard/wg0 \
  weejewel/wg-easy
docker run -d \
  --name=wg-wireguard \
  -e WG_HOST=10.0.0.1 \
  -e PASSWORD= \
  --network host \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
docker run -d \
  --name=wg-easy3 \
  --network host \
  --privileged \
  -e WG_HOST=39.174.229.143 \
  -e PASSWORD= \
  -e WG_PERSISTENT_KEEPALIVE=25 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
network:
  ethernets:
    eth0:  # 请替换为你的实际网卡名称
      dhcp4: no
      addresses:
        - 192.168.0.219/24  # 设置静态 IP
      gateway4: 192.168.0.8  # 设置网关
      nameservers:
        addresses:
          - 211.140.13.188
  version: 2
ip route add 192.168.200.0/24 via 10.8.0.1 dev tun0
iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE
iptables -A FORWARD -i tun0 -o eth1 -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A FORWARD -i eth1 -o tun0 -j ACCEPT


docker run -d \
  --name=wireguard-client \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -v /mnt:/config \
  -v /lib/modules:/lib/modules \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  lscr.io/linuxserver/wireguard:latest

enp1s0    enx00e04c360351
network:
  version: 2
  renderer: networkd
  ethernets:
    eth0:
      dhcp4: yes
      dhcp6: no
    enx00e04c360351:
      addresses:
        - 10.131.61.111/24
      dhcp4: no
sudo iptables -t nat -A POSTROUTING -o enp1s0 -j MASQUERADE
sudo iptables -A FORWARD -i enx00e04c360351 -o enp1s0 -j ACCEPT
sudo iptables -A FORWARD -i enp1s0 -o enx00e04c360351 -m state --state RELATED,ESTABLISHED -j ACCEPT
ip route add 22.8.144.97 via 10.130.61.1 dev enx00e04c360351
ip route add 22.8.144.97 via 10.131.61.1 dev br-lan  
ip route add 22.8.144.97 via 10.0.0.5 dev wireguard 
22.8.144.97
ip route add 22.8.144.97 via 192.168.0.8 dev eth0
39.174.229.143
10.0.0.0/24
uci show firewall | grep '@redirect'
docker run -d \
  --name=transmission \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -p 80:9091 \
  -p 51413:51413 \
  -p 51413:51413/udp \
  -v /home/download:/downloads \
  --restart unless-stopped \
  lscr.io/linuxserver/transmission:latest

docker run --restart always --name openwrt -d --network macnet --privileged --ip 10.1.25.193 ophub/openwrt-aarch64:latest
uci set zerotier.global.enabled='1'
uci delete zerotier.earth
uci set zerotier.openwrt_network=network
uci set zerotier.openwrt_network.id='856127940c66f22d'
uci commit zerotier
ip link set  eth0 promisc on
docker network create -d macvlan --subnet=192.168.50.0/24 --gateway=192.168.50.1 -o parent=br-lan  mynet
docker run  --name openwrt --restart unless-stopped -d --network mynet    --privileged --ip 192.168.50.314  openwrt  /sbin/init
docker run -d \
  --name=resilio-sync \
  -p 8888:8888 \
  -p 55555:55555 \
  -v /mnt/sda1/resilio:/mnt/sync \
  -v /mnt/sda1/resilio-config:/config \
  --restart unless-stopped \
  resilio/sync

[Interface]
PrivateKey = OO5201M+3VC3BpIZY7MGhMbZkIBlmGyzegh5sgWPjVU=
Address = 10.0.8.6/24
DNS = 211.140.13.188


[Peer]
PublicKey = klRBbxYnJUMuKBLewfTwaQdj08w9JoeipgZyhahyynU=
PresharedKey = NNwo3pswYpeHmrZV3aWoHT+aBCUq0VDMVDErAY4Z+7Y=
AllowedIPs = 10.0.8.0/24,10.1.25.0/24
PersistentKeepalive = 25
Endpoint = 39.174.229.143:51820


c0: 20250204202213-2virs7k
c2: update
c3: 复制修改版
c5: 2025-03-15-112234-update/20250204202137-3g13i3l/20250204202213-2virs7k.sy
c6: 1742008954
c4:
通过 iPhone 镜像从 Mac 使用 iPhone
魔兽争霸:https://www.123pan.com/s/nVxFjv-fkwd3.html
dd if=openwrt-24.10.0-armsr-armv8-generic-ext4-combined-efi.img of=/dev/mmcblk2 bs=4M
docker dockerd luci-lib-docker docker-compose
docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
dd if=/dev/sda of=/root/openwrt24.img bs=4M status=progress

docker run -d  -v /mnt/usb1_2-1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d \
  --name=qbittorrent \
  -e PUID=1000 -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -e WEBUI_PORT=8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -p 1000:8080 \
  -v /mnt/usb1_2-2/:/downloads \
  --restart unless-stopped \
  linuxserver/qbittorrent

docker run -d \
  --name=qbittorrent \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 1000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/usb1_2-2:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

dd if=istoreo.img of=/dev/sda bs=4M
docker run -d --name=xunlei --hostname=NNN1 --net=host -v /mnt/usb1_2-2:/xunlei/data -v /mnt/usb1_2-2:/xunlei/downloads --restart=unless-stopped --privileged cnk3x/xunlei:latest
docker run -d --privileged  -v /mnt/:/xunlei/downloads -p 2345:2345 cnk3x/xunlei
docker run -d -v /mnt/usb1/siyuan:/siyuan/workspace  -e PUID=$UID  -e PGID=$GID  -p 6806:6806 b3log/siyuan  --workspace=/siyuan/workspace/ --accessAuthCode=xxx
docker run -d --name=siyuan -v /mnt/usb1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d --name syncthing  --restart always -p 3000:8384 -p 22000:22000/tcp -p 22000:22000/udp  -p 21027:21027/udp -v /mnt/config-sync:/var/syncthing/config -v /mnt:/var/syncthing/data syncthing/syncthing
docker run -d \
  --name syncthing \
  --restart always \
  -p 8384:8384 \
  -p 22000:22000/tcp \
  -p 22000:22000/udp \
  -p 21027:21027/udp \
  -v /mnt/usb2/syncthing/config:/var/syncthing/config \
  -v /mnt/usb2/syncthing/:/var/syncthing/data \
  syncthing/syncthing
docker run -d --name=samba  --restart unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NNN"  -v "/mnt:/storage" dockurr/samba
opkg install fdisk block-mount unzip zerotier samba4-server samba4-utils luci-app-samba4 openssh-sftp-server openvpn-openssl luci-app-openvpn wireguard-tools kmod-wireguard luci-proto-wireguard
mkdir -p /tmp/introot
mkdir -p /tmp/extroot
mount --bind / /tmp/introot
mount /dev/sda3 /tmp/extroot
tar -C /tmp/introot -cvf - . | tar -C /tmp/extroot -xf -
umount /tmp/introot
umount /tmp/extroot
docker run -d --name=samba --restart=unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NBBN"  -v "/mnt/:/storage" dockurr/samba
network:
  version: 2
  renderer: networkd
  wifis:
    wlp2s0:
      dhcp4: no
      addresses:
        - 192.168.0.124/24  # 这里改成你想要的静态 IP
      gateway4: 192.168.0.8  # 你的网关 IP（通常是路由器 IP）
      nameservers:
        addresses:
          - 211.140.13.188   
          - 114.114.114.114  # 114 DNS
      access-points:
        "boci1":
          password: "a1b2c3d4"

docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
docker run --restart always --name openwrt1 -d --network macnet --privileged --ip 192.168.0.124   openwrt /sbin/init
docker run -d \
  --name=clash \
  -v /root/clash.yaml: /root/.config/clash/config.yaml \
  -p 7890:7890 \
  -p 9090:9090 \
  --restart unless-stopped \
  dreamacro/clash

安装官方最新版本：
curl -fsSL https://get.docker.com | bash
docker import rootfs.tar.gz my-custom-image
docker run -d \
  --name openwrt \
  --network host \
  --privileged \
  openwrt
docker run --restart always --name openwrt -p 80:80 -d --network host --privileged openwrt /sbin/init
允许 ZeroTier 网络访问本地网络
sudo iptables -A FORWARD -s 192.168.192.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 192.168.0.0/24 -d 192.168.192.0/24 -j ACCEPT
如果局域网设备默认网关不是 Ubuntu，需要 NAT
sudo iptables -t nat -A POSTROUTING -s 192.168.192.0/24 -d 192.168.0.0/24 -j MASQUERADE
eroTier 网络
192.168.0.0/24 via 192.168.191.112
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
ip route add 192.168.50.0/24 via 10.8.0.1 dev tun0
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
4.新启动 OpenVPN 服务
systemctl restart openvpn
docker run -d \
  --name=wg-client2 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  -v /mnt/wg0:/etc/wireguard/wg0 \
  weejewel/wg-easy
docker run -d \
  --name=wg-wireguard \
  -e WG_HOST=10.0.0.1 \
  -e PASSWORD= \
  --network host \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
docker run -d \
  --name=wg-easy3 \
  --network host \
  --privileged \
  -e WG_HOST=39.174.229.143 \
  -e PASSWORD= \
  -e WG_PERSISTENT_KEEPALIVE=25 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
network:
  ethernets:
    eth0:  # 请替换为你的实际网卡名称
      dhcp4: no
      addresses:
        - 192.168.0.219/24  # 设置静态 IP
      gateway4: 192.168.0.8  # 设置网关
      nameservers:
        addresses:
          - 211.140.13.188
  version: 2
ip route add 192.168.200.0/24 via 10.8.0.1 dev tun0
iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE
iptables -A FORWARD -i tun0 -o eth1 -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A FORWARD -i eth1 -o tun0 -j ACCEPT


docker run -d \
  --name=wireguard-client \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -v /mnt:/config \
  -v /lib/modules:/lib/modules \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  lscr.io/linuxserver/wireguard:latest

enp1s0    enx00e04c360351
network:
  version: 2
  renderer: networkd
  ethernets:
    eth0:
      dhcp4: yes
      dhcp6: no
    enx00e04c360351:
      addresses:
        - 10.131.61.111/24
      dhcp4: no
sudo iptables -t nat -A POSTROUTING -o enp1s0 -j MASQUERADE
sudo iptables -A FORWARD -i enx00e04c360351 -o enp1s0 -j ACCEPT
sudo iptables -A FORWARD -i enp1s0 -o enx00e04c360351 -m state --state RELATED,ESTABLISHED -j ACCEPT
ip route add 22.8.144.97 via 10.130.61.1 dev enx00e04c360351
ip route add 22.8.144.97 via 10.131.61.1 dev br-lan  
ip route add 22.8.144.97 via 10.0.0.5 dev wireguard 
22.8.144.97
ip route add 22.8.144.97 via 192.168.0.8 dev eth0
39.174.229.143
10.0.0.0/24
uci show firewall | grep '@redirect'
docker run -d \
  --name=transmission \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -p 80:9091 \
  -p 51413:51413 \
  -p 51413:51413/udp \
  -v /home/download:/downloads \
  --restart unless-stopped \
  lscr.io/linuxserver/transmission:latest

docker run --restart always --name openwrt -d --network macnet --privileged --ip 10.1.25.193 ophub/openwrt-aarch64:latest
uci set zerotier.global.enabled='1'
uci delete zerotier.earth
uci set zerotier.openwrt_network=network
uci set zerotier.openwrt_network.id='856127940c66f22d'
uci commit zerotier
ip link set  eth0 promisc on
docker network create -d macvlan --subnet=192.168.50.0/24 --gateway=192.168.50.1 -o parent=br-lan  mynet
docker run  --name openwrt --restart unless-stopped -d --network mynet    --privileged --ip 192.168.50.314  openwrt  /sbin/init
docker run -d \
  --name=resilio-sync \
  -p 8888:8888 \
  -p 55555:55555 \
  -v /mnt/sda1/resilio:/mnt/sync \
  -v /mnt/sda1/resilio-config:/config \
  --restart unless-stopped \
  resilio/sync

[Interface]
PrivateKey = OO5201M+3VC3BpIZY7MGhMbZkIBlmGyzegh5sgWPjVU=
Address = 10.0.8.6/24
DNS = 211.140.13.188


[Peer]
PublicKey = klRBbxYnJUMuKBLewfTwaQdj08w9JoeipgZyhahyynU=
PresharedKey = NNwo3pswYpeHmrZV3aWoHT+aBCUq0VDMVDErAY4Z+7Y=
AllowedIPs = 10.0.8.0/24,10.1.25.0/24
PersistentKeepalive = 25
Endpoint = 39.174.229.143:51820


c0: 20250204202213-2virs7k
c2: update
c3: 复制修改版
c5: 2025-03-15-113234-update/20250204202137-3g13i3l/20250204202213-2virs7k.sy
c6: 1742009554
c4:
通过 iPhone 镜像从 Mac 使用 iPhone
魔兽争霸:https://www.123pan.com/s/nVxFjv-fkwd3.html
dd if=openwrt-24.10.0-armsr-armv8-generic-ext4-combined-efi.img of=/dev/mmcblk2 bs=4M
docker dockerd luci-lib-docker docker-compose
docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
dd if=/dev/sda of=/root/openwrt24.img bs=4M status=progress

docker run -d  -v /mnt/usb1_2-1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d \
  --name=qbittorrent \
  -e PUID=1000 -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -e WEBUI_PORT=8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -p 1000:8080 \
  -v /mnt/usb1_2-2/:/downloads \
  --restart unless-stopped \
  linuxserver/qbittorrent

docker run -d \
  --name=qbittorrent \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 8080:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/sda2:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

dd if=istoreo.img of=/dev/sda bs=4M
docker run -d --name=xunlei --hostname=NNN1 --net=host -v /mnt/usb1_2-2:/xunlei/data -v /mnt/usb1_2-2:/xunlei/downloads --restart=unless-stopped --privileged cnk3x/xunlei:latest
docker run -d --privileged  -v /mnt/:/xunlei/downloads -p 2345:2345 cnk3x/xunlei
docker run -d -v /mnt/usb1/siyuan:/siyuan/workspace  -e PUID=$UID  -e PGID=$GID  -p 6806:6806 b3log/siyuan  --workspace=/siyuan/workspace/ --accessAuthCode=xxx
docker run -d --name=siyuan -v /mnt/usb1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d --name syncthing  --restart always -p 3000:8384 -p 22000:22000/tcp -p 22000:22000/udp  -p 21027:21027/udp -v /mnt/config-sync:/var/syncthing/config -v /mnt:/var/syncthing/data syncthing/syncthing
docker run -d \
  --name syncthing \
  --restart always \
  -p 8384:8384 \
  -p 22000:22000/tcp \
  -p 22000:22000/udp \
  -p 21027:21027/udp \
  -v /mnt/usb2/syncthing/config:/var/syncthing/config \
  -v /mnt/usb2/syncthing/:/var/syncthing/data \
  syncthing/syncthing
docker run -d --name=samba  --restart unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NNN"  -v "/mnt:/storage" dockurr/samba
opkg install fdisk block-mount unzip zerotier samba4-server samba4-utils luci-app-samba4 openssh-sftp-server openvpn-openssl luci-app-openvpn wireguard-tools kmod-wireguard luci-proto-wireguard
mkdir -p /tmp/introot
mkdir -p /tmp/extroot
mount --bind / /tmp/introot
mount /dev/sda3 /tmp/extroot
tar -C /tmp/introot -cvf - . | tar -C /tmp/extroot -xf -
umount /tmp/introot
umount /tmp/extroot
docker run -d --name=samba --restart=unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NBBN"  -v "/mnt/:/storage" dockurr/samba
network:
  version: 2
  renderer: networkd
  wifis:
    wlp2s0:
      dhcp4: no
      addresses:
        - 192.168.0.124/24  # 这里改成你想要的静态 IP
      gateway4: 192.168.0.8  # 你的网关 IP（通常是路由器 IP）
      nameservers:
        addresses:
          - 211.140.13.188   
          - 114.114.114.114  # 114 DNS
      access-points:
        "boci1":
          password: "a1b2c3d4"

docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
docker run --restart always --name openwrt1 -d --network macnet --privileged --ip 192.168.0.124   openwrt /sbin/init
docker run -d \
  --name=clash \
  -v /root/clash.yaml: /root/.config/clash/config.yaml \
  -p 7890:7890 \
  -p 9090:9090 \
  --restart unless-stopped \
  dreamacro/clash

安装官方最新版本：
curl -fsSL https://get.docker.com | bash
docker import rootfs.tar.gz my-custom-image
docker run -d \
  --name openwrt \
  --network host \
  --privileged \
  openwrt
docker run --restart always --name openwrt -p 80:80 -d --network host --privileged openwrt /sbin/init
允许 ZeroTier 网络访问本地网络
sudo iptables -A FORWARD -s 192.168.192.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 192.168.0.0/24 -d 192.168.192.0/24 -j ACCEPT
如果局域网设备默认网关不是 Ubuntu，需要 NAT
sudo iptables -t nat -A POSTROUTING -s 192.168.192.0/24 -d 192.168.0.0/24 -j MASQUERADE
eroTier 网络
192.168.0.0/24 via 192.168.191.112
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
ip route add 192.168.50.0/24 via 10.8.0.1 dev tun0
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
4.新启动 OpenVPN 服务
systemctl restart openvpn
docker run -d \
  --name=wg-client2 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  -v /mnt/wg0:/etc/wireguard/wg0 \
  weejewel/wg-easy
docker run -d \
  --name=wg-wireguard \
  -e WG_HOST=10.0.0.1 \
  -e PASSWORD= \
  --network host \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
docker run -d \
  --name=wg-easy3 \
  --network host \
  --privileged \
  -e WG_HOST=39.174.229.143 \
  -e PASSWORD= \
  -e WG_PERSISTENT_KEEPALIVE=25 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
network:
  ethernets:
    eth0:  # 请替换为你的实际网卡名称
      dhcp4: no
      addresses:
        - 192.168.0.219/24  # 设置静态 IP
      gateway4: 192.168.0.8  # 设置网关
      nameservers:
        addresses:
          - 211.140.13.188
  version: 2
ip route add 192.168.200.0/24 via 10.8.0.1 dev tun0
iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE
iptables -A FORWARD -i tun0 -o eth1 -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A FORWARD -i eth1 -o tun0 -j ACCEPT


docker run -d \
  --name=wireguard-client \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -v /mnt:/config \
  -v /lib/modules:/lib/modules \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  lscr.io/linuxserver/wireguard:latest

enp1s0    enx00e04c360351
network:
  version: 2
  renderer: networkd
  ethernets:
    eth0:
      dhcp4: yes
      dhcp6: no
    enx00e04c360351:
      addresses:
        - 10.131.61.111/24
      dhcp4: no
sudo iptables -t nat -A POSTROUTING -o enp1s0 -j MASQUERADE
sudo iptables -A FORWARD -i enx00e04c360351 -o enp1s0 -j ACCEPT
sudo iptables -A FORWARD -i enp1s0 -o enx00e04c360351 -m state --state RELATED,ESTABLISHED -j ACCEPT
ip route add 22.8.144.97 via 10.130.61.1 dev enx00e04c360351
ip route add 22.8.144.97 via 10.131.61.1 dev br-lan  
ip route add 22.8.144.97 via 10.0.0.5 dev wireguard 
22.8.144.97
ip route add 22.8.144.97 via 192.168.0.8 dev eth0
39.174.229.143
10.0.0.0/24
uci show firewall | grep '@redirect'
docker run -d \
  --name=transmission \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -p 80:9091 \
  -p 51413:51413 \
  -p 51413:51413/udp \
  -v /home/download:/downloads \
  --restart unless-stopped \
  lscr.io/linuxserver/transmission:latest

docker run --restart always --name openwrt -d --network macnet --privileged --ip 10.1.25.193 ophub/openwrt-aarch64:latest
uci set zerotier.global.enabled='1'
uci delete zerotier.earth
uci set zerotier.openwrt_network=network
uci set zerotier.openwrt_network.id='856127940c66f22d'
uci commit zerotier
ip link set  eth0 promisc on
docker network create -d macvlan --subnet=192.168.50.0/24 --gateway=192.168.50.1 -o parent=br-lan  mynet
docker run  --name openwrt --restart unless-stopped -d --network mynet    --privileged --ip 192.168.50.314  openwrt  /sbin/init
docker run -d \
  --name=resilio-sync \
  -p 8888:8888 \
  -p 55555:55555 \
  -v /mnt/sda1/resilio:/mnt/sync \
  -v /mnt/sda1/resilio-config:/config \
  --restart unless-stopped \
  resilio/sync

[Interface]
PrivateKey = OO5201M+3VC3BpIZY7MGhMbZkIBlmGyzegh5sgWPjVU=
Address = 10.0.8.6/24
DNS = 211.140.13.188


[Peer]
PublicKey = klRBbxYnJUMuKBLewfTwaQdj08w9JoeipgZyhahyynU=
PresharedKey = NNwo3pswYpeHmrZV3aWoHT+aBCUq0VDMVDErAY4Z+7Y=
AllowedIPs = 10.0.8.0/24,10.1.25.0/24
PersistentKeepalive = 25
Endpoint = 39.174.229.143:51820


c0: 20250204202213-2virs7k
c2: update
c3: 复制修改版
c5: 2025-03-15-114234-update/20250204202137-3g13i3l/20250204202213-2virs7k.sy
c6: 1742010154
c4:
通过 iPhone 镜像从 Mac 使用 iPhone
魔兽争霸:https://www.123pan.com/s/nVxFjv-fkwd3.html
dd if=openwrt-24.10.0-armsr-armv8-generic-ext4-combined-efi.img of=/dev/mmcblk2 bs=4M
docker dockerd luci-lib-docker docker-compose
docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
dd if=/dev/sda of=/root/openwrt24.img bs=4M status=progress

docker run -d  -v /mnt/usb1_2-1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d \
  --name=qbittorrent \
  -e PUID=100 -e PGID=100 \
  -e TZ=Asia/Shanghai \
  -e WEBUI_PORT=8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -p 1000:8080 \
  -v /mnt/usb1_2-2/:/downloads \
  --restart unless-stopped \
  linuxserver/qbittorrent

docker run -d \
  --name=qbittorrent \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 8080:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/sda2:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

dd if=istoreo.img of=/dev/sda bs=4M
docker run -d --name=xunlei --hostname=NNN1 --net=host -v /mnt/usb1_2-2:/xunlei/data -v /mnt/usb1_2-2:/xunlei/downloads --restart=unless-stopped --privileged cnk3x/xunlei:latest
docker run -d --privileged  -v /mnt/:/xunlei/downloads -p 2345:2345 cnk3x/xunlei
docker run -d -v /mnt/usb1/siyuan:/siyuan/workspace  -e PUID=$UID  -e PGID=$GID  -p 6806:6806 b3log/siyuan  --workspace=/siyuan/workspace/ --accessAuthCode=xxx
docker run -d --name=siyuan -v /mnt/usb1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d --name syncthing  --restart always -p 3000:8384 -p 22000:22000/tcp -p 22000:22000/udp  -p 21027:21027/udp -v /mnt/config-sync:/var/syncthing/config -v /mnt:/var/syncthing/data syncthing/syncthing
docker run -d \
  --name syncthing \
  --restart always \
  -p 8384:8384 \
  -p 22000:22000/tcp \
  -p 22000:22000/udp \
  -p 21027:21027/udp \
  -v /mnt/usb2/syncthing/config:/var/syncthing/config \
  -v /mnt/usb2/syncthing/:/var/syncthing/data \
  syncthing/syncthing
docker run -d --name=samba  --restart unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NNN"  -v "/mnt:/storage" dockurr/samba
opkg install fdisk block-mount unzip zerotier samba4-server samba4-utils luci-app-samba4 openssh-sftp-server openvpn-openssl luci-app-openvpn wireguard-tools kmod-wireguard luci-proto-wireguard
mkdir -p /tmp/introot
mkdir -p /tmp/extroot
mount --bind / /tmp/introot
mount /dev/sda3 /tmp/extroot
tar -C /tmp/introot -cvf - . | tar -C /tmp/extroot -xf -
umount /tmp/introot
umount /tmp/extroot
docker run -d --name=samba --restart=unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NBBN"  -v "/mnt/:/storage" dockurr/samba
network:
  version: 2
  renderer: networkd
  wifis:
    wlp2s0:
      dhcp4: no
      addresses:
        - 192.168.0.124/24  # 这里改成你想要的静态 IP
      gateway4: 192.168.0.8  # 你的网关 IP（通常是路由器 IP）
      nameservers:
        addresses:
          - 211.140.13.188   
          - 114.114.114.114  # 114 DNS
      access-points:
        "boci1":
          password: "a1b2c3d4"

docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
docker run --restart always --name openwrt1 -d --network macnet --privileged --ip 192.168.0.124   openwrt /sbin/init
docker run -d \
  --name=clash \
  -v /root/clash.yaml: /root/.config/clash/config.yaml \
  -p 7890:7890 \
  -p 9090:9090 \
  --restart unless-stopped \
  dreamacro/clash

安装官方最新版本：
curl -fsSL https://get.docker.com | bash
docker import rootfs.tar.gz my-custom-image
docker run -d \
  --name openwrt \
  --network host \
  --privileged \
  openwrt
docker run --restart always --name openwrt -p 80:80 -d --network host --privileged openwrt /sbin/init
允许 ZeroTier 网络访问本地网络
sudo iptables -A FORWARD -s 192.168.192.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 192.168.0.0/24 -d 192.168.192.0/24 -j ACCEPT
如果局域网设备默认网关不是 Ubuntu，需要 NAT
sudo iptables -t nat -A POSTROUTING -s 192.168.192.0/24 -d 192.168.0.0/24 -j MASQUERADE
eroTier 网络
192.168.0.0/24 via 192.168.191.112
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
ip route add 192.168.50.0/24 via 10.8.0.1 dev tun0
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
4.新启动 OpenVPN 服务
systemctl restart openvpn
docker run -d \
  --name=wg-client2 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  -v /mnt/wg0:/etc/wireguard/wg0 \
  weejewel/wg-easy
docker run -d \
  --name=wg-wireguard \
  -e WG_HOST=10.0.0.1 \
  -e PASSWORD= \
  --network host \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
docker run -d \
  --name=wg-easy3 \
  --network host \
  --privileged \
  -e WG_HOST=39.174.229.143 \
  -e PASSWORD= \
  -e WG_PERSISTENT_KEEPALIVE=25 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
network:
  ethernets:
    eth0:  # 请替换为你的实际网卡名称
      dhcp4: no
      addresses:
        - 192.168.0.219/24  # 设置静态 IP
      gateway4: 192.168.0.8  # 设置网关
      nameservers:
        addresses:
          - 211.140.13.188
  version: 2
ip route add 192.168.200.0/24 via 10.8.0.1 dev tun0
iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE
iptables -A FORWARD -i tun0 -o eth1 -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A FORWARD -i eth1 -o tun0 -j ACCEPT


docker run -d \
  --name=wireguard-client \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -v /mnt:/config \
  -v /lib/modules:/lib/modules \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  lscr.io/linuxserver/wireguard:latest

enp1s0    enx00e04c360351
network:
  version: 2
  renderer: networkd
  ethernets:
    eth0:
      dhcp4: yes
      dhcp6: no
    enx00e04c360351:
      addresses:
        - 10.131.61.111/24
      dhcp4: no
sudo iptables -t nat -A POSTROUTING -o enp1s0 -j MASQUERADE
sudo iptables -A FORWARD -i enx00e04c360351 -o enp1s0 -j ACCEPT
sudo iptables -A FORWARD -i enp1s0 -o enx00e04c360351 -m state --state RELATED,ESTABLISHED -j ACCEPT
ip route add 22.8.144.97 via 10.130.61.1 dev enx00e04c360351
ip route add 22.8.144.97 via 10.131.61.1 dev br-lan  
ip route add 22.8.144.97 via 10.0.0.5 dev wireguard 
22.8.144.97
ip route add 22.8.144.97 via 192.168.0.8 dev eth0
39.174.229.143
10.0.0.0/24
uci show firewall | grep '@redirect'
docker run -d \
  --name=transmission \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -p 80:9091 \
  -p 51413:51413 \
  -p 51413:51413/udp \
  -v /home/download:/downloads \
  --restart unless-stopped \
  lscr.io/linuxserver/transmission:latest

docker run --restart always --name openwrt -d --network macnet --privileged --ip 10.1.25.193 ophub/openwrt-aarch64:latest
uci set zerotier.global.enabled='1'
uci delete zerotier.earth
uci set zerotier.openwrt_network=network
uci set zerotier.openwrt_network.id='856127940c66f22d'
uci commit zerotier
ip link set  eth0 promisc on
docker network create -d macvlan --subnet=192.168.50.0/24 --gateway=192.168.50.1 -o parent=br-lan  mynet
docker run  --name openwrt --restart unless-stopped -d --network mynet    --privileged --ip 192.168.50.314  openwrt  /sbin/init
docker run -d \
  --name=resilio-sync \
  -p 8888:8888 \
  -p 55555:55555 \
  -v /mnt/sda1/resilio:/mnt/sync \
  -v /mnt/sda1/resilio-config:/config \
  --restart unless-stopped \
  resilio/sync

[Interface]
PrivateKey = OO5201M+3VC3BpIZY7MGhMbZkIBlmGyzegh5sgWPjVU=
Address = 10.0.8.6/24
DNS = 211.140.13.188


[Peer]
PublicKey = klRBbxYnJUMuKBLewfTwaQdj08w9JoeipgZyhahyynU=
PresharedKey = NNwo3pswYpeHmrZV3aWoHT+aBCUq0VDMVDErAY4Z+7Y=
AllowedIPs = 10.0.8.0/24,10.1.25.0/24
PersistentKeepalive = 25
Endpoint = 39.174.229.143:51820


c0: 20250204202213-2virs7k
c2: update
c3: 复制修改版
c5: 2025-03-15-145234-update/20250204202137-3g13i3l/20250204202213-2virs7k.sy
c6: 1742021554
c4:
通过 iPhone 镜像从 Mac 使用 iPhone
魔兽争霸:https://www.123pan.com/s/nVxFjv-fkwd3.html
dd if=openwrt-24.10.0-armsr-armv8-generic-ext4-combined-efi.img of=/dev/mmcblk2 bs=4M
docker dockerd luci-lib-docker docker-compose
docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
dd if=/dev/sda of=/root/openwrt24.img bs=4M status=progress

docker run -d  -v /mnt/usb1_2-1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d \
  --name=qbittorrent \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 8080:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /path/to/qbittorrent/appdata:/config \
  -v /path/to/downloads:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

docker run -d \
  --name=qbittorrent \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 1000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/usb1_2-1/download:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

dd if=istoreo.img of=/dev/sda bs=4M
docker run -d --name=xunlei --hostname=NNN1 --net=host -v /mnt/usb1_2-2:/xunlei/data -v /mnt/usb1_2-2:/xunlei/downloads --restart=unless-stopped --privileged cnk3x/xunlei:latest
docker run -d --privileged  -v /mnt/:/xunlei/downloads -p 2345:2345 cnk3x/xunlei
docker run -d -v /mnt/usb1/siyuan:/siyuan/workspace  -e PUID=$UID  -e PGID=$GID  -p 6806:6806 b3log/siyuan  --workspace=/siyuan/workspace/ --accessAuthCode=xxx
docker run -d --name=siyuan -v /mnt/usb1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d --name syncthing  --restart always -p 3000:8384 -p 22000:22000/tcp -p 22000:22000/udp  -p 21027:21027/udp -v /mnt/config-sync:/var/syncthing/config -v /mnt:/var/syncthing/data syncthing/syncthing
docker run -d \
  --name syncthing \
  --restart always \
  -p 8384:8384 \
  -p 22000:22000/tcp \
  -p 22000:22000/udp \
  -p 21027:21027/udp \
  -v /mnt/usb2/syncthing/config:/var/syncthing/config \
  -v /mnt/usb2/syncthing/:/var/syncthing/data \
  syncthing/syncthing
docker run -d --name=samba  --restart unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NNN"  -v "/mnt:/storage" dockurr/samba
opkg install fdisk block-mount unzip zerotier samba4-server samba4-utils luci-app-samba4 openssh-sftp-server openvpn-openssl luci-app-openvpn wireguard-tools kmod-wireguard luci-proto-wireguard
mkdir -p /tmp/introot
mkdir -p /tmp/extroot
mount --bind / /tmp/introot
mount /dev/sda3 /tmp/extroot
tar -C /tmp/introot -cvf - . | tar -C /tmp/extroot -xf -
umount /tmp/introot
umount /tmp/extroot
docker run -d --name=samba --restart=unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NBBN"  -v "/mnt/:/storage" dockurr/samba
network:
  version: 2
  renderer: networkd
  wifis:
    wlp2s0:
      dhcp4: no
      addresses:
        - 192.168.0.124/24  # 这里改成你想要的静态 IP
      gateway4: 192.168.0.8  # 你的网关 IP（通常是路由器 IP）
      nameservers:
        addresses:
          - 211.140.13.188   
          - 114.114.114.114  # 114 DNS
      access-points:
        "boci1":
          password: "a1b2c3d4"

docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
docker run --restart always --name openwrt1 -d --network macnet --privileged --ip 192.168.0.124   openwrt /sbin/init
docker run -d \
  --name=clash \
  -v /root/clash.yaml: /root/.config/clash/config.yaml \
  -p 7890:7890 \
  -p 9090:9090 \
  --restart unless-stopped \
  dreamacro/clash

安装官方最新版本：
curl -fsSL https://get.docker.com | bash
docker import rootfs.tar.gz my-custom-image
docker run -d \
  --name openwrt \
  --network host \
  --privileged \
  openwrt
docker run --restart always --name openwrt -p 80:80 -d --network host --privileged openwrt /sbin/init
允许 ZeroTier 网络访问本地网络
sudo iptables -A FORWARD -s 192.168.192.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 192.168.0.0/24 -d 192.168.192.0/24 -j ACCEPT
如果局域网设备默认网关不是 Ubuntu，需要 NAT
sudo iptables -t nat -A POSTROUTING -s 192.168.192.0/24 -d 192.168.0.0/24 -j MASQUERADE
eroTier 网络
192.168.0.0/24 via 192.168.191.112
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
ip route add 192.168.50.0/24 via 10.8.0.1 dev tun0
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
4.新启动 OpenVPN 服务
systemctl restart openvpn
docker run -d \
  --name=wg-client2 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  -v /mnt/wg0:/etc/wireguard/wg0 \
  weejewel/wg-easy
docker run -d \
  --name=wg-wireguard \
  -e WG_HOST=10.0.0.1 \
  -e PASSWORD= \
  --network host \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
docker run -d \
  --name=wg-easy3 \
  --network host \
  --privileged \
  -e WG_HOST=39.174.229.143 \
  -e PASSWORD= \
  -e WG_PERSISTENT_KEEPALIVE=25 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
network:
  ethernets:
    eth0:  # 请替换为你的实际网卡名称
      dhcp4: no
      addresses:
        - 192.168.0.219/24  # 设置静态 IP
      gateway4: 192.168.0.8  # 设置网关
      nameservers:
        addresses:
          - 211.140.13.188
  version: 2
ip route add 192.168.200.0/24 via 10.8.0.1 dev tun0
iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE
iptables -A FORWARD -i tun0 -o eth1 -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A FORWARD -i eth1 -o tun0 -j ACCEPT


docker run -d \
  --name=wireguard-client \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -v /mnt:/config \
  -v /lib/modules:/lib/modules \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  lscr.io/linuxserver/wireguard:latest

enp1s0    enx00e04c360351
network:
  version: 2
  renderer: networkd
  ethernets:
    eth0:
      dhcp4: yes
      dhcp6: no
    enx00e04c360351:
      addresses:
        - 10.131.61.111/24
      dhcp4: no
sudo iptables -t nat -A POSTROUTING -o enp1s0 -j MASQUERADE
sudo iptables -A FORWARD -i enx00e04c360351 -o enp1s0 -j ACCEPT
sudo iptables -A FORWARD -i enp1s0 -o enx00e04c360351 -m state --state RELATED,ESTABLISHED -j ACCEPT
ip route add 22.8.144.97 via 10.130.61.1 dev enx00e04c360351
ip route add 22.8.144.97 via 10.131.61.1 dev br-lan  
ip route add 22.8.144.97 via 10.0.0.5 dev wireguard 
22.8.144.97
ip route add 22.8.144.97 via 192.168.0.8 dev eth0
39.174.229.143
10.0.0.0/24
uci show firewall | grep '@redirect'
docker run -d \
  --name=transmission \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -p 80:9091 \
  -p 51413:51413 \
  -p 51413:51413/udp \
  -v /home/download:/downloads \
  --restart unless-stopped \
  lscr.io/linuxserver/transmission:latest

docker run --restart always --name openwrt -d --network macnet --privileged --ip 10.1.25.193 ophub/openwrt-aarch64:latest
uci set zerotier.global.enabled='1'
uci delete zerotier.earth
uci set zerotier.openwrt_network=network
uci set zerotier.openwrt_network.id='856127940c66f22d'
uci commit zerotier
ip link set  eth0 promisc on
docker network create -d macvlan --subnet=192.168.50.0/24 --gateway=192.168.50.1 -o parent=br-lan  mynet
docker run  --name openwrt --restart unless-stopped -d --network mynet    --privileged --ip 192.168.50.314  openwrt  /sbin/init
docker run -d \
  --name=resilio-sync \
  -p 8888:8888 \
  -p 55555:55555 \
  -v /mnt/sda1/resilio:/mnt/sync \
  -v /mnt/sda1/resilio-config:/config \
  --restart unless-stopped \
  resilio/sync

[Interface]
PrivateKey = OO5201M+3VC3BpIZY7MGhMbZkIBlmGyzegh5sgWPjVU=
Address = 10.0.8.6/24
DNS = 211.140.13.188


[Peer]
PublicKey = klRBbxYnJUMuKBLewfTwaQdj08w9JoeipgZyhahyynU=
PresharedKey = NNwo3pswYpeHmrZV3aWoHT+aBCUq0VDMVDErAY4Z+7Y=
AllowedIPs = 10.0.8.0/24,10.1.25.0/24
PersistentKeepalive = 25
Endpoint = 39.174.229.143:51820


c0: 20250204202213-2virs7k
c2: update
c3: 复制修改版
c5: 2025-03-15-150234-update/20250204202137-3g13i3l/20250204202213-2virs7k.sy
c6: 1742022154
c4:
通过 iPhone 镜像从 Mac 使用 iPhone
魔兽争霸:https://www.123pan.com/s/nVxFjv-fkwd3.html
dd if=openwrt-24.10.0-armsr-armv8-generic-ext4-combined-efi.img of=/dev/mmcblk2 bs=4M
docker dockerd luci-lib-docker docker-compose
docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
dd if=/dev/sda of=/root/openwrt24.img bs=4M status=progress

docker run -d  -v /mnt/usb1_2-1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d \
  --name=qbittorrent \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 1000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/usb1_2-1:/config \
  -v /mnt/usb1_2-1/downloads:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

docker run -d \
  --name=qbittorrent \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 1000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/usb1_2-1/download:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

dd if=istoreo.img of=/dev/sda bs=4M
docker run -d --name=xunlei --hostname=NNN1 --net=host -v /mnt/usb1_2-2:/xunlei/data -v /mnt/usb1_2-2:/xunlei/downloads --restart=unless-stopped --privileged cnk3x/xunlei:latest
docker run -d --privileged  -v /mnt/:/xunlei/downloads -p 2345:2345 cnk3x/xunlei
docker run -d -v /mnt/usb1/siyuan:/siyuan/workspace  -e PUID=$UID  -e PGID=$GID  -p 6806:6806 b3log/siyuan  --workspace=/siyuan/workspace/ --accessAuthCode=xxx
docker run -d --name=siyuan -v /mnt/usb1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d --name syncthing  --restart always -p 3000:8384 -p 22000:22000/tcp -p 22000:22000/udp  -p 21027:21027/udp -v /mnt/config-sync:/var/syncthing/config -v /mnt:/var/syncthing/data syncthing/syncthing
docker run -d \
  --name syncthing \
  --restart always \
  -p 8384:8384 \
  -p 22000:22000/tcp \
  -p 22000:22000/udp \
  -p 21027:21027/udp \
  -v /mnt/usb2/syncthing/config:/var/syncthing/config \
  -v /mnt/usb2/syncthing/:/var/syncthing/data \
  syncthing/syncthing
docker run -d --name=samba  --restart unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NNN"  -v "/mnt:/storage" dockurr/samba
opkg install fdisk block-mount unzip zerotier samba4-server samba4-utils luci-app-samba4 openssh-sftp-server openvpn-openssl luci-app-openvpn wireguard-tools kmod-wireguard luci-proto-wireguard
mkdir -p /tmp/introot
mkdir -p /tmp/extroot
mount --bind / /tmp/introot
mount /dev/sda3 /tmp/extroot
tar -C /tmp/introot -cvf - . | tar -C /tmp/extroot -xf -
umount /tmp/introot
umount /tmp/extroot
docker run -d --name=samba --restart=unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NBBN"  -v "/mnt/:/storage" dockurr/samba
network:
  version: 2
  renderer: networkd
  wifis:
    wlp2s0:
      dhcp4: no
      addresses:
        - 192.168.0.124/24  # 这里改成你想要的静态 IP
      gateway4: 192.168.0.8  # 你的网关 IP（通常是路由器 IP）
      nameservers:
        addresses:
          - 211.140.13.188   
          - 114.114.114.114  # 114 DNS
      access-points:
        "boci1":
          password: "a1b2c3d4"

docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
docker run --restart always --name openwrt1 -d --network macnet --privileged --ip 192.168.0.124   openwrt /sbin/init
docker run -d \
  --name=clash \
  -v /root/clash.yaml: /root/.config/clash/config.yaml \
  -p 7890:7890 \
  -p 9090:9090 \
  --restart unless-stopped \
  dreamacro/clash

安装官方最新版本：
curl -fsSL https://get.docker.com | bash
docker import rootfs.tar.gz my-custom-image
docker run -d \
  --name openwrt \
  --network host \
  --privileged \
  openwrt
docker run --restart always --name openwrt -p 80:80 -d --network host --privileged openwrt /sbin/init
允许 ZeroTier 网络访问本地网络
sudo iptables -A FORWARD -s 192.168.192.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 192.168.0.0/24 -d 192.168.192.0/24 -j ACCEPT
如果局域网设备默认网关不是 Ubuntu，需要 NAT
sudo iptables -t nat -A POSTROUTING -s 192.168.192.0/24 -d 192.168.0.0/24 -j MASQUERADE
eroTier 网络
192.168.0.0/24 via 192.168.191.112
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
ip route add 192.168.50.0/24 via 10.8.0.1 dev tun0
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
4.新启动 OpenVPN 服务
systemctl restart openvpn
docker run -d \
  --name=wg-client2 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  -v /mnt/wg0:/etc/wireguard/wg0 \
  weejewel/wg-easy
docker run -d \
  --name=wg-wireguard \
  -e WG_HOST=10.0.0.1 \
  -e PASSWORD= \
  --network host \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
docker run -d \
  --name=wg-easy3 \
  --network host \
  --privileged \
  -e WG_HOST=39.174.229.143 \
  -e PASSWORD= \
  -e WG_PERSISTENT_KEEPALIVE=25 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
network:
  ethernets:
    eth0:  # 请替换为你的实际网卡名称
      dhcp4: no
      addresses:
        - 192.168.0.219/24  # 设置静态 IP
      gateway4: 192.168.0.8  # 设置网关
      nameservers:
        addresses:
          - 211.140.13.188
  version: 2
ip route add 192.168.200.0/24 via 10.8.0.1 dev tun0
iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE
iptables -A FORWARD -i tun0 -o eth1 -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A FORWARD -i eth1 -o tun0 -j ACCEPT


docker run -d \
  --name=wireguard-client \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -v /mnt:/config \
  -v /lib/modules:/lib/modules \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  lscr.io/linuxserver/wireguard:latest

enp1s0    enx00e04c360351
network:
  version: 2
  renderer: networkd
  ethernets:
    eth0:
      dhcp4: yes
      dhcp6: no
    enx00e04c360351:
      addresses:
        - 10.131.61.111/24
      dhcp4: no
sudo iptables -t nat -A POSTROUTING -o enp1s0 -j MASQUERADE
sudo iptables -A FORWARD -i enx00e04c360351 -o enp1s0 -j ACCEPT
sudo iptables -A FORWARD -i enp1s0 -o enx00e04c360351 -m state --state RELATED,ESTABLISHED -j ACCEPT
ip route add 22.8.144.97 via 10.130.61.1 dev enx00e04c360351
ip route add 22.8.144.97 via 10.131.61.1 dev br-lan  
ip route add 22.8.144.97 via 10.0.0.5 dev wireguard 
22.8.144.97
ip route add 22.8.144.97 via 192.168.0.8 dev eth0
39.174.229.143
10.0.0.0/24
uci show firewall | grep '@redirect'
docker run -d \
  --name=transmission \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -p 80:9091 \
  -p 51413:51413 \
  -p 51413:51413/udp \
  -v /home/download:/downloads \
  --restart unless-stopped \
  lscr.io/linuxserver/transmission:latest

docker run --restart always --name openwrt -d --network macnet --privileged --ip 10.1.25.193 ophub/openwrt-aarch64:latest
uci set zerotier.global.enabled='1'
uci delete zerotier.earth
uci set zerotier.openwrt_network=network
uci set zerotier.openwrt_network.id='856127940c66f22d'
uci commit zerotier
ip link set  eth0 promisc on
docker network create -d macvlan --subnet=192.168.50.0/24 --gateway=192.168.50.1 -o parent=br-lan  mynet
docker run  --name openwrt --restart unless-stopped -d --network mynet    --privileged --ip 192.168.50.314  openwrt  /sbin/init
docker run -d \
  --name=resilio-sync \
  -p 8888:8888 \
  -p 55555:55555 \
  -v /mnt/sda1/resilio:/mnt/sync \
  -v /mnt/sda1/resilio-config:/config \
  --restart unless-stopped \
  resilio/sync

[Interface]
PrivateKey = OO5201M+3VC3BpIZY7MGhMbZkIBlmGyzegh5sgWPjVU=
Address = 10.0.8.6/24
DNS = 211.140.13.188


[Peer]
PublicKey = klRBbxYnJUMuKBLewfTwaQdj08w9JoeipgZyhahyynU=
PresharedKey = NNwo3pswYpeHmrZV3aWoHT+aBCUq0VDMVDErAY4Z+7Y=
AllowedIPs = 10.0.8.0/24,10.1.25.0/24
PersistentKeepalive = 25
Endpoint = 39.174.229.143:51820


c0: 20250204202213-2virs7k
c2: update
c3: 复制修改版
c5: 2025-03-15-151234-update/20250204202137-3g13i3l/20250204202213-2virs7k.sy
c6: 1742022754
c4:
通过 iPhone 镜像从 Mac 使用 iPhone
魔兽争霸:https://www.123pan.com/s/nVxFjv-fkwd3.html
dd if=openwrt-24.10.0-armsr-armv8-generic-ext4-combined-efi.img of=/dev/mmcblk2 bs=4M
docker dockerd luci-lib-docker docker-compose
docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
dd if=/dev/sda of=/root/openwrt24.img bs=4M status=progress

docker run -d  -v /mnt/usb1_2-1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d \
  --name=qbittorrent \
  -e PUID=0 \
  -e PGID=0 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 1000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/usb1_2-1:/config \
  -v /mnt/usb1_2-1/download:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

docker run -d \
  --name=qbittorrent \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 1000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/usb1_2-1/download:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

dd if=istoreo.img of=/dev/sda bs=4M
docker run -d --name=xunlei --hostname=NNN1 --net=host -v /mnt/usb1_2-2:/xunlei/data -v /mnt/usb1_2-2:/xunlei/downloads --restart=unless-stopped --privileged cnk3x/xunlei:latest
docker run -d --privileged  -v /mnt/:/xunlei/downloads -p 2345:2345 cnk3x/xunlei
docker run -d -v /mnt/usb1/siyuan:/siyuan/workspace  -e PUID=$UID  -e PGID=$GID  -p 6806:6806 b3log/siyuan  --workspace=/siyuan/workspace/ --accessAuthCode=xxx
docker run -d --name=siyuan -v /mnt/usb1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d --name syncthing  --restart always -p 3000:8384 -p 22000:22000/tcp -p 22000:22000/udp  -p 21027:21027/udp -v /mnt/config-sync:/var/syncthing/config -v /mnt:/var/syncthing/data syncthing/syncthing
docker run -d \
  --name syncthing \
  --restart always \
  -p 8384:8384 \
  -p 22000:22000/tcp \
  -p 22000:22000/udp \
  -p 21027:21027/udp \
  -v /mnt/usb2/syncthing/config:/var/syncthing/config \
  -v /mnt/usb2/syncthing/:/var/syncthing/data \
  syncthing/syncthing
docker run -d --name=samba  --restart unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NNN"  -v "/mnt:/storage" dockurr/samba
opkg install fdisk block-mount unzip zerotier samba4-server samba4-utils luci-app-samba4 openssh-sftp-server openvpn-openssl luci-app-openvpn wireguard-tools kmod-wireguard luci-proto-wireguard
mkdir -p /tmp/introot
mkdir -p /tmp/extroot
mount --bind / /tmp/introot
mount /dev/sda3 /tmp/extroot
tar -C /tmp/introot -cvf - . | tar -C /tmp/extroot -xf -
umount /tmp/introot
umount /tmp/extroot
docker run -d --name=samba --restart=unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NBBN"  -v "/mnt/:/storage" dockurr/samba
network:
  version: 2
  renderer: networkd
  wifis:
    wlp2s0:
      dhcp4: no
      addresses:
        - 192.168.0.124/24  # 这里改成你想要的静态 IP
      gateway4: 192.168.0.8  # 你的网关 IP（通常是路由器 IP）
      nameservers:
        addresses:
          - 211.140.13.188   
          - 114.114.114.114  # 114 DNS
      access-points:
        "boci1":
          password: "a1b2c3d4"

docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
docker run --restart always --name openwrt1 -d --network macnet --privileged --ip 192.168.0.124   openwrt /sbin/init
docker run -d \
  --name=clash \
  -v /root/clash.yaml: /root/.config/clash/config.yaml \
  -p 7890:7890 \
  -p 9090:9090 \
  --restart unless-stopped \
  dreamacro/clash

安装官方最新版本：
curl -fsSL https://get.docker.com | bash
docker import rootfs.tar.gz my-custom-image
docker run -d \
  --name openwrt \
  --network host \
  --privileged \
  openwrt
docker run --restart always --name openwrt -p 80:80 -d --network host --privileged openwrt /sbin/init
允许 ZeroTier 网络访问本地网络
sudo iptables -A FORWARD -s 192.168.192.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 192.168.0.0/24 -d 192.168.192.0/24 -j ACCEPT
如果局域网设备默认网关不是 Ubuntu，需要 NAT
sudo iptables -t nat -A POSTROUTING -s 192.168.192.0/24 -d 192.168.0.0/24 -j MASQUERADE
eroTier 网络
192.168.0.0/24 via 192.168.191.112
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
ip route add 192.168.50.0/24 via 10.8.0.1 dev tun0
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
4.新启动 OpenVPN 服务
systemctl restart openvpn
docker run -d \
  --name=wg-client2 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  -v /mnt/wg0:/etc/wireguard/wg0 \
  weejewel/wg-easy
docker run -d \
  --name=wg-wireguard \
  -e WG_HOST=10.0.0.1 \
  -e PASSWORD= \
  --network host \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
docker run -d \
  --name=wg-easy3 \
  --network host \
  --privileged \
  -e WG_HOST=39.174.229.143 \
  -e PASSWORD= \
  -e WG_PERSISTENT_KEEPALIVE=25 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
network:
  ethernets:
    eth0:  # 请替换为你的实际网卡名称
      dhcp4: no
      addresses:
        - 192.168.0.219/24  # 设置静态 IP
      gateway4: 192.168.0.8  # 设置网关
      nameservers:
        addresses:
          - 211.140.13.188
  version: 2
ip route add 192.168.200.0/24 via 10.8.0.1 dev tun0
iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE
iptables -A FORWARD -i tun0 -o eth1 -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A FORWARD -i eth1 -o tun0 -j ACCEPT


docker run -d \
  --name=wireguard-client \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -v /mnt:/config \
  -v /lib/modules:/lib/modules \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  lscr.io/linuxserver/wireguard:latest

enp1s0    enx00e04c360351
network:
  version: 2
  renderer: networkd
  ethernets:
    eth0:
      dhcp4: yes
      dhcp6: no
    enx00e04c360351:
      addresses:
        - 10.131.61.111/24
      dhcp4: no
sudo iptables -t nat -A POSTROUTING -o enp1s0 -j MASQUERADE
sudo iptables -A FORWARD -i enx00e04c360351 -o enp1s0 -j ACCEPT
sudo iptables -A FORWARD -i enp1s0 -o enx00e04c360351 -m state --state RELATED,ESTABLISHED -j ACCEPT
ip route add 22.8.144.97 via 10.130.61.1 dev enx00e04c360351
ip route add 22.8.144.97 via 10.131.61.1 dev br-lan  
ip route add 22.8.144.97 via 10.0.0.5 dev wireguard 
22.8.144.97
ip route add 22.8.144.97 via 192.168.0.8 dev eth0
39.174.229.143
10.0.0.0/24
uci show firewall | grep '@redirect'
docker run -d \
  --name=transmission \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -p 80:9091 \
  -p 51413:51413 \
  -p 51413:51413/udp \
  -v /home/download:/downloads \
  --restart unless-stopped \
  lscr.io/linuxserver/transmission:latest

docker run --restart always --name openwrt -d --network macnet --privileged --ip 10.1.25.193 ophub/openwrt-aarch64:latest
uci set zerotier.global.enabled='1'
uci delete zerotier.earth
uci set zerotier.openwrt_network=network
uci set zerotier.openwrt_network.id='856127940c66f22d'
uci commit zerotier
ip link set  eth0 promisc on
docker network create -d macvlan --subnet=192.168.50.0/24 --gateway=192.168.50.1 -o parent=br-lan  mynet
docker run  --name openwrt --restart unless-stopped -d --network mynet    --privileged --ip 192.168.50.314  openwrt  /sbin/init
docker run -d \
  --name=resilio-sync \
  -p 8888:8888 \
  -p 55555:55555 \
  -v /mnt/sda1/resilio:/mnt/sync \
  -v /mnt/sda1/resilio-config:/config \
  --restart unless-stopped \
  resilio/sync

[Interface]
PrivateKey = OO5201M+3VC3BpIZY7MGhMbZkIBlmGyzegh5sgWPjVU=
Address = 10.0.8.6/24
DNS = 211.140.13.188


[Peer]
PublicKey = klRBbxYnJUMuKBLewfTwaQdj08w9JoeipgZyhahyynU=
PresharedKey = NNwo3pswYpeHmrZV3aWoHT+aBCUq0VDMVDErAY4Z+7Y=
AllowedIPs = 10.0.8.0/24,10.1.25.0/24
PersistentKeepalive = 25
Endpoint = 39.174.229.143:51820


c0: 20250204202213-2virs7k
c2: update
c3: 复制修改版
c5: 2025-03-15-152234-update/20250204202137-3g13i3l/20250204202213-2virs7k.sy
c6: 1742023354
c4:
通过 iPhone 镜像从 Mac 使用 iPhone
魔兽争霸:https://www.123pan.com/s/nVxFjv-fkwd3.html
dd if=openwrt-24.10.0-armsr-armv8-generic-ext4-combined-efi.img of=/dev/mmcblk2 bs=4M
docker dockerd luci-lib-docker docker-compose
docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
dd if=/dev/sda of=/root/openwrt24.img bs=4M status=progress

docker run -d  -v /mnt/usb1_2-1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d \
  --name=qbittorrent \
  -e PUID=0 \
  -e PGID=0 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 1000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/usb1_2-1:/config \
  -v /mnt/usb1_2-1/download:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

docker run -d \
  --name=qbittorrent \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 1000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/usb1_2-1/download:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

dd if=istoreo.img of=/dev/sda bs=4M
docker run -d --name=xunlei --hostname=NNN1 --net=host -v /mnt/usb1_2-1:/xunlei/config-xunl -v /mnt/usb1_2-1:/xunlei/downloads --restart=unless-stopped --privileged cnk3x/xunlei:latest
docker run -d --privileged  -v /mnt/:/xunlei/downloads -p 2345:2345 cnk3x/xunlei
docker run -d -v /mnt/usb1/siyuan:/siyuan/workspace  -e PUID=$UID  -e PGID=$GID  -p 6806:6806 b3log/siyuan  --workspace=/siyuan/workspace/ --accessAuthCode=xxx
docker run -d --name=siyuan -v /mnt/usb1_2-1/siyuan:/siyuan/workspace -p 2000:6806 --restart always  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d --name syncthing  --restart always -p 3000:8384 -p 22000:22000/tcp -p 22000:22000/udp  -p 21027:21027/udp -v /mnt/config-sync:/var/syncthing/config -v /mnt:/var/syncthing/data syncthing/syncthing
docker run -d \
  --name syncthing \
  --restart always \
  -p 8384:8384 \
  -p 22000:22000/tcp \
  -p 22000:22000/udp \
  -p 21027:21027/udp \
  -v /mnt/usb2/syncthing/config:/var/syncthing/config \
  -v /mnt/usb2/syncthing/:/var/syncthing/data \
  syncthing/syncthing
docker run -d --name=samba  --restart unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NNN"  -v "/mnt:/storage" dockurr/samba
opkg install fdisk block-mount unzip zerotier samba4-server samba4-utils luci-app-samba4 openssh-sftp-server openvpn-openssl luci-app-openvpn wireguard-tools kmod-wireguard luci-proto-wireguard
mkdir -p /tmp/introot
mkdir -p /tmp/extroot
mount --bind / /tmp/introot
mount /dev/sda3 /tmp/extroot
tar -C /tmp/introot -cvf - . | tar -C /tmp/extroot -xf -
umount /tmp/introot
umount /tmp/extroot
docker run -d --name=samba --restart=unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NBBN"  -v "/mnt/:/storage" dockurr/samba
network:
  version: 2
  renderer: networkd
  wifis:
    wlp2s0:
      dhcp4: no
      addresses:
        - 192.168.0.124/24  # 这里改成你想要的静态 IP
      gateway4: 192.168.0.8  # 你的网关 IP（通常是路由器 IP）
      nameservers:
        addresses:
          - 211.140.13.188   
          - 114.114.114.114  # 114 DNS
      access-points:
        "boci1":
          password: "a1b2c3d4"

docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
docker run --restart always --name openwrt1 -d --network macnet --privileged --ip 192.168.0.124   openwrt /sbin/init
docker run -d \
  --name=clash \
  -v /root/clash.yaml: /root/.config/clash/config.yaml \
  -p 7890:7890 \
  -p 9090:9090 \
  --restart unless-stopped \
  dreamacro/clash

安装官方最新版本：
curl -fsSL https://get.docker.com | bash
docker import rootfs.tar.gz my-custom-image
docker run -d \
  --name openwrt \
  --network host \
  --privileged \
  openwrt
docker run --restart always --name openwrt -p 80:80 -d --network host --privileged openwrt /sbin/init
允许 ZeroTier 网络访问本地网络
sudo iptables -A FORWARD -s 192.168.192.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 192.168.0.0/24 -d 192.168.192.0/24 -j ACCEPT
如果局域网设备默认网关不是 Ubuntu，需要 NAT
sudo iptables -t nat -A POSTROUTING -s 192.168.192.0/24 -d 192.168.0.0/24 -j MASQUERADE
eroTier 网络
192.168.0.0/24 via 192.168.191.112
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
ip route add 192.168.50.0/24 via 10.8.0.1 dev tun0
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
4.新启动 OpenVPN 服务
systemctl restart openvpn
docker run -d \
  --name=wg-client2 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  -v /mnt/wg0:/etc/wireguard/wg0 \
  weejewel/wg-easy
docker run -d \
  --name=wg-wireguard \
  -e WG_HOST=10.0.0.1 \
  -e PASSWORD= \
  --network host \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
docker run -d \
  --name=wg-easy3 \
  --network host \
  --privileged \
  -e WG_HOST=39.174.229.143 \
  -e PASSWORD= \
  -e WG_PERSISTENT_KEEPALIVE=25 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
network:
  ethernets:
    eth0:  # 请替换为你的实际网卡名称
      dhcp4: no
      addresses:
        - 192.168.0.219/24  # 设置静态 IP
      gateway4: 192.168.0.8  # 设置网关
      nameservers:
        addresses:
          - 211.140.13.188
  version: 2
ip route add 192.168.200.0/24 via 10.8.0.1 dev tun0
iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE
iptables -A FORWARD -i tun0 -o eth1 -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A FORWARD -i eth1 -o tun0 -j ACCEPT


docker run -d \
  --name=wireguard-client \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -v /mnt:/config \
  -v /lib/modules:/lib/modules \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  lscr.io/linuxserver/wireguard:latest

enp1s0    enx00e04c360351
network:
  version: 2
  renderer: networkd
  ethernets:
    eth0:
      dhcp4: yes
      dhcp6: no
    enx00e04c360351:
      addresses:
        - 10.131.61.111/24
      dhcp4: no
sudo iptables -t nat -A POSTROUTING -o enp1s0 -j MASQUERADE
sudo iptables -A FORWARD -i enx00e04c360351 -o enp1s0 -j ACCEPT
sudo iptables -A FORWARD -i enp1s0 -o enx00e04c360351 -m state --state RELATED,ESTABLISHED -j ACCEPT
ip route add 22.8.144.97 via 10.130.61.1 dev enx00e04c360351
ip route add 22.8.144.97 via 10.131.61.1 dev br-lan  
ip route add 22.8.144.97 via 10.0.0.5 dev wireguard 
22.8.144.97
ip route add 22.8.144.97 via 192.168.0.8 dev eth0
39.174.229.143
10.0.0.0/24
uci show firewall | grep '@redirect'
docker run -d \
  --name=transmission \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -p 80:9091 \
  -p 51413:51413 \
  -p 51413:51413/udp \
  -v /home/download:/downloads \
  --restart unless-stopped \
  lscr.io/linuxserver/transmission:latest

docker run --restart always --name openwrt -d --network macnet --privileged --ip 10.1.25.193 ophub/openwrt-aarch64:latest
uci set zerotier.global.enabled='1'
uci delete zerotier.earth
uci set zerotier.openwrt_network=network
uci set zerotier.openwrt_network.id='856127940c66f22d'
uci commit zerotier
ip link set  eth0 promisc on
docker network create -d macvlan --subnet=192.168.50.0/24 --gateway=192.168.50.1 -o parent=br-lan  mynet
docker run  --name openwrt --restart unless-stopped -d --network mynet    --privileged --ip 192.168.50.314  openwrt  /sbin/init
docker run -d \
  --name=resilio-sync \
  -p 8888:8888 \
  -p 55555:55555 \
  -v /mnt/sda1/resilio:/mnt/sync \
  -v /mnt/sda1/resilio-config:/config \
  --restart unless-stopped \
  resilio/sync

[Interface]
PrivateKey = OO5201M+3VC3BpIZY7MGhMbZkIBlmGyzegh5sgWPjVU=
Address = 10.0.8.6/24
DNS = 211.140.13.188


[Peer]
PublicKey = klRBbxYnJUMuKBLewfTwaQdj08w9JoeipgZyhahyynU=
PresharedKey = NNwo3pswYpeHmrZV3aWoHT+aBCUq0VDMVDErAY4Z+7Y=
AllowedIPs = 10.0.8.0/24,10.1.25.0/24
PersistentKeepalive = 25
Endpoint = 39.174.229.143:51820


c0: 20250204202213-2virs7k
c2: update
c3: 复制修改版
c5: 2025-03-15-153234-update/20250204202137-3g13i3l/20250204202213-2virs7k.sy
c6: 1742023954
c4:
通过 iPhone 镜像从 Mac 使用 iPhone
魔兽争霸:https://www.123pan.com/s/nVxFjv-fkwd3.html
dd if=openwrt-24.10.0-armsr-armv8-generic-ext4-combined-efi.img of=/dev/mmcblk2 bs=4M
docker dockerd luci-lib-docker docker-compose
docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
dd if=/dev/sda of=/root/openwrt24.img bs=4M status=progress

docker run -d  -v /mnt/usb1_2-1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d \
  --name=qbittorrent \
  -e PUID=0 \
  -e PGID=0 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 1000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/usb1_2-1:/config \
  -v /mnt/usb1_2-1/download:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

docker run -d \
  --name=qbittorrent \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 1000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/usb1_2-1/download:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

dd if=istoreo.img of=/dev/sda bs=4M
docker run -d --name=xunlei --hostname=NNN1 --net=host -v /mnt/usb1_2-1/configxunl:/xunlei/config -v /mnt/usb1_2-1:/xunlei/downloads --restart=unless-stopped --privileged cnk3x/xunlei:latest
docker run -d --privileged  -v /mnt/:/xunlei/downloads -p 2345:2345 cnk3x/xunlei
docker run -d -v /mnt/usb1/siyuan:/siyuan/workspace  -e PUID=$UID  -e PGID=$GID  -p 6806:6806 b3log/siyuan  --workspace=/siyuan/workspace/ --accessAuthCode=xxx
docker run -d --name=siyuan -v /mnt/usb1_2-1/siyuan:/siyuan/workspace -p 2000:6806 --restart always  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d --name syncthing  --restart always -p 3000:8384 -p 22000:22000/tcp -p 22000:22000/udp  -p 21027:21027/udp -v /mnt/config-sync:/var/syncthing/config -v /mnt:/var/syncthing/data syncthing/syncthing
docker run -d \
  --name syncthing \
  --restart always \
  -p 8384:8384 \
  -p 22000:22000/tcp \
  -p 22000:22000/udp \
  -p 21027:21027/udp \
  -v /mnt/usb2/syncthing/config:/var/syncthing/config \
  -v /mnt/usb2/syncthing/:/var/syncthing/data \
  syncthing/syncthing
docker run -d --name=samba  --restart unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NNN"  -v "/mnt:/storage" dockurr/samba
opkg install fdisk block-mount unzip zerotier samba4-server samba4-utils luci-app-samba4 openssh-sftp-server openvpn-openssl luci-app-openvpn wireguard-tools kmod-wireguard luci-proto-wireguard
mkdir -p /tmp/introot
mkdir -p /tmp/extroot
mount --bind / /tmp/introot
mount /dev/sda3 /tmp/extroot
tar -C /tmp/introot -cvf - . | tar -C /tmp/extroot -xf -
umount /tmp/introot
umount /tmp/extroot
docker run -d --name=samba --restart=unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NBBN"  -v "/mnt/:/storage" dockurr/samba
network:
  version: 2
  renderer: networkd
  wifis:
    wlp2s0:
      dhcp4: no
      addresses:
        - 192.168.0.124/24  # 这里改成你想要的静态 IP
      gateway4: 192.168.0.8  # 你的网关 IP（通常是路由器 IP）
      nameservers:
        addresses:
          - 211.140.13.188   
          - 114.114.114.114  # 114 DNS
      access-points:
        "boci1":
          password: "a1b2c3d4"

docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
docker run --restart always --name openwrt1 -d --network macnet --privileged --ip 192.168.0.124   openwrt /sbin/init
docker run -d \
  --name=clash \
  -v /root/clash.yaml: /root/.config/clash/config.yaml \
  -p 7890:7890 \
  -p 9090:9090 \
  --restart unless-stopped \
  dreamacro/clash

安装官方最新版本：
curl -fsSL https://get.docker.com | bash
docker import rootfs.tar.gz my-custom-image
docker run -d \
  --name openwrt \
  --network host \
  --privileged \
  openwrt
docker run --restart always --name openwrt -p 80:80 -d --network host --privileged openwrt /sbin/init
允许 ZeroTier 网络访问本地网络
sudo iptables -A FORWARD -s 192.168.192.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 192.168.0.0/24 -d 192.168.192.0/24 -j ACCEPT
如果局域网设备默认网关不是 Ubuntu，需要 NAT
sudo iptables -t nat -A POSTROUTING -s 192.168.192.0/24 -d 192.168.0.0/24 -j MASQUERADE
eroTier 网络
192.168.0.0/24 via 192.168.191.112
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
ip route add 192.168.50.0/24 via 10.8.0.1 dev tun0
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
4.新启动 OpenVPN 服务
systemctl restart openvpn
docker run -d \
  --name=wg-client2 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  -v /mnt/wg0:/etc/wireguard/wg0 \
  weejewel/wg-easy
docker run -d \
  --name=wg-wireguard \
  -e WG_HOST=10.0.0.1 \
  -e PASSWORD= \
  --network host \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
docker run -d \
  --name=wg-easy3 \
  --network host \
  --privileged \
  -e WG_HOST=39.174.229.143 \
  -e PASSWORD= \
  -e WG_PERSISTENT_KEEPALIVE=25 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
network:
  ethernets:
    eth0:  # 请替换为你的实际网卡名称
      dhcp4: no
      addresses:
        - 192.168.0.219/24  # 设置静态 IP
      gateway4: 192.168.0.8  # 设置网关
      nameservers:
        addresses:
          - 211.140.13.188
  version: 2
ip route add 192.168.200.0/24 via 10.8.0.1 dev tun0
iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE
iptables -A FORWARD -i tun0 -o eth1 -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A FORWARD -i eth1 -o tun0 -j ACCEPT


docker run -d \
  --name=wireguard-client \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -v /mnt:/config \
  -v /lib/modules:/lib/modules \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  lscr.io/linuxserver/wireguard:latest

enp1s0    enx00e04c360351
network:
  version: 2
  renderer: networkd
  ethernets:
    eth0:
      dhcp4: yes
      dhcp6: no
    enx00e04c360351:
      addresses:
        - 10.131.61.111/24
      dhcp4: no
sudo iptables -t nat -A POSTROUTING -o enp1s0 -j MASQUERADE
sudo iptables -A FORWARD -i enx00e04c360351 -o enp1s0 -j ACCEPT
sudo iptables -A FORWARD -i enp1s0 -o enx00e04c360351 -m state --state RELATED,ESTABLISHED -j ACCEPT
ip route add 22.8.144.97 via 10.130.61.1 dev enx00e04c360351
ip route add 22.8.144.97 via 10.131.61.1 dev br-lan  
ip route add 22.8.144.97 via 10.0.0.5 dev wireguard 
22.8.144.97
ip route add 22.8.144.97 via 192.168.0.8 dev eth0
39.174.229.143
10.0.0.0/24
uci show firewall | grep '@redirect'
docker run -d \
  --name=transmission \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -p 80:9091 \
  -p 51413:51413 \
  -p 51413:51413/udp \
  -v /home/download:/downloads \
  --restart unless-stopped \
  lscr.io/linuxserver/transmission:latest

docker run --restart always --name openwrt -d --network macnet --privileged --ip 10.1.25.193 ophub/openwrt-aarch64:latest
uci set zerotier.global.enabled='1'
uci delete zerotier.earth
uci set zerotier.openwrt_network=network
uci set zerotier.openwrt_network.id='856127940c66f22d'
uci commit zerotier
ip link set  eth0 promisc on
docker network create -d macvlan --subnet=192.168.50.0/24 --gateway=192.168.50.1 -o parent=br-lan  mynet
docker run  --name openwrt --restart unless-stopped -d --network mynet    --privileged --ip 192.168.50.314  openwrt  /sbin/init
docker run -d \
  --name=resilio-sync \
  -p 8888:8888 \
  -p 55555:55555 \
  -v /mnt/sda1/resilio:/mnt/sync \
  -v /mnt/sda1/resilio-config:/config \
  --restart unless-stopped \
  resilio/sync

[Interface]
PrivateKey = OO5201M+3VC3BpIZY7MGhMbZkIBlmGyzegh5sgWPjVU=
Address = 10.0.8.6/24
DNS = 211.140.13.188


[Peer]
PublicKey = klRBbxYnJUMuKBLewfTwaQdj08w9JoeipgZyhahyynU=
PresharedKey = NNwo3pswYpeHmrZV3aWoHT+aBCUq0VDMVDErAY4Z+7Y=
AllowedIPs = 10.0.8.0/24,10.1.25.0/24
PersistentKeepalive = 25
Endpoint = 39.174.229.143:51820


c0: 20250204202213-2virs7k
c2: update
c3: 复制修改版
c5: 2025-03-15-171234-update/20250204202137-3g13i3l/20250204202213-2virs7k.sy
c6: 1742029954
c4:
通过 iPhone 镜像从 Mac 使用 iPhone
魔兽争霸:https://www.123pan.com/s/nVxFjv-fkwd3.html
dd if=openwrt-24.10.0-armsr-armv8-generic-ext4-combined-efi.img of=/dev/mmcblk2 bs=4M
docker dockerd luci-lib-docker docker-compose
docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
dd if=/dev/sda of=/root/openwrt24.img bs=4M status=progress

docker run -d  -v /mnt/usb1_2-1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d \
  --name=qbittorrent \
  -e PUID=0 \
  -e PGID=0 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 1000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/usb1_2-1:/config \
  -v /mnt/usb1_2-1/download:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

docker run -d \
  --name=qbittorrent \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 1000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/usb1_2-1/download:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

dd if=istoreo.img of=/dev/sda bs=4M
docker run -d --name=xunlei --hostname=NNN1 --net=host -v /mnt/data2/configxunl:/xunlei/config -v /mnt/data2:/xunlei/downloads --restart=unless-stopped --privileged cnk3x/xunlei:latest
docker run -d --privileged  -v /mnt/:/xunlei/downloads -p 2345:2345 cnk3x/xunlei
docker run -d -v /mnt/usb1/siyuan:/siyuan/workspace  -e PUID=$UID  -e PGID=$GID  -p 6806:6806 b3log/siyuan  --workspace=/siyuan/workspace/ --accessAuthCode=xxx
docker run -d --name=siyuan -v /mnt/usb1_2-1/siyuan:/siyuan/workspace -p 2000:6806 --restart always  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d --name syncthing  --restart always -p 3000:8384 -p 22000:22000/tcp -p 22000:22000/udp  -p 21027:21027/udp -v /mnt/config-sync:/var/syncthing/config -v /mnt:/var/syncthing/data syncthing/syncthing
docker run -d \
  --name syncthing \
  --restart always \
  -p 8384:8384 \
  -p 22000:22000/tcp \
  -p 22000:22000/udp \
  -p 21027:21027/udp \
  -v /mnt/usb2/syncthing/config:/var/syncthing/config \
  -v /mnt/usb2/syncthing/:/var/syncthing/data \
  syncthing/syncthing
docker run -d --name=samba  --restart unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NNN"  -v "/mnt:/storage" dockurr/samba
opkg install fdisk block-mount unzip zerotier samba4-server samba4-utils luci-app-samba4 openssh-sftp-server openvpn-openssl luci-app-openvpn wireguard-tools kmod-wireguard luci-proto-wireguard
mkdir -p /tmp/introot
mkdir -p /tmp/extroot
mount --bind / /tmp/introot
mount /dev/sda3 /tmp/extroot
tar -C /tmp/introot -cvf - . | tar -C /tmp/extroot -xf -
umount /tmp/introot
umount /tmp/extroot
docker run -d --name=samba --restart=unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NBBN"  -v "/mnt/:/storage" dockurr/samba
network:
  version: 2
  renderer: networkd
  wifis:
    wlp2s0:
      dhcp4: no
      addresses:
        - 192.168.0.124/24  # 这里改成你想要的静态 IP
      gateway4: 192.168.0.8  # 你的网关 IP（通常是路由器 IP）
      nameservers:
        addresses:
          - 211.140.13.188   
          - 114.114.114.114  # 114 DNS
      access-points:
        "boci1":
          password: "a1b2c3d4"

docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
docker run --restart always --name openwrt1 -d --network macnet --privileged --ip 192.168.0.124   openwrt /sbin/init
docker run -d \
  --name=clash \
  -v /root/clash.yaml: /root/.config/clash/config.yaml \
  -p 7890:7890 \
  -p 9090:9090 \
  --restart unless-stopped \
  dreamacro/clash

安装官方最新版本：
curl -fsSL https://get.docker.com | bash
docker import rootfs.tar.gz my-custom-image
docker run -d \
  --name openwrt \
  --network host \
  --privileged \
  openwrt
docker run --restart always --name openwrt -p 80:80 -d --network host --privileged openwrt /sbin/init
允许 ZeroTier 网络访问本地网络
sudo iptables -A FORWARD -s 192.168.192.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 192.168.0.0/24 -d 192.168.192.0/24 -j ACCEPT
如果局域网设备默认网关不是 Ubuntu，需要 NAT
sudo iptables -t nat -A POSTROUTING -s 192.168.192.0/24 -d 192.168.0.0/24 -j MASQUERADE
eroTier 网络
192.168.0.0/24 via 192.168.191.112
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
ip route add 192.168.50.0/24 via 10.8.0.1 dev tun0
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
4.新启动 OpenVPN 服务
systemctl restart openvpn
docker run -d \
  --name=wg-client2 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  -v /mnt/wg0:/etc/wireguard/wg0 \
  weejewel/wg-easy
docker run -d \
  --name=wg-wireguard \
  -e WG_HOST=10.0.0.1 \
  -e PASSWORD= \
  --network host \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
docker run -d \
  --name=wg-easy3 \
  --network host \
  --privileged \
  -e WG_HOST=39.174.229.143 \
  -e PASSWORD= \
  -e WG_PERSISTENT_KEEPALIVE=25 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
network:
  ethernets:
    eth0:  # 请替换为你的实际网卡名称
      dhcp4: no
      addresses:
        - 192.168.0.219/24  # 设置静态 IP
      gateway4: 192.168.0.8  # 设置网关
      nameservers:
        addresses:
          - 211.140.13.188
  version: 2
ip route add 192.168.200.0/24 via 10.8.0.1 dev tun0
iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE
iptables -A FORWARD -i tun0 -o eth1 -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A FORWARD -i eth1 -o tun0 -j ACCEPT


docker run -d \
  --name=wireguard-client \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -v /mnt:/config \
  -v /lib/modules:/lib/modules \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  lscr.io/linuxserver/wireguard:latest

enp1s0    enx00e04c360351
network:
  version: 2
  renderer: networkd
  ethernets:
    eth0:
      dhcp4: yes
      dhcp6: no
    enx00e04c360351:
      addresses:
        - 10.131.61.111/24
      dhcp4: no
sudo iptables -t nat -A POSTROUTING -o enp1s0 -j MASQUERADE
sudo iptables -A FORWARD -i enx00e04c360351 -o enp1s0 -j ACCEPT
sudo iptables -A FORWARD -i enp1s0 -o enx00e04c360351 -m state --state RELATED,ESTABLISHED -j ACCEPT
ip route add 22.8.144.97 via 10.130.61.1 dev enx00e04c360351
ip route add 22.8.144.97 via 10.131.61.1 dev br-lan  
ip route add 22.8.144.97 via 10.0.0.5 dev wireguard 
22.8.144.97
ip route add 22.8.144.97 via 192.168.0.8 dev eth0
39.174.229.143
10.0.0.0/24
uci show firewall | grep '@redirect'
docker run -d \
  --name=transmission \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -p 80:9091 \
  -p 51413:51413 \
  -p 51413:51413/udp \
  -v /home/download:/downloads \
  --restart unless-stopped \
  lscr.io/linuxserver/transmission:latest

docker run --restart always --name openwrt -d --network macnet --privileged --ip 10.1.25.193 ophub/openwrt-aarch64:latest
uci set zerotier.global.enabled='1'
uci delete zerotier.earth
uci set zerotier.openwrt_network=network
uci set zerotier.openwrt_network.id='856127940c66f22d'
uci commit zerotier
ip link set  eth0 promisc on
docker network create -d macvlan --subnet=192.168.50.0/24 --gateway=192.168.50.1 -o parent=br-lan  mynet
docker run  --name openwrt --restart unless-stopped -d --network mynet    --privileged --ip 192.168.50.314  openwrt  /sbin/init
docker run -d \
  --name=resilio-sync \
  -p 8888:8888 \
  -p 55555:55555 \
  -v /mnt/sda1/resilio:/mnt/sync \
  -v /mnt/sda1/resilio-config:/config \
  --restart unless-stopped \
  resilio/sync

[Interface]
PrivateKey = OO5201M+3VC3BpIZY7MGhMbZkIBlmGyzegh5sgWPjVU=
Address = 10.0.8.6/24
DNS = 211.140.13.188


[Peer]
PublicKey = klRBbxYnJUMuKBLewfTwaQdj08w9JoeipgZyhahyynU=
PresharedKey = NNwo3pswYpeHmrZV3aWoHT+aBCUq0VDMVDErAY4Z+7Y=
AllowedIPs = 10.0.8.0/24,10.1.25.0/24
PersistentKeepalive = 25
Endpoint = 39.174.229.143:51820


c0: 20250204202213-2virs7k
c2: update
c3: 复制修改版
c5: 2025-03-15-172234-update/20250204202137-3g13i3l/20250204202213-2virs7k.sy
c6: 1742030554
c4:
通过 iPhone 镜像从 Mac 使用 iPhone
魔兽争霸:https://www.123pan.com/s/nVxFjv-fkwd3.html
dd if=openwrt-24.10.0-armsr-armv8-generic-ext4-combined-efi.img of=/dev/mmcblk2 bs=4M
docker dockerd luci-lib-docker docker-compose
docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
dd if=/dev/sda of=/root/openwrt24.img bs=4M status=progress

docker run -d  -v /mnt/data1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d \
  --name=qbittorrent \
  -e PUID=0 \
  -e PGID=0 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 1000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/usb1_2-1:/config \
  -v /mnt/usb1_2-1/download:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

docker run -d \
  --name=qbittorrent \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 1000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/usb1_2-1/download:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

dd if=istoreo.img of=/dev/sda bs=4M
docker run -d --name=xunlei --hostname=NNN1 --net=host -v /mnt/data2/configxunl:/xunlei/config -v /mnt/data2:/xunlei/downloads --restart=unless-stopped --privileged cnk3x/xunlei:latest
docker run -d --privileged  -v /mnt/:/xunlei/downloads -p 2345:2345 cnk3x/xunlei
docker run -d -v /mnt/usb1/siyuan:/siyuan/workspace  -e PUID=$UID  -e PGID=$GID  -p 6806:6806 b3log/siyuan  --workspace=/siyuan/workspace/ --accessAuthCode=xxx
docker run -d --name=siyuan -v /mnt/usb1_2-1/siyuan:/siyuan/workspace -p 2000:6806 --restart always  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d --name syncthing  --restart always -p 3000:8384 -p 22000:22000/tcp -p 22000:22000/udp  -p 21027:21027/udp -v /mnt/config-sync:/var/syncthing/config -v /mnt:/var/syncthing/data syncthing/syncthing
docker run -d \
  --name syncthing \
  --restart always \
  -p 8384:8384 \
  -p 22000:22000/tcp \
  -p 22000:22000/udp \
  -p 21027:21027/udp \
  -v /mnt/usb2/syncthing/config:/var/syncthing/config \
  -v /mnt/usb2/syncthing/:/var/syncthing/data \
  syncthing/syncthing
docker run -d --name=samba  --restart unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NNN"  -v "/mnt:/storage" dockurr/samba
opkg install fdisk block-mount unzip zerotier samba4-server samba4-utils luci-app-samba4 openssh-sftp-server openvpn-openssl luci-app-openvpn wireguard-tools kmod-wireguard luci-proto-wireguard
mkdir -p /tmp/introot
mkdir -p /tmp/extroot
mount --bind / /tmp/introot
mount /dev/sda3 /tmp/extroot
tar -C /tmp/introot -cvf - . | tar -C /tmp/extroot -xf -
umount /tmp/introot
umount /tmp/extroot
docker run -d --name=samba --restart=unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NBBN"  -v "/mnt/:/storage" dockurr/samba
network:
  version: 2
  renderer: networkd
  wifis:
    wlp2s0:
      dhcp4: no
      addresses:
        - 192.168.0.124/24  # 这里改成你想要的静态 IP
      gateway4: 192.168.0.8  # 你的网关 IP（通常是路由器 IP）
      nameservers:
        addresses:
          - 211.140.13.188   
          - 114.114.114.114  # 114 DNS
      access-points:
        "boci1":
          password: "a1b2c3d4"

docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
docker run --restart always --name openwrt1 -d --network macnet --privileged --ip 192.168.0.124   openwrt /sbin/init
docker run -d \
  --name=clash \
  -v /root/clash.yaml: /root/.config/clash/config.yaml \
  -p 7890:7890 \
  -p 9090:9090 \
  --restart unless-stopped \
  dreamacro/clash

安装官方最新版本：
curl -fsSL https://get.docker.com | bash
docker import rootfs.tar.gz my-custom-image
docker run -d \
  --name openwrt \
  --network host \
  --privileged \
  openwrt
docker run --restart always --name openwrt -p 80:80 -d --network host --privileged openwrt /sbin/init
允许 ZeroTier 网络访问本地网络
sudo iptables -A FORWARD -s 192.168.192.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 192.168.0.0/24 -d 192.168.192.0/24 -j ACCEPT
如果局域网设备默认网关不是 Ubuntu，需要 NAT
sudo iptables -t nat -A POSTROUTING -s 192.168.192.0/24 -d 192.168.0.0/24 -j MASQUERADE
eroTier 网络
192.168.0.0/24 via 192.168.191.112
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
ip route add 192.168.50.0/24 via 10.8.0.1 dev tun0
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
4.新启动 OpenVPN 服务
systemctl restart openvpn
docker run -d \
  --name=wg-client2 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  -v /mnt/wg0:/etc/wireguard/wg0 \
  weejewel/wg-easy
docker run -d \
  --name=wg-wireguard \
  -e WG_HOST=10.0.0.1 \
  -e PASSWORD= \
  --network host \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
docker run -d \
  --name=wg-easy3 \
  --network host \
  --privileged \
  -e WG_HOST=39.174.229.143 \
  -e PASSWORD= \
  -e WG_PERSISTENT_KEEPALIVE=25 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
network:
  ethernets:
    eth0:  # 请替换为你的实际网卡名称
      dhcp4: no
      addresses:
        - 192.168.0.219/24  # 设置静态 IP
      gateway4: 192.168.0.8  # 设置网关
      nameservers:
        addresses:
          - 211.140.13.188
  version: 2
ip route add 192.168.200.0/24 via 10.8.0.1 dev tun0
iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE
iptables -A FORWARD -i tun0 -o eth1 -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A FORWARD -i eth1 -o tun0 -j ACCEPT


docker run -d \
  --name=wireguard-client \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -v /mnt:/config \
  -v /lib/modules:/lib/modules \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  lscr.io/linuxserver/wireguard:latest

enp1s0    enx00e04c360351
network:
  version: 2
  renderer: networkd
  ethernets:
    eth0:
      dhcp4: yes
      dhcp6: no
    enx00e04c360351:
      addresses:
        - 10.131.61.111/24
      dhcp4: no
sudo iptables -t nat -A POSTROUTING -o enp1s0 -j MASQUERADE
sudo iptables -A FORWARD -i enx00e04c360351 -o enp1s0 -j ACCEPT
sudo iptables -A FORWARD -i enp1s0 -o enx00e04c360351 -m state --state RELATED,ESTABLISHED -j ACCEPT
ip route add 22.8.144.97 via 10.130.61.1 dev enx00e04c360351
ip route add 22.8.144.97 via 10.131.61.1 dev br-lan  
ip route add 22.8.144.97 via 10.0.0.5 dev wireguard 
22.8.144.97
ip route add 22.8.144.97 via 192.168.0.8 dev eth0
39.174.229.143
10.0.0.0/24
uci show firewall | grep '@redirect'
docker run -d \
  --name=transmission \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -p 80:9091 \
  -p 51413:51413 \
  -p 51413:51413/udp \
  -v /home/download:/downloads \
  --restart unless-stopped \
  lscr.io/linuxserver/transmission:latest

docker run --restart always --name openwrt -d --network macnet --privileged --ip 10.1.25.193 ophub/openwrt-aarch64:latest
uci set zerotier.global.enabled='1'
uci delete zerotier.earth
uci set zerotier.openwrt_network=network
uci set zerotier.openwrt_network.id='856127940c66f22d'
uci commit zerotier
ip link set  eth0 promisc on
docker network create -d macvlan --subnet=192.168.50.0/24 --gateway=192.168.50.1 -o parent=br-lan  mynet
docker run  --name openwrt --restart unless-stopped -d --network mynet    --privileged --ip 192.168.50.314  openwrt  /sbin/init
docker run -d \
  --name=resilio-sync \
  -p 8888:8888 \
  -p 55555:55555 \
  -v /mnt/sda1/resilio:/mnt/sync \
  -v /mnt/sda1/resilio-config:/config \
  --restart unless-stopped \
  resilio/sync

[Interface]
PrivateKey = OO5201M+3VC3BpIZY7MGhMbZkIBlmGyzegh5sgWPjVU=
Address = 10.0.8.6/24
DNS = 211.140.13.188


[Peer]
PublicKey = klRBbxYnJUMuKBLewfTwaQdj08w9JoeipgZyhahyynU=
PresharedKey = NNwo3pswYpeHmrZV3aWoHT+aBCUq0VDMVDErAY4Z+7Y=
AllowedIPs = 10.0.8.0/24,10.1.25.0/24
PersistentKeepalive = 25
Endpoint = 39.174.229.143:51820


c0: 20250204202213-2virs7k
c2: update
c3: 复制修改版
c5: 2025-03-15-210234-update/20250204202137-3g13i3l/20250204202213-2virs7k.sy
c6: 1742043754
c4:
通过 iPhone 镜像从 Mac 使用 iPhone
魔兽争霸:https://www.123pan.com/s/nVxFjv-fkwd3.html
dd if=openwrt-24.10.0-armsr-armv8-generic-ext4-combined-efi.img of=/dev/mmcblk2 bs=4M
docker dockerd luci-lib-docker docker-compose
docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
dd if=/dev/sda of=/root/openwrt24.img bs=4M status=progress

docker run -d  -v /mnt/data1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d \
  --name=qbittorrent \
  -e PUID=0 \
  -e PGID=0 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 1000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/usb1_2-1:/config \
  -v /mnt/usb1_2-1/download:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

docker run -d \
  --name=qbittorrent \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 1000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/usb1_2-1/download:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

dd if=istoreo.img of=/dev/sda bs=4M
docker run -d --name=xunlei --hostname=NNN1 --net=host -v /mnt/data2/configxunl:/xunlei/config -v /mnt/data2:/xunlei/downloads --restart=unless-stopped --privileged cnk3x/xunlei:latest
docker run -d --privileged  -v /mnt/:/xunlei/downloads -p 2345:2345 cnk3x/xunlei
docker run -d -v /mnt/usb1/siyuan:/siyuan/workspace  -e PUID=$UID  -e PGID=$GID  -p 6806:6806 b3log/siyuan  --workspace=/siyuan/workspace/ --accessAuthCode=xxx
docker run -d --name=siyuan -v /mnt/usb1_2-1/siyuan:/siyuan/workspace -p 2000:6806 --restart always  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d --name syncthing  --restart always -p 3000:8384 -p 22000:22000/tcp -p 22000:22000/udp  -p 21027:21027/udp -v /mnt/config-sync:/var/syncthing/config -v /mnt:/var/syncthing/data syncthing/syncthing
docker run -d \
  --name syncthing \
  --restart always \
  -p 8384:8384 \
  -p 22000:22000/tcp \
  -p 22000:22000/udp \
  -p 21027:21027/udp \
  -v /mnt/usb2/syncthing/config:/var/syncthing/config \
  -v /mnt/usb2/syncthing/:/var/syncthing/data \
  syncthing/syncthing
docker run -d --name=samba  --restart unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NNN"  -v "/mnt:/storage" dockurr/samba
opkg install fdisk block-mount unzip zerotier samba4-server samba4-utils luci-app-samba4 openssh-sftp-server openvpn-openssl luci-app-openvpn wireguard-tools kmod-wireguard luci-proto-wireguard
mkdir -p /tmp/introot
mkdir -p /tmp/extroot
mount --bind / /tmp/introot
mount /dev/sda3 /tmp/extroot
tar -C /tmp/introot -cvf - . | tar -C /tmp/extroot -xf -
umount /tmp/introot
umount /tmp/extroot
docker run -d --name=samba --restart=unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NBBN"  -v "/mnt/:/storage" dockurr/samba
network:
  version: 2
  renderer: networkd
  wifis:
    wlp2s0:
      dhcp4: no
      addresses:
        - 192.168.0.124/24  # 这里改成你想要的静态 IP
      gateway4: 192.168.0.8  # 你的网关 IP（通常是路由器 IP）
      nameservers:
        addresses:
          - 211.140.13.188   
          - 114.114.114.114  # 114 DNS
      access-points:
        "boci1":
          password: "a1b2c3d4"

docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
docker run --restart always --name openwrt1 -d --network macnet --privileged --ip 192.168.0.124   openwrt /sbin/init
docker run -d \
  --name=clash \
  -v /root/clash.yaml: /root/.config/clash/config.yaml \
  -p 7890:7890 \
  -p 9090:9090 \
  --restart unless-stopped \
  dreamacro/clash

安装官方最新版本：
curl -fsSL https://get.docker.com | bash
docker import rootfs.tar.gz my-custom-image
docker run -d \
  --name openwrt \
  --network host \
  --privileged \
  openwrt
docker run --restart always --name openwrt -p 80:80 -d --network host --privileged openwrt /sbin/init
允许 ZeroTier 网络访问本地网络
sudo iptables -A FORWARD -s 192.168.192.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 192.168.0.0/24 -d 192.168.192.0/24 -j ACCEPT
如果局域网设备默认网关不是 Ubuntu，需要 NAT
sudo iptables -t nat -A POSTROUTING -s 192.168.192.0/24 -d 192.168.0.0/24 -j MASQUERADE
eroTier 网络
192.168.0.0/24 via 192.168.191.112
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
ip route add 192.168.50.0/24 via 10.8.0.1 dev tun0
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
4.新启动 OpenVPN 服务
systemctl restart openvpn
docker run -d \
  --name=wg-client2 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  -v /mnt/wg0:/etc/wireguard/wg0 \
  weejewel/wg-easy
docker run -d \
  --name=wg-wireguard \
  -e WG_HOST=10.0.0.1 \
  -e PASSWORD= \
  --network host \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
docker run -d \
  --name=wg-easy3 \
  --network host \
  --privileged \
  -e WG_HOST=39.174.229.143 \
  -e PASSWORD= \
  -e WG_PERSISTENT_KEEPALIVE=25 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
network:
  ethernets:
    eth0:  # 请替换为你的实际网卡名称
      dhcp4: no
      addresses:
        - 192.168.0.219/24  # 设置静态 IP
      gateway4: 192.168.0.8  # 设置网关
      nameservers:
        addresses:
          - 211.140.13.188
  version: 2
ip route add 192.168.200.0/24 via 10.8.0.1 dev tun0
iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE
iptables -A FORWARD -i tun0 -o eth1 -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A FORWARD -i eth1 -o tun0 -j ACCEPT


docker run -d \
  --name=wireguard-client \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -v /mnt:/config \
  -v /lib/modules:/lib/modules \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  lscr.io/linuxserver/wireguard:latest

enp1s0    enx00e04c360351
network:
  version: 2
  renderer: networkd
  ethernets:
    eth0:
      dhcp4: yes
      dhcp6: no
    enx00e04c360351:
      addresses:
        - 10.131.61.111/24
      dhcp4: no
sudo iptables -t nat -A POSTROUTING -o enp1s0 -j MASQUERADE
sudo iptables -A FORWARD -i enx00e04c360351 -o enp1s0 -j ACCEPT
sudo iptables -A FORWARD -i enp1s0 -o enx00e04c360351 -m state --state RELATED,ESTABLISHED -j ACCEPT
ip route add 22.8.144.97 via 10.130.61.1 dev enx00e04c360351
ip route add 22.8.144.97 via 10.131.61.1 dev br-lan  
ip route add 22.8.144.97 via 10.0.0.5 dev wireguard 
22.8.144.97
ip route add 22.8.144.97 via 192.168.0.8 dev eth0
39.174.229.143
10.0.0.0/24
uci show firewall | grep '@redirect'
docker run -d \
  --name=transmission \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -p 80:9091 \
  -p 51413:51413 \
  -p 51413:51413/udp \
  -v /home/download:/downloads \
  --restart unless-stopped \
  lscr.io/linuxserver/transmission:latest

docker run --restart always --name openwrt -d --network macnet --privileged --ip 10.1.25.193 ophub/openwrt-aarch64:latest
uci set zerotier.global.enabled='1'
uci delete zerotier.earth
uci set zerotier.openwrt_network=network
uci set zerotier.openwrt_network.id='856127940c66f22d'
uci commit zerotier
ip link set  eth0 promisc on
docker network create -d macvlan --subnet=192.168.50.0/24 --gateway=192.168.50.1 -o parent=br-lan  mynet
docker run  --name openwrt --restart unless-stopped -d --network mynet    --privileged --ip 192.168.50.314  openwrt  /sbin/init
docker run -d \
  --name=resilio-sync \
  -p 8888:8888 \
  -p 55555:55555 \
  -v /mnt/sda1/resilio:/mnt/sync \
  -v /mnt/sda1/resilio-config:/config \
  --restart unless-stopped \
  resilio/sync

user  root;
worker_processes  1;

events {
    worker_connections  1024;
}

stream {
    upstream rdp_backend {
        server 192.168.50.168:3389;  # 远程 Windows 11 的 IP
    }

    server {
        listen 3389;
        proxy_pass rdp_backend;
        proxy_timeout 10m;
        proxy_connect_timeout 10s;
    }
}

http {
    include       mime.types;
    default_type  application/octet-stream;
    sendfile        on;
    keepalive_timeout  65;

    server {
        listen       85;
        server_name  localhost;
        charset utf-8;

        location / {
            root   /usr/share/nginx/html;
            autoindex on;
        }

        location ~* ^.*\.txt$ {
            return 404;
        }

        error_page   500 502 503 504  /50x.html;
        location = /50x.html {
            root   /usr/share/nginx/html;
        }
    }
}


c0: 20250204202213-2virs7k
c2: update
c3: 复制修改版
c5: 2025-03-18-120234-update/20250204202137-3g13i3l/20250204202213-2virs7k.sy
c6: 1742270554
c4:
通过 iPhone 镜像从 Mac 使用 iPhone
魔兽争霸:https://www.123pan.com/s/nVxFjv-fkwd3.html
dd if=openwrt-24.10.0-armsr-armv8-generic-ext4-combined-efi.img of=/dev/mmcblk2 bs=4M
docker dockerd luci-lib-docker docker-compose
docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
dd if=/dev/sda of=/root/openwrt24.img bs=4M status=progress

docker run -d  -v /mnt/data1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d \
  --name=qbittorrent \
  -e PUID=0 \
  -e PGID=0 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 1000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/usb1_2-1:/config \
  -v /mnt/usb1_2-1/download:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

docker run -d \
  --name=qbittorrent \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 1000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/usb1_2-1/download:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

dd if=istoreo.img of=/dev/sda bs=4M
docker run -d --name=xunlei --hostname=NNN1 --net=host -v /mnt/data2/configxunl:/xunlei/config -v /mnt/data2:/xunlei/downloads --restart=unless-stopped --privileged cnk3x/xunlei:latest
docker run -d --privileged  -v /mnt/:/xunlei/downloads -p 2345:2345 cnk3x/xunlei
docker run -d -v /mnt/usb1/siyuan:/siyuan/workspace  -e PUID=$UID  -e PGID=$GID  -p 6806:6806 b3log/siyuan  --workspace=/siyuan/workspace/ --accessAuthCode=xxx
docker run -d --name=siyuan -v /mnt/usb1_2-1/siyuan:/siyuan/workspace -p 2000:6806 --restart always  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d --name syncthing  --restart always -p 3000:8384 -p 22000:22000/tcp -p 22000:22000/udp  -p 21027:21027/udp -v /mnt/config-sync:/var/syncthing/config -v /mnt:/var/syncthing/data syncthing/syncthing
docker run -d \
  --name syncthing \
  --restart always \
  -p 8384:8384 \
  -p 22000:22000/tcp \
  -p 22000:22000/udp \
  -p 21027:21027/udp \
  -v /mnt/usb2/syncthing/config:/var/syncthing/config \
  -v /mnt/usb2/syncthing/:/var/syncthing/data \
  syncthing/syncthing
docker run -d --name=samba  --restart unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NNN"  -v "/mnt:/storage" dockurr/samba
opkg install fdisk block-mount unzip zerotier samba4-server samba4-utils luci-app-samba4 openssh-sftp-server openvpn-openssl luci-app-openvpn wireguard-tools kmod-wireguard luci-proto-wireguard
mkdir -p /tmp/introot
mkdir -p /tmp/extroot
mount --bind / /tmp/introot
mount /dev/sda4 /tmp/extroot
tar -C /tmp/introot -cvf - . | tar -C /tmp/extroot -xf -
umount /tmp/introot
umount /tmp/extroot
docker run -d --name=samba --restart=unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NBBN"  -v "/mnt/:/storage" dockurr/samba
network:
  version: 2
  renderer: networkd
  wifis:
    wlp2s0:
      dhcp4: no
      addresses:
        - 192.168.0.124/24  # 这里改成你想要的静态 IP
      gateway4: 192.168.0.8  # 你的网关 IP（通常是路由器 IP）
      nameservers:
        addresses:
          - 211.140.13.188   
          - 114.114.114.114  # 114 DNS
      access-points:
        "boci1":
          password: "a1b2c3d4"

docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
docker run --restart always --name openwrt1 -d --network macnet --privileged --ip 192.168.0.124   openwrt /sbin/init
docker run -d \
  --name=clash \
  -v /root/clash.yaml: /root/.config/clash/config.yaml \
  -p 7890:7890 \
  -p 9090:9090 \
  --restart unless-stopped \
  dreamacro/clash

安装官方最新版本：
curl -fsSL https://get.docker.com | bash
docker import rootfs.tar.gz my-custom-image
docker run -d \
  --name openwrt \
  --network host \
  --privileged \
  openwrt
docker run --restart always --name openwrt -p 80:80 -d --network host --privileged openwrt /sbin/init
允许 ZeroTier 网络访问本地网络
sudo iptables -A FORWARD -s 192.168.192.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 192.168.0.0/24 -d 192.168.192.0/24 -j ACCEPT
如果局域网设备默认网关不是 Ubuntu，需要 NAT
sudo iptables -t nat -A POSTROUTING -s 192.168.192.0/24 -d 192.168.0.0/24 -j MASQUERADE
eroTier 网络
192.168.0.0/24 via 192.168.191.112
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
ip route add 192.168.50.0/24 via 10.8.0.1 dev tun0
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
4.新启动 OpenVPN 服务
systemctl restart openvpn
docker run -d \
  --name=wg-client2 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  -v /mnt/wg0:/etc/wireguard/wg0 \
  weejewel/wg-easy
docker run -d \
  --name=wg-wireguard \
  -e WG_HOST=10.0.0.1 \
  -e PASSWORD= \
  --network host \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
docker run -d \
  --name=wg-easy3 \
  --network host \
  --privileged \
  -e WG_HOST=39.174.229.143 \
  -e PASSWORD= \
  -e WG_PERSISTENT_KEEPALIVE=25 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
network:
  ethernets:
    eth0:  # 请替换为你的实际网卡名称
      dhcp4: no
      addresses:
        - 192.168.0.219/24  # 设置静态 IP
      gateway4: 192.168.0.8  # 设置网关
      nameservers:
        addresses:
          - 211.140.13.188
  version: 2
ip route add 192.168.200.0/24 via 10.8.0.1 dev tun0
iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE
iptables -A FORWARD -i tun0 -o eth1 -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A FORWARD -i eth1 -o tun0 -j ACCEPT


docker run -d \
  --name=wireguard-client \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -v /mnt:/config \
  -v /lib/modules:/lib/modules \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  lscr.io/linuxserver/wireguard:latest

enp1s0    enx00e04c360351
network:
  version: 2
  renderer: networkd
  ethernets:
    eth0:
      dhcp4: yes
      dhcp6: no
    enx00e04c360351:
      addresses:
        - 10.131.61.111/24
      dhcp4: no
sudo iptables -t nat -A POSTROUTING -o enp1s0 -j MASQUERADE
sudo iptables -A FORWARD -i enx00e04c360351 -o enp1s0 -j ACCEPT
sudo iptables -A FORWARD -i enp1s0 -o enx00e04c360351 -m state --state RELATED,ESTABLISHED -j ACCEPT
ip route add 22.8.144.97 via 10.130.61.1 dev enx00e04c360351
ip route add 22.8.144.97 via 10.131.61.1 dev br-lan  
ip route add 22.8.144.97 via 10.0.0.5 dev wireguard 
22.8.144.97
ip route add 22.8.144.97 via 192.168.0.8 dev eth0
39.174.229.143
10.0.0.0/24
uci show firewall | grep '@redirect'
docker run -d \
  --name=transmission \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -p 80:9091 \
  -p 51413:51413 \
  -p 51413:51413/udp \
  -v /home/download:/downloads \
  --restart unless-stopped \
  lscr.io/linuxserver/transmission:latest

docker run --restart always --name openwrt -d --network macnet --privileged --ip 10.1.25.193 ophub/openwrt-aarch64:latest
uci set zerotier.global.enabled='1'
uci delete zerotier.earth
uci set zerotier.openwrt_network=network
uci set zerotier.openwrt_network.id='856127940c66f22d'
uci commit zerotier
ip link set  eth0 promisc on
docker network create -d macvlan --subnet=192.168.50.0/24 --gateway=192.168.50.1 -o parent=br-lan  mynet
docker run  --name openwrt --restart unless-stopped -d --network mynet    --privileged --ip 192.168.50.314  openwrt  /sbin/init
docker run -d \
  --name=resilio-sync \
  -p 8888:8888 \
  -p 55555:55555 \
  -v /mnt/sda1/resilio:/mnt/sync \
  -v /mnt/sda1/resilio-config:/config \
  --restart unless-stopped \
  resilio/sync

user  root;
worker_processes  1;

events {
    worker_connections  1024;
}

stream {
    upstream rdp_backend {
        server 192.168.50.168:3389;  # 远程 Windows 11 的 IP
    }

    server {
        listen 3389;
        proxy_pass rdp_backend;
        proxy_timeout 10m;
        proxy_connect_timeout 10s;
    }
}

http {
    include       mime.types;
    default_type  application/octet-stream;
    sendfile        on;
    keepalive_timeout  65;

    server {
        listen       85;
        server_name  localhost;
        charset utf-8;

        location / {
            root   /usr/share/nginx/html;
            autoindex on;
        }

        location ~* ^.*\.txt$ {
            return 404;
        }

        error_page   500 502 503 504  /50x.html;
        location = /50x.html {
            root   /usr/share/nginx/html;
        }
    }
}


c0: 20250204202213-2virs7k
c2: update
c3: 复制修改版
c5: 2025-03-18-135234-update/20250204202137-3g13i3l/20250204202213-2virs7k.sy
c6: 1742277154
c4:
通过 iPhone 镜像从 Mac 使用 iPhone
魔兽争霸:https://www.123pan.com/s/nVxFjv-fkwd3.html
dd if=openwrt-24.10.0-armsr-armv8-generic-ext4-combined-efi.img of=/dev/mmcblk2 bs=4M
docker dockerd luci-lib-docker docker-compose
docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
dd if=/dev/sda of=/root/openwrt24.img bs=4M status=progress

docker run -d  -v /mnt/data1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d \
  --name=qbittorrent \
  -e PUID=0 \
  -e PGID=0 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 1000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/usb1_2-1:/config \
  -v /mnt/usb1_2-1/download:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

docker run -d \
  --name=qbittorrent \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 1000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/usb1_2-1/download:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

dd if=istoreo.img of=/dev/sda bs=4M
docker run -d --name=xunlei --hostname=NNN1 --net=host -v /mnt/data2/configxunl:/xunlei/config -v /mnt/data2:/xunlei/downloads --restart=unless-stopped --privileged cnk3x/xunlei:latest
docker run -d --privileged  -v /mnt/:/xunlei/downloads -p 2345:2345 cnk3x/xunlei
docker run -d -v /mnt/usb1/siyuan:/siyuan/workspace  -e PUID=$UID  -e PGID=$GID  -p 6806:6806 b3log/siyuan  --workspace=/siyuan/workspace/ --accessAuthCode=xxx
docker run -d --name=siyuan -v /mnt/usb1_2-1/siyuan:/siyuan/workspace -p 2000:6806 --restart always  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d --name syncthing  --restart always -p 3000:8384 -p 22000:22000/tcp -p 22000:22000/udp  -p 21027:21027/udp -v /mnt/config-sync:/var/syncthing/config -v /mnt:/var/syncthing/data syncthing/syncthing
docker run -d \
  --name syncthing \
  --restart always \
  -p 8384:8384 \
  -p 22000:22000/tcp \
  -p 22000:22000/udp \
  -p 21027:21027/udp \
  -v /mnt/usb2/syncthing/config:/var/syncthing/config \
  -v /mnt/usb2/syncthing/:/var/syncthing/data \
  syncthing/syncthing
docker run -d --name=samba  --restart unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NNN"  -v "/mnt:/storage" dockurr/samba
opkg install fdisk block-mount unzip zerotier samba4-server samba4-utils luci-app-samba4 openssh-sftp-server openvpn-openssl luci-app-openvpn wireguard-tools kmod-wireguard luci-proto-wireguard
mkdir -p /tmp/introot
mkdir -p /tmp/extroot
mount --bind / /tmp/introot
mount /dev/sda4 /tmp/extroot
tar -C /tmp/introot -cvf - . | tar -C /tmp/extroot -xf -
umount /tmp/introot
umount /tmp/extroot
docker run -d --name=samba --restart=unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NBBN"  -v "/mnt/:/storage" dockurr/samba
network:
  version: 2
  renderer: networkd
  wifis:
    wlp2s0:
      dhcp4: no
      addresses:
        - 192.168.0.124/24  # 这里改成你想要的静态 IP
      gateway4: 192.168.0.8  # 你的网关 IP（通常是路由器 IP）
      nameservers:
        addresses:
          - 211.140.13.188   
          - 114.114.114.114  # 114 DNS
      access-points:
        "boci1":
          password: "a1b2c3d4"

docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
docker run --restart always --name openwrt1 -d --network macnet --privileged --ip 192.168.0.124   openwrt /sbin/init
docker run -d \
  --name=clash \
  -v /root/clash.yaml: /root/.config/clash/config.yaml \
  -p 7890:7890 \
  -p 9090:9090 \
  --restart unless-stopped \
  dreamacro/clash

安装官方最新版本：
curl -fsSL https://get.docker.com | bash
docker import rootfs.tar.gz my-custom-image
docker run -d \
  --name openwrt \
  --network host \
  --privileged \
  openwrt
docker run --restart always --name openwrt -p 80:80 -d --network host --privileged openwrt /sbin/init
允许 ZeroTier 网络访问本地网络
sudo iptables -A FORWARD -s 192.168.192.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 192.168.0.0/24 -d 192.168.192.0/24 -j ACCEPT
如果局域网设备默认网关不是 Ubuntu，需要 NAT
sudo iptables -t nat -A POSTROUTING -s 192.168.192.0/24 -d 192.168.0.0/24 -j MASQUERADE
eroTier 网络
192.168.0.0/24 via 192.168.191.112
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
ip route add 192.168.50.0/24 via 10.8.0.1 dev tun0
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
4.新启动 OpenVPN 服务
systemctl restart openvpn
docker run -d \
  --name=wg-client2 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  -v /mnt/wg0:/etc/wireguard/wg0 \
  weejewel/wg-easy
docker run -d \
  --name=wg-wireguard \
  -e WG_HOST=10.0.0.1 \
  -e PASSWORD= \
  --network host \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
docker run -d \
  --name=wg-easy3 \
  --network host \
  --privileged \
  -e WG_HOST=39.174.229.143 \
  -e PASSWORD= \
  -e WG_PERSISTENT_KEEPALIVE=25 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
network:
  ethernets:
    eth0:  # 请替换为你的实际网卡名称
      dhcp4: no
      addresses:
        - 192.168.0.219/24  # 设置静态 IP
      gateway4: 192.168.0.8  # 设置网关
      nameservers:
        addresses:
          - 211.140.13.188
  version: 2
ip route add 192.168.200.0/24 via 10.8.0.1 dev tun0
iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE
iptables -A FORWARD -i tun0 -o eth1 -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A FORWARD -i eth1 -o tun0 -j ACCEPT


docker run -d \
  --name=wireguard-client \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -v /mnt:/config \
  -v /lib/modules:/lib/modules \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  lscr.io/linuxserver/wireguard:latest

enp1s0    enx00e04c360351
network:
  version: 2
  renderer: networkd
  ethernets:
    eth0:
      dhcp4: yes
      dhcp6: no
    enx00e04c360351:
      addresses:
        - 10.131.61.111/24
      dhcp4: no
sudo iptables -t nat -A POSTROUTING -o enp1s0 -j MASQUERADE
sudo iptables -A FORWARD -i enx00e04c360351 -o enp1s0 -j ACCEPT
sudo iptables -A FORWARD -i enp1s0 -o enx00e04c360351 -m state --state RELATED,ESTABLISHED -j ACCEPT
ip route add 22.8.144.97 via 10.130.61.1 dev enx00e04c360351
ip route add 22.8.144.97 via 10.131.61.1 dev br-lan  
ip route add 22.8.144.97 via 10.0.0.5 dev wireguard 
22.8.144.97
ip route add 22.8.144.97 via 192.168.0.8 dev eth0
39.174.229.143
10.0.0.0/24
uci show firewall | grep '@redirect'
docker run -d \
  --name=transmission \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -p 80:9091 \
  -p 51413:51413 \
  -p 51413:51413/udp \
  -v /home/download:/downloads \
  --restart unless-stopped \
  lscr.io/linuxserver/transmission:latest

docker run --restart always --name openwrt -d --network macnet --privileged --ip 10.1.25.193 ophub/openwrt-aarch64:latest
uci set zerotier.global.enabled='1'
uci delete zerotier.earth
uci set zerotier.openwrt_network=network
uci set zerotier.openwrt_network.id='856127940c66f22d'
uci commit zerotier
ip link set  eth0 promisc on
docker network create -d macvlan --subnet=192.168.50.0/24 --gateway=192.168.50.1 -o parent=br-lan  mynet
docker run  --name openwrt --restart unless-stopped -d --network mynet    --privileged --ip 192.168.50.314  openwrt  /sbin/init
docker run -d \
  --name=resilio-sync \
  -p 8888:8888 \
  -p 55555:55555 \
  -v /mnt/sda1/resilio:/mnt/sync \
  -v /mnt/sda1/resilio-config:/config \
  --restart unless-stopped \
  resilio/sync

user  root;
worker_processes  1;

events {
    worker_connections  1024;
}

stream {
    upstream rdp_backend {
        server 10.1.25.217:3389;  # 远程 Windows 11 的 IP
    }

    server {
        listen 3389;
        proxy_pass rdp_backend;
        proxy_timeout 10m;
        proxy_connect_timeout 10s;
    }
}

http {
    include       mime.types;
    default_type  application/octet-stream;
    sendfile        on;
    keepalive_timeout  65;

    server {
        listen       85;
        server_name  localhost;
        charset utf-8;

        location / {
            root   /usr/share/nginx/html;
            autoindex on;
        }

        location ~* ^.*\.txt$ {
            return 404;
        }

        error_page   500 502 503 504  /50x.html;
        location = /50x.html {
            root   /usr/share/nginx/html;
        }
    }
}


c0: 20250204202213-2virs7k
c2: update
c3: 复制修改版
c5: 2025-03-18-140234-update/20250204202137-3g13i3l/20250204202213-2virs7k.sy
c6: 1742277754
c4:
通过 iPhone 镜像从 Mac 使用 iPhone
魔兽争霸:https://www.123pan.com/s/nVxFjv-fkwd3.html
dd if=openwrt-24.10.0-armsr-armv8-generic-ext4-combined-efi.img of=/dev/mmcblk2 bs=4M
docker dockerd luci-lib-docker docker-compose
docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
dd if=/dev/sda of=/root/openwrt24.img bs=4M status=progress

docker run -d  -v /mnt/data1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d \
  --name=qbittorrent \
  -e PUID=0 \
  -e PGID=0 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 1000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/usb1_2-1:/config \
  -v /mnt/usb1_2-1/download:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

docker run -d \
  --name=qbittorrent \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 1000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/usb1_2-1/download:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

dd if=istoreo.img of=/dev/sda bs=4M
docker run -d --name=xunlei --hostname=NNN1 --net=host -v /mnt/data2/configxunl:/xunlei/config -v /mnt/data2:/xunlei/downloads --restart=unless-stopped --privileged cnk3x/xunlei:latest
docker run -d --privileged  -v /mnt/:/xunlei/downloads -p 2345:2345 cnk3x/xunlei
docker run -d -v /mnt/usb1/siyuan:/siyuan/workspace  -e PUID=$UID  -e PGID=$GID  -p 6806:6806 b3log/siyuan  --workspace=/siyuan/workspace/ --accessAuthCode=xxx
docker run -d --name=siyuan -v /mnt/usb1_2-1/siyuan:/siyuan/workspace -p 2000:6806 --restart always  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d --name syncthing  --restart always -p 3000:8384 -p 22000:22000/tcp -p 22000:22000/udp  -p 21027:21027/udp -v /mnt/config-sync:/var/syncthing/config -v /mnt:/var/syncthing/data syncthing/syncthing
docker run -d \
  --name syncthing \
  --restart always \
  -p 8384:8384 \
  -p 22000:22000/tcp \
  -p 22000:22000/udp \
  -p 21027:21027/udp \
  -v /mnt/usb2/syncthing/config:/var/syncthing/config \
  -v /mnt/usb2/syncthing/:/var/syncthing/data \
  syncthing/syncthing
docker run -d --name=samba  --restart unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NNN"  -v "/mnt:/storage" dockurr/samba
opkg install fdisk block-mount unzip zerotier samba4-server samba4-utils luci-app-samba4 openssh-sftp-server openvpn-openssl luci-app-openvpn wireguard-tools kmod-wireguard luci-proto-wireguard
mkdir -p /tmp/introot
mkdir -p /tmp/extroot
mount --bind / /tmp/introot
mount /dev/sda4 /tmp/extroot
tar -C /tmp/introot -cvf - . | tar -C /tmp/extroot -xf -
umount /tmp/introot
umount /tmp/extroot
docker run -d --name=samba --restart=unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NBBN"  -v "/mnt/:/storage" dockurr/samba
network:
  version: 2
  renderer: networkd
  wifis:
    wlp2s0:
      dhcp4: no
      addresses:
        - 192.168.0.124/24  # 这里改成你想要的静态 IP
      gateway4: 192.168.0.8  # 你的网关 IP（通常是路由器 IP）
      nameservers:
        addresses:
          - 211.140.13.188   
          - 114.114.114.114  # 114 DNS
      access-points:
        "boci1":
          password: "a1b2c3d4"

docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
docker run --restart always --name openwrt1 -d --network macnet --privileged --ip 192.168.0.124   openwrt /sbin/init
docker run -d \
  --name=clash \
  -v /root/clash.yaml: /root/.config/clash/config.yaml \
  -p 7890:7890 \
  -p 9090:9090 \
  --restart unless-stopped \
  dreamacro/clash

安装官方最新版本：
curl -fsSL https://get.docker.com | bash
docker import rootfs.tar.gz my-custom-image
docker run -d \
  --name openwrt \
  --network host \
  --privileged \
  openwrt
docker run --restart always --name openwrt -p 80:80 -d --network host --privileged openwrt /sbin/init
允许 ZeroTier 网络访问本地网络
sudo iptables -A FORWARD -s 192.168.192.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 192.168.0.0/24 -d 192.168.192.0/24 -j ACCEPT
如果局域网设备默认网关不是 Ubuntu，需要 NAT
sudo iptables -t nat -A POSTROUTING -s 192.168.192.0/24 -d 192.168.0.0/24 -j MASQUERADE
eroTier 网络
192.168.0.0/24 via 192.168.191.112
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
ip route add 192.168.50.0/24 via 10.8.0.1 dev tun0
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
4.新启动 OpenVPN 服务
systemctl restart openvpn
docker run -d \
  --name=wg-client2 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  -v /mnt/wg0:/etc/wireguard/wg0 \
  weejewel/wg-easy
docker run -d \
  --name=wg-wireguard \
  -e WG_HOST=10.0.0.1 \
  -e PASSWORD= \
  --network host \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
docker run -d \
  --name=wg-easy3 \
  --network host \
  --privileged \
  -e WG_HOST=39.174.229.143 \
  -e PASSWORD= \
  -e WG_PERSISTENT_KEEPALIVE=25 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
network:
  ethernets:
    eth0:  # 请替换为你的实际网卡名称
      dhcp4: no
      addresses:
        - 192.168.0.219/24  # 设置静态 IP
      gateway4: 192.168.0.8  # 设置网关
      nameservers:
        addresses:
          - 211.140.13.188
  version: 2
ip route add 192.168.200.0/24 via 10.8.0.1 dev tun0
iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE
iptables -A FORWARD -i tun0 -o eth1 -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A FORWARD -i eth1 -o tun0 -j ACCEPT


docker run -d \
  --name=wireguard-client \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -v /mnt:/config \
  -v /lib/modules:/lib/modules \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  lscr.io/linuxserver/wireguard:latest

enp1s0    enx00e04c360351
network:
  version: 2
  renderer: networkd
  ethernets:
    eth0:
      dhcp4: yes
      dhcp6: no
    enx00e04c360351:
      addresses:
        - 10.131.61.111/24
      dhcp4: no
sudo iptables -t nat -A POSTROUTING -o enp1s0 -j MASQUERADE
sudo iptables -A FORWARD -i enx00e04c360351 -o enp1s0 -j ACCEPT
sudo iptables -A FORWARD -i enp1s0 -o enx00e04c360351 -m state --state RELATED,ESTABLISHED -j ACCEPT
ip route add 22.8.144.97 via 10.130.61.1 dev enx00e04c360351
ip route add 22.8.144.97 via 10.131.61.1 dev br-lan  
ip route add 22.8.144.97 via 10.0.0.5 dev wireguard 
22.8.144.97
ip route add 22.8.144.97 via 192.168.0.8 dev eth0
39.174.229.143
10.0.0.0/24
uci show firewall | grep '@redirect'
docker run -d \
  --name=transmission \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -p 80:9091 \
  -p 51413:51413 \
  -p 51413:51413/udp \
  -v /home/download:/downloads \
  --restart unless-stopped \
  lscr.io/linuxserver/transmission:latest

docker run --restart always --name openwrt -d --network macnet --privileged --ip 10.1.25.193 ophub/openwrt-aarch64:latest
uci set zerotier.global.enabled='1'
uci delete zerotier.earth
uci set zerotier.openwrt_network=network
uci set zerotier.openwrt_network.id='856127940c66f22d'
uci commit zerotier
ip link set  eth0 promisc on
docker network create -d macvlan --subnet=192.168.50.0/24 --gateway=192.168.50.1 -o parent=br-lan  mynet
docker run  --name openwrt --restart unless-stopped -d --network mynet    --privileged --ip 192.168.50.314  openwrt  /sbin/init
docker run -d \
  --name=resilio-sync \
  -p 8888:8888 \
  -p 55555:55555 \
  -v /mnt/sda1/resilio:/mnt/sync \
  -v /mnt/sda1/resilio-config:/config \
  --restart unless-stopped \
  resilio/sync

user  root;
worker_processes  1;

events {
    worker_connections  1024;
}

stream {
    upstream rdp_backend {
        server 10.1.25.217:3389;  # 远程 Windows 11 的 IP
    }

    server {
        listen 3389;
        proxy_pass rdp_backend;
        proxy_timeout 10m;
        proxy_connect_timeout 10s;
    }
}

http {
    include       mime.types;
    default_type  application/octet-stream;
    sendfile        on;
    keepalive_timeout  65;

    server {
        listen       85;
        server_name  localhost;
        charset utf-8;

        location / {
            root   /usr/share/nginx/html;
            autoindex on;
        }

        location ~* ^.*\.txt$ {
            return 404;
        }

        error_page   500 502 503 504  /50x.html;
        location = /50x.html {
            root   /usr/share/nginx/html;
        }
    }
}
docker run -d --name nginx   -p 3389:3389  -p 85:85 -v /root/nginx.conf:/etc/nginx/nginx.conf:ro nginx


c0: 20250204202213-2virs7k
c2: update
c3: 复制修改版
c5: 2025-03-31-133234-update/20250204202137-3g13i3l/20250204202213-2virs7k.sy
c6: 1743399154
c4:
通过 iPhone 镜像从 Mac 使用 iPhone
魔兽争霸:https://www.123pan.com/s/nVxFjv-fkwd3.html
dd if=openwrt-24.10.0-armsr-armv8-generic-ext4-combined-efi.img of=/dev/mmcblk2 bs=4M
docker dockerd luci-lib-docker docker-compose
docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
dd if=/dev/sdb of=/dev/sda bs=4M status=progress

docker run -d  -v /mnt/data1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d \
  --name=qbittorrent \
  -e PUID=0 \
  -e PGID=0 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 1000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/usb1_2-1:/config \
  -v /mnt/usb1_2-1/download:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

docker run -d \
  --name=qbittorrent \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 1000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/usb1_2-1/download:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

dd if=istoreo.img of=/dev/sda bs=4M
docker run -d --name=xunlei --hostname=NNN1 --net=host -v /mnt/data2/configxunl:/xunlei/config -v /mnt/data2:/xunlei/downloads --restart=unless-stopped --privileged cnk3x/xunlei:latest
docker run -d --privileged  -v /mnt/:/xunlei/downloads -p 2345:2345 cnk3x/xunlei
docker run -d -v /mnt/usb1/siyuan:/siyuan/workspace  -e PUID=$UID  -e PGID=$GID  -p 6806:6806 b3log/siyuan  --workspace=/siyuan/workspace/ --accessAuthCode=xxx
docker run -d --name=siyuan -v /mnt/usb1_2-1/siyuan:/siyuan/workspace -p 2000:6806 --restart always  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d --name syncthing  --restart always -p 3000:8384 -p 22000:22000/tcp -p 22000:22000/udp  -p 21027:21027/udp -v /mnt/config-sync:/var/syncthing/config -v /mnt:/var/syncthing/data syncthing/syncthing
docker run -d \
  --name syncthing \
  --restart always \
  -p 8384:8384 \
  -p 22000:22000/tcp \
  -p 22000:22000/udp \
  -p 21027:21027/udp \
  -v /mnt/usb2/syncthing/config:/var/syncthing/config \
  -v /mnt/usb2/syncthing/:/var/syncthing/data \
  syncthing/syncthing
docker run -d --name=samba  --restart unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NNN"  -v "/mnt:/storage" dockurr/samba
opkg install fdisk block-mount unzip zerotier samba4-server samba4-utils luci-app-samba4 openssh-sftp-server openvpn-openssl luci-app-openvpn wireguard-tools kmod-wireguard luci-proto-wireguard
mkdir -p /tmp/introot
mkdir -p /tmp/extroot
mount --bind / /tmp/introot
mount /dev/sda4 /tmp/extroot
tar -C /tmp/introot -cvf - . | tar -C /tmp/extroot -xf -
umount /tmp/introot
umount /tmp/extroot
docker run -d --name=samba --restart=unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NBBN"  -v "/mnt/:/storage" dockurr/samba
network:
  version: 2
  renderer: networkd
  wifis:
    wlp2s0:
      dhcp4: no
      addresses:
        - 192.168.0.124/24  # 这里改成你想要的静态 IP
      gateway4: 192.168.0.8  # 你的网关 IP（通常是路由器 IP）
      nameservers:
        addresses:
          - 211.140.13.188   
          - 114.114.114.114  # 114 DNS
      access-points:
        "boci1":
          password: "a1b2c3d4"

docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
docker run --restart always --name openwrt1 -d --network macnet --privileged --ip 192.168.0.124   openwrt /sbin/init
docker run -d \
  --name=clash \
  -v /root/clash.yaml: /root/.config/clash/config.yaml \
  -p 7890:7890 \
  -p 9090:9090 \
  --restart unless-stopped \
  dreamacro/clash

安装官方最新版本：
curl -fsSL https://get.docker.com | bash
docker import rootfs.tar.gz my-custom-image
docker run -d \
  --name openwrt \
  --network host \
  --privileged \
  openwrt
docker run --restart always --name openwrt -p 80:80 -d --network host --privileged openwrt /sbin/init
允许 ZeroTier 网络访问本地网络
sudo iptables -A FORWARD -s 192.168.192.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 192.168.0.0/24 -d 192.168.192.0/24 -j ACCEPT
如果局域网设备默认网关不是 Ubuntu，需要 NAT
sudo iptables -t nat -A POSTROUTING -s 192.168.192.0/24 -d 192.168.0.0/24 -j MASQUERADE
eroTier 网络
192.168.0.0/24 via 192.168.191.112
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
ip route add 192.168.50.0/24 via 10.8.0.1 dev tun0
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
4.新启动 OpenVPN 服务
systemctl restart openvpn
docker run -d \
  --name=wg-client2 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  -v /mnt/wg0:/etc/wireguard/wg0 \
  weejewel/wg-easy
docker run -d \
  --name=wg-wireguard \
  -e WG_HOST=10.0.0.1 \
  -e PASSWORD= \
  --network host \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
docker run -d \
  --name=wg-easy3 \
  --network host \
  --privileged \
  -e WG_HOST=39.174.229.143 \
  -e PASSWORD= \
  -e WG_PERSISTENT_KEEPALIVE=25 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
network:
  ethernets:
    eth0:  # 请替换为你的实际网卡名称
      dhcp4: no
      addresses:
        - 192.168.0.219/24  # 设置静态 IP
      gateway4: 192.168.0.8  # 设置网关
      nameservers:
        addresses:
          - 211.140.13.188
  version: 2
ip route add 192.168.200.0/24 via 10.8.0.1 dev tun0
iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE
iptables -A FORWARD -i tun0 -o eth1 -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A FORWARD -i eth1 -o tun0 -j ACCEPT


docker run -d \
  --name=wireguard-client \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -v /mnt:/config \
  -v /lib/modules:/lib/modules \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  lscr.io/linuxserver/wireguard:latest

enp1s0    enx00e04c360351
network:
  version: 2
  renderer: networkd
  ethernets:
    eth0:
      dhcp4: yes
      dhcp6: no
    enx00e04c360351:
      addresses:
        - 10.131.61.111/24
      dhcp4: no
sudo iptables -t nat -A POSTROUTING -o enp1s0 -j MASQUERADE
sudo iptables -A FORWARD -i enx00e04c360351 -o enp1s0 -j ACCEPT
sudo iptables -A FORWARD -i enp1s0 -o enx00e04c360351 -m state --state RELATED,ESTABLISHED -j ACCEPT
ip route add 22.8.144.97 via 10.130.61.1 dev enx00e04c360351
ip route add 22.8.144.97 via 10.131.61.1 dev br-lan  
ip route add 22.8.144.97 via 10.0.0.5 dev wireguard 
22.8.144.97
ip route add 22.8.144.97 via 192.168.0.8 dev eth0
39.174.229.143
10.0.0.0/24
uci show firewall | grep '@redirect'
docker run -d \
  --name=transmission \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -p 80:9091 \
  -p 51413:51413 \
  -p 51413:51413/udp \
  -v /home/download:/downloads \
  --restart unless-stopped \
  lscr.io/linuxserver/transmission:latest

docker run --restart always --name openwrt -d --network macnet --privileged --ip 10.1.25.193 ophub/openwrt-aarch64:latest
uci set zerotier.global.enabled='1'
uci delete zerotier.earth
uci set zerotier.openwrt_network=network
uci set zerotier.openwrt_network.id='856127940c66f22d'
uci commit zerotier
ip link set  eth0 promisc on
docker network create -d macvlan --subnet=192.168.50.0/24 --gateway=192.168.50.1 -o parent=br-lan  mynet
docker run  --name openwrt --restart unless-stopped -d --network mynet    --privileged --ip 192.168.50.314  openwrt  /sbin/init
docker run -d \
  --name=resilio-sync \
  -p 8888:8888 \
  -p 55555:55555 \
  -v /mnt/sda1/resilio:/mnt/sync \
  -v /mnt/sda1/resilio-config:/config \
  --restart unless-stopped \
  resilio/sync

user  root;
worker_processes  1;

events {
    worker_connections  1024;
}

stream {
    upstream rdp_backend {
        server 10.1.25.217:3389;  # 远程 Windows 11 的 IP
    }

    server {
        listen 3389;
        proxy_pass rdp_backend;
        proxy_timeout 10m;
        proxy_connect_timeout 10s;
    }
}

http {
    include       mime.types;
    default_type  application/octet-stream;
    sendfile        on;
    keepalive_timeout  65;

    server {
        listen       85;
        server_name  localhost;
        charset utf-8;

        location / {
            root   /usr/share/nginx/html;
            autoindex on;
        }

        location ~* ^.*\.txt$ {
            return 404;
        }

        error_page   500 502 503 504  /50x.html;
        location = /50x.html {
            root   /usr/share/nginx/html;
        }
    }
}
docker run -d --name nginx   -p 3389:3389  -p 85:85 -v /root/nginx.conf:/etc/nginx/nginx.conf:ro nginx


c0: 20250204202213-2virs7k
c2: update
c3: 复制修改版
c5: 2025-03-31-144234-update/20250204202137-3g13i3l/20250204202213-2virs7k.sy
c6: 1743403354
c4:
通过 iPhone 镜像从 Mac 使用 iPhone
魔兽争霸:https://www.123pan.com/s/nVxFjv-fkwd3.html
dd if=openwrt-24.10.0-armsr-armv8-generic-ext4-combined-efi.img of=/dev/mmcblk2 bs=4M
docker dockerd luci-lib-docker docker-compose
docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
dd if=/dev/sdb of=/dev/sda bs=4M status=progress
dd if=/dev/sdb of=/dev/sdb bs=4M
docker run -d  -v /mnt/data1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d \
  --name=qbittorrent \
  -e PUID=0 \
  -e PGID=0 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 1000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/usb1_2-1:/config \
  -v /mnt/usb1_2-1/download:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

docker run -d \
  --name=qbittorrent \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 1000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/usb1_2-1/download:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

dd if=istoreo.img of=/dev/sda bs=4M
docker run -d --name=xunlei --hostname=NNN1 --net=host -v /mnt/data2/configxunl:/xunlei/config -v /mnt/data2:/xunlei/downloads --restart=unless-stopped --privileged cnk3x/xunlei:latest
docker run -d --privileged  -v /mnt/:/xunlei/downloads -p 2345:2345 cnk3x/xunlei
docker run -d -v /mnt/usb1/siyuan:/siyuan/workspace  -e PUID=$UID  -e PGID=$GID  -p 6806:6806 b3log/siyuan  --workspace=/siyuan/workspace/ --accessAuthCode=xxx
docker run -d --name=siyuan -v /mnt/usb1_2-1/siyuan:/siyuan/workspace -p 2000:6806 --restart always  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d --name syncthing  --restart always -p 3000:8384 -p 22000:22000/tcp -p 22000:22000/udp  -p 21027:21027/udp -v /mnt/config-sync:/var/syncthing/config -v /mnt:/var/syncthing/data syncthing/syncthing
docker run -d \
  --name syncthing \
  --restart always \
  -p 8384:8384 \
  -p 22000:22000/tcp \
  -p 22000:22000/udp \
  -p 21027:21027/udp \
  -v /mnt/usb2/syncthing/config:/var/syncthing/config \
  -v /mnt/usb2/syncthing/:/var/syncthing/data \
  syncthing/syncthing
docker run -d --name=samba  --restart unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NNN"  -v "/mnt:/storage" dockurr/samba
opkg install fdisk block-mount unzip zerotier samba4-server samba4-utils luci-app-samba4 openssh-sftp-server openvpn-openssl luci-app-openvpn wireguard-tools kmod-wireguard luci-proto-wireguard
mkdir -p /tmp/introot
mkdir -p /tmp/extroot
mount --bind / /tmp/introot
mount /dev/sda4 /tmp/extroot
tar -C /tmp/introot -cvf - . | tar -C /tmp/extroot -xf -
umount /tmp/introot
umount /tmp/extroot
docker run -d --name=samba --restart=unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NBBN"  -v "/mnt/:/storage" dockurr/samba
network:
  version: 2
  renderer: networkd
  wifis:
    wlp2s0:
      dhcp4: no
      addresses:
        - 192.168.0.124/24  # 这里改成你想要的静态 IP
      gateway4: 192.168.0.8  # 你的网关 IP（通常是路由器 IP）
      nameservers:
        addresses:
          - 211.140.13.188   
          - 114.114.114.114  # 114 DNS
      access-points:
        "boci1":
          password: "a1b2c3d4"

docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
docker run --restart always --name openwrt1 -d --network macnet --privileged --ip 192.168.0.124   openwrt /sbin/init
docker run -d \
  --name=clash \
  -v /root/clash.yaml: /root/.config/clash/config.yaml \
  -p 7890:7890 \
  -p 9090:9090 \
  --restart unless-stopped \
  dreamacro/clash

安装官方最新版本：
curl -fsSL https://get.docker.com | bash
docker import rootfs.tar.gz my-custom-image
docker run -d \
  --name openwrt \
  --network host \
  --privileged \
  openwrt
docker run --restart always --name openwrt -p 80:80 -d --network host --privileged openwrt /sbin/init
允许 ZeroTier 网络访问本地网络
sudo iptables -A FORWARD -s 192.168.192.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 192.168.0.0/24 -d 192.168.192.0/24 -j ACCEPT
如果局域网设备默认网关不是 Ubuntu，需要 NAT
sudo iptables -t nat -A POSTROUTING -s 192.168.192.0/24 -d 192.168.0.0/24 -j MASQUERADE
eroTier 网络
192.168.0.0/24 via 192.168.191.112
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
ip route add 192.168.50.0/24 via 10.8.0.1 dev tun0
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
4.新启动 OpenVPN 服务
systemctl restart openvpn
docker run -d \
  --name=wg-client2 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  -v /mnt/wg0:/etc/wireguard/wg0 \
  weejewel/wg-easy
docker run -d \
  --name=wg-wireguard \
  -e WG_HOST=10.0.0.1 \
  -e PASSWORD= \
  --network host \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
docker run -d \
  --name=wg-easy3 \
  --network host \
  --privileged \
  -e WG_HOST=39.174.229.143 \
  -e PASSWORD= \
  -e WG_PERSISTENT_KEEPALIVE=25 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
network:
  ethernets:
    eth0:  # 请替换为你的实际网卡名称
      dhcp4: no
      addresses:
        - 192.168.0.219/24  # 设置静态 IP
      gateway4: 192.168.0.8  # 设置网关
      nameservers:
        addresses:
          - 211.140.13.188
  version: 2
ip route add 192.168.200.0/24 via 10.8.0.1 dev tun0
iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE
iptables -A FORWARD -i tun0 -o eth1 -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A FORWARD -i eth1 -o tun0 -j ACCEPT


docker run -d \
  --name=wireguard-client \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -v /mnt:/config \
  -v /lib/modules:/lib/modules \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  lscr.io/linuxserver/wireguard:latest

enp1s0    enx00e04c360351
network:
  version: 2
  renderer: networkd
  ethernets:
    eth0:
      dhcp4: yes
      dhcp6: no
    enx00e04c360351:
      addresses:
        - 10.131.61.111/24
      dhcp4: no
sudo iptables -t nat -A POSTROUTING -o enp1s0 -j MASQUERADE
sudo iptables -A FORWARD -i enx00e04c360351 -o enp1s0 -j ACCEPT
sudo iptables -A FORWARD -i enp1s0 -o enx00e04c360351 -m state --state RELATED,ESTABLISHED -j ACCEPT
ip route add 22.8.144.97 via 10.130.61.1 dev enx00e04c360351
ip route add 22.8.144.97 via 10.131.61.1 dev br-lan  
ip route add 22.8.144.97 via 10.0.0.5 dev wireguard 
22.8.144.97
ip route add 22.8.144.97 via 192.168.0.8 dev eth0
39.174.229.143
10.0.0.0/24
uci show firewall | grep '@redirect'
docker run -d \
  --name=transmission \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -p 80:9091 \
  -p 51413:51413 \
  -p 51413:51413/udp \
  -v /home/download:/downloads \
  --restart unless-stopped \
  lscr.io/linuxserver/transmission:latest

docker run --restart always --name openwrt -d --network macnet --privileged --ip 10.1.25.193 ophub/openwrt-aarch64:latest
uci set zerotier.global.enabled='1'
uci delete zerotier.earth
uci set zerotier.openwrt_network=network
uci set zerotier.openwrt_network.id='856127940c66f22d'
uci commit zerotier
ip link set  eth0 promisc on
docker network create -d macvlan --subnet=192.168.50.0/24 --gateway=192.168.50.1 -o parent=br-lan  mynet
docker run  --name openwrt --restart unless-stopped -d --network mynet    --privileged --ip 192.168.50.314  openwrt  /sbin/init
docker run -d \
  --name=resilio-sync \
  -p 8888:8888 \
  -p 55555:55555 \
  -v /mnt/sda1/resilio:/mnt/sync \
  -v /mnt/sda1/resilio-config:/config \
  --restart unless-stopped \
  resilio/sync

user  root;
worker_processes  1;

events {
    worker_connections  1024;
}

stream {
    upstream rdp_backend {
        server 10.1.25.217:3389;  # 远程 Windows 11 的 IP
    }

    server {
        listen 3389;
        proxy_pass rdp_backend;
        proxy_timeout 10m;
        proxy_connect_timeout 10s;
    }
}

http {
    include       mime.types;
    default_type  application/octet-stream;
    sendfile        on;
    keepalive_timeout  65;

    server {
        listen       85;
        server_name  localhost;
        charset utf-8;

        location / {
            root   /usr/share/nginx/html;
            autoindex on;
        }

        location ~* ^.*\.txt$ {
            return 404;
        }

        error_page   500 502 503 504  /50x.html;
        location = /50x.html {
            root   /usr/share/nginx/html;
        }
    }
}
docker run -d --name nginx   -p 3389:3389  -p 85:85 -v /root/nginx.conf:/etc/nginx/nginx.conf:ro nginx


c0: 20250204202213-2virs7k
c2: update
c3: 复制修改版
c5: 2025-03-31-145234-update/20250204202137-3g13i3l/20250204202213-2virs7k.sy
c6: 1743403954
c4:
通过 iPhone 镜像从 Mac 使用 iPhone
魔兽争霸:https://www.123pan.com/s/nVxFjv-fkwd3.html
dd if=openwrt-24.10.0-armsr-armv8-generic-ext4-combined-efi.img of=/dev/mmcblk2 bs=4M
docker dockerd luci-lib-docker docker-compose
docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
dd if=/dev/sdb of=/dev/sda bs=4M status=progress
dd if=/mnt/usb1_1_1-5/Armbian_25.2.3_Uefi-x86_bookworm_current_6.12.20_minimal.img of=/dev/sdb bs=4M
docker run -d  -v /mnt/data1/siyuan:/siyuan/workspace -p 2000:6806  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d \
  --name=qbittorrent \
  -e PUID=0 \
  -e PGID=0 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 1000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/usb1_2-1:/config \
  -v /mnt/usb1_2-1/download:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

docker run -d \
  --name=qbittorrent \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -e WEBUI_PORT=8080 \
  -e TORRENTING_PORT=6881 \
  -p 1000:8080 \
  -p 6881:6881 \
  -p 6881:6881/udp \
  -v /mnt/usb1_2-1/download:/downloads `#optional` \
  --restart unless-stopped \
  lscr.io/linuxserver/qbittorrent:latest

dd if=istoreo.img of=/dev/sda bs=4M
docker run -d --name=xunlei --hostname=NNN1 --net=host -v /mnt/data2/configxunl:/xunlei/config -v /mnt/data2:/xunlei/downloads --restart=unless-stopped --privileged cnk3x/xunlei:latest
docker run -d --privileged  -v /mnt/:/xunlei/downloads -p 2345:2345 cnk3x/xunlei
docker run -d -v /mnt/usb1/siyuan:/siyuan/workspace  -e PUID=$UID  -e PGID=$GID  -p 6806:6806 b3log/siyuan  --workspace=/siyuan/workspace/ --accessAuthCode=xxx
docker run -d --name=siyuan -v /mnt/usb1_2-1/siyuan:/siyuan/workspace -p 2000:6806 --restart always  b3log/siyuan --workspace=/siyuan/workspace/ --accessAuthCode=www
docker run -d --name syncthing  --restart always -p 3000:8384 -p 22000:22000/tcp -p 22000:22000/udp  -p 21027:21027/udp -v /mnt/config-sync:/var/syncthing/config -v /mnt:/var/syncthing/data syncthing/syncthing
docker run -d \
  --name syncthing \
  --restart always \
  -p 8384:8384 \
  -p 22000:22000/tcp \
  -p 22000:22000/udp \
  -p 21027:21027/udp \
  -v /mnt/usb2/syncthing/config:/var/syncthing/config \
  -v /mnt/usb2/syncthing/:/var/syncthing/data \
  syncthing/syncthing
docker run -d --name=samba  --restart unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NNN"  -v "/mnt:/storage" dockurr/samba
opkg install fdisk block-mount unzip zerotier samba4-server samba4-utils luci-app-samba4 openssh-sftp-server openvpn-openssl luci-app-openvpn wireguard-tools kmod-wireguard luci-proto-wireguard
mkdir -p /tmp/introot
mkdir -p /tmp/extroot
mount --bind / /tmp/introot
mount /dev/sda4 /tmp/extroot
tar -C /tmp/introot -cvf - . | tar -C /tmp/extroot -xf -
umount /tmp/introot
umount /tmp/extroot
docker run -d --name=samba --restart=unless-stopped -p 445:445 -e "USER=pxx" -e "PASS=888888"  -e  "NAME=NBBN"  -v "/mnt/:/storage" dockurr/samba
network:
  version: 2
  renderer: networkd
  wifis:
    wlp2s0:
      dhcp4: no
      addresses:
        - 192.168.0.124/24  # 这里改成你想要的静态 IP
      gateway4: 192.168.0.8  # 你的网关 IP（通常是路由器 IP）
      nameservers:
        addresses:
          - 211.140.13.188   
          - 114.114.114.114  # 114 DNS
      access-points:
        "boci1":
          password: "a1b2c3d4"

docker run --name=webdav -d -e USERNAME=pxx -e PASSWORD=888888 -v /mnt:/webdav -p 81:80 idelsink/webdav
docker run --restart always --name openwrt1 -d --network macnet --privileged --ip 192.168.0.124   openwrt /sbin/init
docker run -d \
  --name=clash \
  -v /root/clash.yaml: /root/.config/clash/config.yaml \
  -p 7890:7890 \
  -p 9090:9090 \
  --restart unless-stopped \
  dreamacro/clash

安装官方最新版本：
curl -fsSL https://get.docker.com | bash
docker import rootfs.tar.gz my-custom-image
docker run -d \
  --name openwrt \
  --network host \
  --privileged \
  openwrt
docker run --restart always --name openwrt -p 80:80 -d --network host --privileged openwrt /sbin/init
允许 ZeroTier 网络访问本地网络
sudo iptables -A FORWARD -s 192.168.192.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 192.168.0.0/24 -d 192.168.192.0/24 -j ACCEPT
如果局域网设备默认网关不是 Ubuntu，需要 NAT
sudo iptables -t nat -A POSTROUTING -s 192.168.192.0/24 -d 192.168.0.0/24 -j MASQUERADE
eroTier 网络
192.168.0.0/24 via 192.168.191.112
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.50.0/24 -j ACCEPT
ip route add 192.168.50.0/24 via 10.8.0.1 dev tun0
sudo iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
sudo iptables -A FORWARD -s 10.8.0.0/24 -d 192.168.0.0/24 -j ACCEPT
4.新启动 OpenVPN 服务
systemctl restart openvpn
docker run -d \
  --name=wg-client2 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  -v /mnt/wg0:/etc/wireguard/wg0 \
  weejewel/wg-easy
docker run -d \
  --name=wg-wireguard \
  -e WG_HOST=10.0.0.1 \
  -e PASSWORD= \
  --network host \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
docker run -d \
  --name=wg-easy3 \
  --network host \
  --privileged \
  -e WG_HOST=39.174.229.143 \
  -e PASSWORD= \
  -e WG_PERSISTENT_KEEPALIVE=25 \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  --restart unless-stopped \
  weejewel/wg-easy
network:
  ethernets:
    eth0:  # 请替换为你的实际网卡名称
      dhcp4: no
      addresses:
        - 192.168.0.219/24  # 设置静态 IP
      gateway4: 192.168.0.8  # 设置网关
      nameservers:
        addresses:
          - 211.140.13.188
  version: 2
ip route add 192.168.200.0/24 via 10.8.0.1 dev tun0
iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE
iptables -A FORWARD -i tun0 -o eth1 -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A FORWARD -i eth1 -o tun0 -j ACCEPT


docker run -d \
  --name=wireguard-client \
  --cap-add=NET_ADMIN \
  --cap-add=SYS_MODULE \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Etc/UTC \
  -v /mnt:/config \
  -v /lib/modules:/lib/modules \
  --sysctl="net.ipv4.conf.all.src_valid_mark=1" \
  --restart unless-stopped \
  lscr.io/linuxserver/wireguard:latest

enp1s0    enx00e04c360351
network:
  version: 2
  renderer: networkd
  ethernets:
    eth0:
      dhcp4: yes
      dhcp6: no
    enx00e04c360351:
      addresses:
        - 10.131.61.111/24
      dhcp4: no
sudo iptables -t nat -A POSTROUTING -o enp1s0 -j MASQUERADE
sudo iptables -A FORWARD -i enx00e04c360351 -o enp1s0 -j ACCEPT
sudo iptables -A FORWARD -i enp1s0 -o enx00e04c360351 -m state --state RELATED,ESTABLISHED -j ACCEPT
ip route add 22.8.144.97 via 10.130.61.1 dev enx00e04c360351
ip route add 22.8.144.97 via 10.131.61.1 dev br-lan  
ip route add 22.8.144.97 via 10.0.0.5 dev wireguard 
22.8.144.97
ip route add 22.8.144.97 via 192.168.0.8 dev eth0
39.174.229.143
10.0.0.0/24
uci show firewall | grep '@redirect'
docker run -d \
  --name=transmission \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -p 80:9091 \
  -p 51413:51413 \
  -p 51413:51413/udp \
  -v /home/download:/downloads \
  --restart unless-stopped \
  lscr.io/linuxserver/transmission:latest

docker run --restart always --name openwrt -d --network macnet --privileged --ip 10.1.25.193 ophub/openwrt-aarch64:latest
uci set zerotier.global.enabled='1'
uci delete zerotier.earth
uci set zerotier.openwrt_network=network
uci set zerotier.openwrt_network.id='856127940c66f22d'
uci commit zerotier
ip link set  eth0 promisc on
docker network create -d macvlan --subnet=192.168.50.0/24 --gateway=192.168.50.1 -o parent=br-lan  mynet
docker run  --name openwrt --restart unless-stopped -d --network mynet    --privileged --ip 192.168.50.314  openwrt  /sbin/init
docker run -d \
  --name=resilio-sync \
  -p 8888:8888 \
  -p 55555:55555 \
  -v /mnt/sda1/resilio:/mnt/sync \
  -v /mnt/sda1/resilio-config:/config \
  --restart unless-stopped \
  resilio/sync

user  root;
worker_processes  1;

events {
    worker_connections  1024;
}

stream {
    upstream rdp_backend {
        server 10.1.25.217:3389;  # 远程 Windows 11 的 IP
    }

    server {
        listen 3389;
        proxy_pass rdp_backend;
        proxy_timeout 10m;
        proxy_connect_timeout 10s;
    }
}

http {
    include       mime.types;
    default_type  application/octet-stream;
    sendfile        on;
    keepalive_timeout  65;

    server {
        listen       85;
        server_name  localhost;
        charset utf-8;

        location / {
            root   /usr/share/nginx/html;
            autoindex on;
        }

        location ~* ^.*\.txt$ {
            return 404;
        }

        error_page   500 502 503 504  /50x.html;
        location = /50x.html {
            root   /usr/share/nginx/html;
        }
    }
}
docker run -d --name nginx   -p 3389:3389  -p 85:85 -v /root/nginx.conf:/etc/nginx/nginx.conf:ro nginx


