Skip to content

Instantly share code, notes, and snippets.

@aa65535
Last active June 4, 2024 10:14
Show Gist options
  • Save aa65535/a48bc61dbf44184d480c88eab3fe9d74 to your computer and use it in GitHub Desktop.
Save aa65535/a48bc61dbf44184d480c88eab3fe9d74 to your computer and use it in GitHub Desktop.
# 定义配置目录, 根据需要修改
CONF_DIR=/etc/xiaoya
mkdir -p $CONF_DIR
# 创建三个配置文件
touch $CONF_DIR/mytoken.txt
touch $CONF_DIR/pikpak.txt
touch $CONF_DIR/guestpass.txt
# 启动容器
docker run -d -p 5678:80 -p 5244:5244 -v $CONF_DIR:/data --restart=always --name=xiaoya xiaoyaliu/alist:latest
# 替换绑定地址为 0.0.0.0
docker exec -it xiaoya sed -i 's/127.0.0.1/0.0.0.0/' /opt/alist/data/config.json
# 确认替换是否成功
docker exec -it xiaoya cat /opt/alist/data/config.json
# 删除配置备份,防止修改被恢复,这里需要等到完全启动后再执行
docker exec -it xiaoya rm -f /var/lib/data.zip
# 查看管理员帐号密码
docker exec -it xiaoya ./alist admin
# 重启容器
docker restart xiaoya
@jixishi
Copy link

jixishi commented May 31, 2024

现在不行了

@cikichen
Copy link

cikichen commented Jun 4, 2024

凉了,只能跑一个原版一个小雅,原版做套娃

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment