在使用docker部署青龍面板前,需要先安裝好docker環境,包括docker引擎和docker-compose。
1. 安裝docker引擎
sudo apt-get update
sudo apt-get install apt-transport-https ca-certificates curl gnupg lsb-release
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo gpg --dearmor -o /usr/share/keyrings/docker-archive-keyring.gpg
echo "deb [arch=amd64 signed-by=/usr/share/keyrings/docker-archive-keyring.gpg] https://download.docker.com/linux/ubuntu \
$(lsb_release -cs) stable" | sudo tee /etc/apt/sources.list.d/docker.list >/dev/null
sudo apt-get update
sudo apt-get install docker-ce docker-ce-cli containerd.io
2. 安裝docker-compose
sudo curl -L "https://github.com/docker/compose/releases/download/1.29.1/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose
sudo chmod +x /usr/local/bin/docker-compose
sudo ln -s /usr/local/bin/docker-compose /usr/bin/docker-compose
3. 下載青龍面板
git clone https://github.com/whyour/qinglong.git
4. 修改配置文件
cd qinglong
cp auth.json.sample auth.json
vim auth.json
在auth.json文件中填寫自己的賬號密碼,格式如下:
{
"url": "https://i.jd.com",
"username": "your_username",
"password": "your_password"
}
5. 啟動服務
docker-compose up -d
啟動后,可以通過瀏覽器訪問青龍面板的地址:http://ip:5700/