mirror of
https://github.com/Kakune55/Pixel.git
synced 2025-12-16 02:53:55 +08:00
添加了DockerFile
This commit is contained in:
22
README.md
22
README.md
@@ -25,3 +25,25 @@ id 图片id
|
||||
|
||||
## 使用的外部库
|
||||
"github.com/disintegration/imaging" MIT LICENSE
|
||||
|
||||
# 部署
|
||||
## 直接部署
|
||||
- 确保本机拥有go环境
|
||||
- 确保网络良好
|
||||
~~~bash
|
||||
git clone https://github.com/Kakune55/Pixel.git #克隆存储库
|
||||
cd ./Pixel #进入工作目录
|
||||
go build main.go #编译
|
||||
./main #运行
|
||||
~~~
|
||||
## 使用Docker (仅支持Linux-X86_64)
|
||||
### 导入镜像
|
||||
~~~bash
|
||||
wget https://github.com/Kakune55/Pixel/releases/download/v1.0/pixel.tar.gz #版本号仅供参考
|
||||
tar -zxvf pixel.tar.gz #解压
|
||||
docker load pixel.tar #导入镜像
|
||||
~~~
|
||||
### 运行容器
|
||||
~~~bash
|
||||
docker run -d -p <你需要的端口号>:9090 --name:pixel pixel
|
||||
~~~
|
||||
Reference in New Issue
Block a user