Skip to content

☁️兰空图床(Lsky Pro) - Docker自动构建

License

Notifications You must be signed in to change notification settings

gofaquan/lsky-pro-docker

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

52 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Lsky-Pro Docker镜像

每天自动拉取最新代码构建Docker镜像

使用方法

docker run -d \
    --name lsky-pro \
    --restart unless-stopped \
    -p 9080:80 \
    -v /path-to-data:/var/www/html \
    halcyonazure/lsky-pro-docker:latest

Windows内以WSL的方式部署Docker容器

按照 #13 的反馈来看,如果在Windows内创建容器出现了将文件挂载于WSL内,然后出现了重启系统文件未识别的情况,可以将映射目录修改为类似\\wsl$\Ubuntu\path-mount-lsky\的形式

反代HTTPS

如果使用了Nginx反代后,如果出现无法加载图片的问题,可以根据原项目 #317 执行以下指令来手动修改容器内AppServiceProvider.php文件对于HTTPS的支持

Tips:将lskypro改为自己容器的名字

docker exec -it lskypro sed -i '32 a \\\Illuminate\\Support\\Facades\\URL::forceScheme('"'"'https'"'"');' /var/www/html/app/Providers/AppServiceProvider.php

Docker-Compose部署参考

使用MySQL来作为数据库的话可以参考原项目 #256 来创建docker-compose.yaml,参考内容如下:

version: '3'
services:
  lskypro:
    image: halcyonazure/lsky-pro-docker:latest
    restart: unless-stopped
    hostname: lskypro
    container_name: lskypro
    volumes:
      - /data/lsky/web:/var/www/html/
    ports:
      - "9080:80"
    networks:
      - lsky-net

  mysql-lsky:
    image: mysql:5.7.22
    restart: unless-stopped
    # 主机名,可作为"数据库连接地址"
    hostname: mysql-lsky
    # 容器名称
    container_name: mysql-lsky
    # 修改加密规则
    command: --default-authentication-plugin=mysql_native_password
    volumes:
      - /data/lsky/mysql/data:/var/lib/mysql
      - /data/lsky/mysql/conf:/etc/mysql
      - /data/lsky/mysql/log:/var/log/mysql
    environment:
      MYSQL_ROOT_PASSWORD: lAsWjb6rzSzENUYg # 数据库root用户密码,自行修改
      MYSQL_DATABASE: lsky-data # 可作为"数据库名称/路径"
    networks:
      - lsky-net

networks:
  lsky-net: {}

原项目:☁️兰空图床(Lsky Pro) - Your photo album on the cloud.

About

☁️兰空图床(Lsky Pro) - Docker自动构建

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Dockerfile 84.8%
  • Shell 15.2%