玩客云折腾记 Armbian Docker CasaOS Alist CloudDrive Jellyfin HomeAssistant

自打玩客云可以刷入Armbian以来,可玩性极大提高。

Armbian

Releases · hzyitc/armbian-onecloud (github.com)
文件名选类似这样的,后缀是burn是线刷,带mini的是精简版
Armbian_23.02.0-trunk_Onecloud_bullseye_edge_6.2.0.burn.img.xz
参考教程:
https://www.right.com.cn/forum/thread-8246606-1-1.html

更换软件源:(提高速度,与其他Linux系统一致)

nano /etc/apt/sources.list

注释原有软件源,更换为:

# 默认注释了源码镜像以提高 apt update 速度,如有需要可自行取消注释
deb https://mirrors.tuna.tsinghua.edu.cn/debian/ bullseye main contrib non-free
# deb-src https://mirrors.tuna.tsinghua.edu.cn/debian/ bullseye main contrib non-free
deb https://mirrors.tuna.tsinghua.edu.cn/debian/ bullseye-updates main contrib non-free
# deb-src https://mirrors.tuna.tsinghua.edu.cn/debian/ bullseye-updates main contrib non-free
deb https://mirrors.tuna.tsinghua.edu.cn/debian/ bullseye-backports main contrib non-free
# deb-src https://mirrors.tuna.tsinghua.edu.cn/debian/ bullseye-backports main contrib non-free
deb https://mirrors.tuna.tsinghua.edu.cn/debian-security bullseye-security main contrib non-free
# deb-src https://mirrors.tuna.tsinghua.edu.cn/debian-security bullseye-security main contrib non-free

Docker

校验时区是否正确:

date -R

如不正确应修改:

cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime

安装Docker:
(我似乎没有执行这个命令,但依然可以用,猜测是Armbian带了Docker,或是安装CasaOS时自动安装了Docker)

apt install docker.io

CasaOS

一行命令安装:

wget -qO- https://get.casaos.io | bash

Alist

docker run -d --restart=always -v /etc/alist:/opt/alist/data -p 5244:5244 --name="alist" xhofe/alist:latest

随后,在IP:5244打开Web UI使用。

CloudDrive

docker run -d  --name clouddrive --restart unless-stopped --env CLOUDDRIVE_HOME=/Config -v /DATA/Media/CloudNAS:/CloudNAS:shared -v /DATA/Media/CloudNAS/Config:/Config -v /DATA/Media/CloudNAS/Media:/media:shared --network host --pid host --privileged --device /dev/fuse:/dev/fuse cloudnas/clouddrive2-unstable

随后,在IP:19798使用,注意,CloudDrive2不会自动挂载添加的云盘,需手动挂载。

特别注意的是,不要将该容器添加到CasaOS,否则会出现挂载到文件系统后目录为空的问题。(折腾了我很久)

Jellyfin

直接用CasaOS的APP Center安装,但是玩客云配置太差,体验不佳,不建议。

HomeAssistant

docker run -d --name homeassistant --privileged --restart=unless-stopped -e TZ=Asia/Shanghai-v /etc/homeassistant/config:/config --network=host ghcr.io/home-assistant/home-assistant:stable

为了免于抓token的痛苦,安装HACS。

https://hacs.xyz/docs/configuration/basic/

https://github.com/hacs/integration/releases/

ZeroTier

docker run --device=/dev/net/tun --name zerotier --net=host --restart=always --cap-add=NET_ADMIN --cap-add=SYS_ADMIN -v /var/lib/zerotier:/var/lib/zerotier zerotier/zerotier:latest

直到:

onecloud:~:# docker run --device=/dev/net/tun --name zerotier --net=host --restart=always --cap-add=NET_ADMIN --cap-add=SYS_ADMIN -v /var/lib/zerotier:/var/lib/zerotier zerotier/zerotier:latest
Unable to find image 'zerotier/zerotier:latest' locally
latest: Pulling from zerotier/zerotier
d50e868f9a62: Pull complete 
36f31cafcf90: Pull complete 
b6a8599210be: Pull complete 
eb421fbb164c: Pull complete 
e9e53b6fcada: Pull complete 
6bd9a76f5d17: Pull complete 
975df314f72a: Pull complete 
Digest: sha256:591e4772efa17e1a581039cbadaffde03d02e1f58a0d8add1b64d56a2cf99dab
Status: Downloaded newer image for zerotier/zerotier:latest
=> Configuring networks to join
=> Joining networks from command line: []
=> Starting ZeroTier
===> ZeroTier hasn't started, waiting a second
=> Writing healthcheck for networks: []
=> zerotier-cli info: [200 info 8f7250b2ab 1.10.6 OFFLINE]
=> Sleeping infinitely

使用Ctrl+C退出命令。重启容器:

docker restart zerotier

配置:

docker exec zerotier zerotier-cli join <your-net-id>
#加入该组织网络;

docker exec zerotier zerotier-cli leave <your-net-id>
#退出组织网络;

https://my.zerotier.com/network

正在进一步探索使用。估计最后长期使用也就是做个云盘挂载,也挺好的了。

posted @ 2023-06-01 10:32  HAN_Letisl  阅读(5583)  评论(3编辑  收藏  举报