mirror of
https://github.com/okxlin/appstore.git
synced 2026-02-21 18:37:41 +08:00
feat:添加photoview到列表
This commit is contained in:
parent
309b0ca317
commit
83f153970e
BIN
app-list.png
BIN
app-list.png
Binary file not shown.
|
Before Width: | Height: | Size: 1.3 MiB After Width: | Height: | Size: 1.3 MiB |
10
apps/photoview/2.3.13/.env.sample
Normal file
10
apps/photoview/2.3.13/.env.sample
Normal file
@ -0,0 +1,10 @@
|
||||
CONTAINER_NAME="photoview"
|
||||
CACHE_PATH="./data/cache"
|
||||
DATA_PATH="./data/photos"
|
||||
PANEL_APP_PORT_HTTP="40100"
|
||||
PANEL_DB_HOST="mysql"
|
||||
PANEL_DB_NAME="photoview"
|
||||
PANEL_DB_USER="photoview"
|
||||
PANEL_DB_USER_PASSWORD="photoview_fMHR4h"
|
||||
PHOTOVIEW_DB_PORT="3306"
|
||||
|
||||
68
apps/photoview/2.3.13/data.yml
Normal file
68
apps/photoview/2.3.13/data.yml
Normal file
@ -0,0 +1,68 @@
|
||||
additionalProperties:
|
||||
formFields:
|
||||
- child:
|
||||
default: ""
|
||||
envKey: PANEL_DB_HOST
|
||||
labelEn: Database Service
|
||||
labelZh: 数据库服务
|
||||
required: true
|
||||
type: service
|
||||
default: mysql
|
||||
labelEn: Database Service
|
||||
labelZh: 数据库服务
|
||||
params:
|
||||
- envKey: PHOTOVIEW_DB_PORT
|
||||
key: mysql
|
||||
type: param
|
||||
value: "3306"
|
||||
required: true
|
||||
type: apps
|
||||
values:
|
||||
- label: MySQL
|
||||
value: mysql
|
||||
- default: photoview
|
||||
envKey: PANEL_DB_NAME
|
||||
labelEn: Database (requires MySQL8)
|
||||
labelZh: 数据库名(要求MySQL8)
|
||||
random: true
|
||||
required: true
|
||||
rule: paramCommon
|
||||
type: text
|
||||
- default: photoview
|
||||
envKey: PANEL_DB_USER
|
||||
labelEn: User
|
||||
labelZh: 数据库用户
|
||||
random: true
|
||||
required: true
|
||||
rule: paramCommon
|
||||
type: text
|
||||
- default: photoview
|
||||
envKey: PANEL_DB_USER_PASSWORD
|
||||
labelEn: Password
|
||||
labelZh: 数据库用户密码
|
||||
random: true
|
||||
required: true
|
||||
rule: paramComplexity
|
||||
type: password
|
||||
- default: 40100
|
||||
edit: true
|
||||
envKey: PANEL_APP_PORT_HTTP
|
||||
labelEn: Port
|
||||
labelZh: 端口
|
||||
required: true
|
||||
rule: paramPort
|
||||
type: number
|
||||
- default: ./data/photos
|
||||
edit: true
|
||||
envKey: DATA_PATH
|
||||
labelEn: Photos folder path
|
||||
labelZh: 照片文件夹路径
|
||||
required: true
|
||||
type: text
|
||||
- default: ./data/cache
|
||||
edit: true
|
||||
envKey: CACHE_PATH
|
||||
labelEn: Cache folder path
|
||||
labelZh: 缓存文件夹路径
|
||||
required: true
|
||||
type: text
|
||||
27
apps/photoview/2.3.13/docker-compose.yml
Normal file
27
apps/photoview/2.3.13/docker-compose.yml
Normal file
@ -0,0 +1,27 @@
|
||||
version: '3'
|
||||
services:
|
||||
photoview:
|
||||
container_name: ${CONTAINER_NAME}
|
||||
restart: always
|
||||
networks:
|
||||
- 1panel-network
|
||||
ports:
|
||||
- "${PANEL_APP_PORT_HTTP}:80"
|
||||
volumes:
|
||||
- ${CACHE_PATH}:/app/cache
|
||||
- ${DATA_PATH}:/photos:ro
|
||||
environment:
|
||||
- PHOTOVIEW_DATABASE_DRIVER=mysql
|
||||
- PHOTOVIEW_MYSQL_URL=${PANEL_DB_USER}:${PANEL_DB_USER_PASSWORD}@tcp(${PANEL_DB_HOST}:${PHOTOVIEW_DB_PORT})/${PANEL_DB_NAME}
|
||||
- PHOTOVIEW_LISTEN_IP=photoview
|
||||
- PHOTOVIEW_LISTEN_PORT=80
|
||||
- PHOTOVIEW_MEDIA_CACHE=/app/cache
|
||||
# - GODEBUG=asyncpreemptoff=1 # Optional: If you are using Samba/CIFS-Share and experience problems with "directory not found"
|
||||
# - MAPBOX_TOKEN=<YOUR TOKEN HERE> # A token can be generated for free here https://account.mapbox.com/access-tokens/
|
||||
image: viktorstrate/photoview:2.3.13
|
||||
labels:
|
||||
createdBy: "Apps"
|
||||
|
||||
networks:
|
||||
1panel-network:
|
||||
external: true
|
||||
209
apps/photoview/README.md
Normal file
209
apps/photoview/README.md
Normal file
@ -0,0 +1,209 @@
|
||||
<img src="https://github.com/photoview/photoview/raw/master/screenshots/photoview-logo.svg" height="92px" alt="photoview logo" />
|
||||
|
||||
[](./LICENSE.md)
|
||||
[](https://github.com/viktorstrate/photoview/graphs/contributors)
|
||||
[](https://hub.docker.com/r/viktorstrate/photoview)
|
||||
[](https://github.com/photoview/photoview/actions/workflows/build.yml)
|
||||
[](https://codecov.io/gh/photoview/photoview)
|
||||
|
||||

|
||||
|
||||
Photoview is a simple and user-friendly photo gallery that's made for photographers and aims to provide an easy and fast way to navigate directories, with thousands of high-resolution photos.
|
||||
|
||||
You configure Photoview to look for photos and videos within a directory on your file system. The scanner automatically picks up your media and start to generate thumbnail images to make browsing super fast.
|
||||
|
||||
When your media has been scanned they show up on the website, organised in the same way as on the filesystem.
|
||||
|
||||
> If you have questions regarding setup or development,
|
||||
feel free to join the Discord server https://discord.gg/jQ392948u9
|
||||
|
||||
## Demo site
|
||||
|
||||
Visit https://photos.qpqp.dk/
|
||||
|
||||
Username: **demo**
|
||||
Password: **demo**
|
||||
|
||||
## Contents
|
||||
|
||||
- [Demo site](#demo-site)
|
||||
- [Contents](#contents)
|
||||
- [Main features](#main-features)
|
||||
- [Supported platforms](#supported-platforms)
|
||||
- [Why yet another self-hosted photo gallery](#why-yet-another-self-hosted-photo-gallery)
|
||||
- [Getting started - Setup with Docker](#getting-started---setup-with-docker)
|
||||
- [Initial Setup](#initial-setup)
|
||||
- [Set up development environment](#set-up-development-environment)
|
||||
- [Local setup](#local-setup)
|
||||
- [Start API server](#start-api-server)
|
||||
- [Start UI server](#start-ui-server)
|
||||
- [Sponsors](#sponsors)
|
||||
|
||||
## Main features
|
||||
|
||||
- **Closely tied to the file system**. The website presents the images found on the local filesystem of the server, directories are mapped to albums.
|
||||
- **User management**. Each user is created along with a path on the local filesystem, photos within that path can be accessed by that user.
|
||||
- **Sharing**. Albums, as well as individual media, can easily be shared with a public link, the link can optionally be password protected.
|
||||
- **Made for photography**. Photoview is built with photographers in mind, and thus supports **RAW** file formats, and **EXIF** parsing.
|
||||
- **Video support**. Many common video formats are supported. Videos will automatically be optimized for web.
|
||||
- **Face recognition**. Faces will automatically be detected in photos, and photos of the same person will be grouped together.
|
||||
- **Performant**. Thumbnails are automatically generated and photos first load when they are visible on the screen. In full screen, thumbnails are displayed until the high resolution image has been fully loaded.
|
||||
- **Secure**. All media resources are protected with a cookie-token, all passwords are properly hashed, and the API uses a strict [CORS policy](https://developer.mozilla.org/en-US/docs/Web/HTTP/CORS).
|
||||
|
||||
## Supported platforms
|
||||
|
||||
- [Docker](https://hub.docker.com/r/viktorstrate/photoview/)
|
||||
- [Arch Linux Aur](https://aur.archlinux.org/packages/photoview)
|
||||
- [Unraid](https://forums.unraid.net/topic/103028-support-photoview-corneliousjd-repo/)
|
||||
- EmbassyOS: [announcement](https://start9labs.medium.com/new-service-photoview-72ee681b2ff0), [repo](https://github.com/Start9Labs/embassyos-photoview-wrapper)
|
||||
- [YunoHost](https://github.com/YunoHost-Apps/photoview_ynh)
|
||||
|
||||
## Why yet another self-hosted photo gallery
|
||||
|
||||
There exists a lot of open-source self-hosted photo galleries already. Here are some, just to mention a few.
|
||||
|
||||
- [Piwigo](https://github.com/Piwigo/Piwigo)
|
||||
- [LibrePhotos](https://github.com/LibrePhotos/librephotos)
|
||||
- [Photoprism](https://github.com/photoprism/photoprism)
|
||||
- [Lychee](https://github.com/LycheeOrg/Lychee)
|
||||
|
||||
So why another one?
|
||||
I love taking photos, and I store all of them on my local fileserver.
|
||||
This is great because I can organize my photos directly on the filesystem so it's easy to move them or take backups. I want to be able to control where and how the photos are stored.
|
||||
|
||||
The problem is however that RAW images are extremely tedious to navigate from a fileserver, even over the local network.
|
||||
|
||||
My server holds a lot of old family pictures, that I would like my family to have access to as well.
|
||||
And some of the pictures I would like to easily be able to share with other people without the hassle of them having to make an account first.
|
||||
|
||||
Thus I need a solution that can do the following:
|
||||
|
||||
- A scan based approach that automatically organises my photos
|
||||
- Support RAW and EXIF parsing
|
||||
- Have support for multiple users and ways to share albums and photos also publicly
|
||||
- Be simple and fast to use
|
||||
|
||||
All of the photo galleries can do a lot of what I need, but no single one can do it all.
|
||||
|
||||
## Getting started - Setup with Docker
|
||||
|
||||
> This section describes how to get Photoview up and running on your server with Docker.
|
||||
> Make sure you have Docker and docker-compose installed and running on your server
|
||||
|
||||
1. Make a new `docker-compose.yml` file on your computer, and copy the content of [docker-compose.example.yml](/docker-compose.example.yml) to the new file.
|
||||
2. Edit `docker-compose.yml`, find the comments starting with `Change This:`, and change the values, to properly match your setup. If you are just testing locally, you don't have to change anything.
|
||||
3. Start the server by running the following command
|
||||
|
||||
```bash
|
||||
$ docker-compose up -d
|
||||
```
|
||||
|
||||
If the endpoint or the port hasn't been changed in the `docker-compose.yml` file, Photoview can now be accessed at http://localhost:8000
|
||||
|
||||
### Initial Setup
|
||||
|
||||
If everything is setup correctly, you should be presented with an initial setup wizard, when accessing the website the first time.
|
||||
|
||||

|
||||
|
||||
Enter a new username and password.
|
||||
|
||||
For the photo path, enter the path in the docker container where your photos are located.
|
||||
This can be set from the `docker-compose.yml` file under `api` -> `volumes`.
|
||||
The default location is `/photos`
|
||||
|
||||
A new admin user will be created, with access to the photos located at the path provided under the initial setup.
|
||||
|
||||
The photos will have to be scanned before they show up, you can start a scan manually, by navigating to `Settings` and clicking on `Scan All`
|
||||
|
||||
## Set up development environment
|
||||
|
||||
### Local setup
|
||||
|
||||
1. Install a local mysql server, and make a new database
|
||||
2. Rename `/api/example.env` to `.env` and update the `MYSQL_URL` field
|
||||
3. Rename `/ui/example.env` to `.env`
|
||||
|
||||
### Start API server
|
||||
|
||||
Make sure [golang](https://golang.org/) is installed.
|
||||
|
||||
Some C libraries are needed to compile the API, see [go-face requirements](https://github.com/Kagami/go-face#requirements) for more details.
|
||||
They can be installed as shown below:
|
||||
|
||||
```sh
|
||||
# Ubuntu
|
||||
sudo add-apt-repository ppa:strukturag/libheif
|
||||
sudo add-apt-repository ppa:strukturag/libde265
|
||||
sudo apt-get update
|
||||
sudo apt-get install libdlib-dev libblas-dev libatlas-base-dev liblapack-dev libjpeg-turbo8-dev libheif-dev
|
||||
# Debian
|
||||
sudo apt-get install libdlib-dev libblas-dev libatlas-base-dev liblapack-dev libjpeg62-turbo-dev libheif-dev
|
||||
# macOS
|
||||
brew install dlib libheif
|
||||
|
||||
```
|
||||
|
||||
Then run the following commands:
|
||||
|
||||
```bash
|
||||
cd ./api
|
||||
go install
|
||||
go run server.go
|
||||
```
|
||||
|
||||
### Start UI server
|
||||
|
||||
Make sure [node](https://nodejs.org/en/) is installed.
|
||||
In a new terminal window run the following commands:
|
||||
|
||||
```bash
|
||||
cd ./ui
|
||||
npm install
|
||||
npm start
|
||||
```
|
||||
|
||||
The site can now be accessed at [localhost:1234](http://localhost:1234).
|
||||
And the graphql playground at [localhost:4001](http://localhost:4001)
|
||||
|
||||
## Sponsors
|
||||
|
||||
<table>
|
||||
<tr>
|
||||
<td>
|
||||
<a href="https://github.com/ericerkz">
|
||||
<img src="https://avatars.githubusercontent.com/u/79728329?v=4" height="auto" width="100" style="border-radius:50%"><br/>
|
||||
<b>@ericerkz</b>
|
||||
</a>
|
||||
</td>
|
||||
<td>
|
||||
<a href="https://github.com/robin-moser">
|
||||
<img src="https://avatars.githubusercontent.com/u/26254821?v=4" height="auto" width="100" style="border-radius:50%"><br/>
|
||||
<b>@robin-moser</b>
|
||||
</a>
|
||||
</td>
|
||||
<td>
|
||||
<a href="https://github.com/Revorge">
|
||||
<img src="https://avatars.githubusercontent.com/u/32901816?v=4" height="auto" width="100" style="border-radius:50%"><br/>
|
||||
<b>@Revorge</b>
|
||||
</a>
|
||||
</td>
|
||||
<td>
|
||||
<a href="https://github.com/deexno">
|
||||
<img src="https://avatars.githubusercontent.com/u/50229919?v=4" height="auto" width="100" style="border-radius:50%"><br/>
|
||||
<b>@deexno</b>
|
||||
</a>
|
||||
</td>
|
||||
<td>
|
||||
<a href="https://github.com/FKrauss">
|
||||
<img src="https://avatars.githubusercontent.com/u/4820683?v=4" height="auto" width="100" style="border-radius:50%"><br/>
|
||||
<b>@FKrauss</b>
|
||||
</a>
|
||||
</td>
|
||||
<td>
|
||||
<a href="https://github.com/jupblb">
|
||||
<img src="https://avatars.githubusercontent.com/u/3370617?v=4" height="auto" width="100" style="border-radius:50%"><br/>
|
||||
<b>@jupblb</b>
|
||||
</a>
|
||||
</td>
|
||||
</table>
|
||||
20
apps/photoview/data.yml
Normal file
20
apps/photoview/data.yml
Normal file
@ -0,0 +1,20 @@
|
||||
name: Photoview
|
||||
tags:
|
||||
- 工具
|
||||
title: 自托管个人服务器的照片库
|
||||
type: 工具
|
||||
description: 自托管个人服务器的照片库
|
||||
additionalProperties:
|
||||
key: photoview
|
||||
name: Photoview
|
||||
tags:
|
||||
- Tool
|
||||
shortDescZh: 自托管个人服务器的照片库
|
||||
shortDescEn: Photo gallery for self-hosted personal servers
|
||||
type: tool
|
||||
crossVersionUpdate: true
|
||||
limit: 0
|
||||
recommend: 0
|
||||
website: https://github.com/photoview/photoview
|
||||
github: https://github.com/photoview/photoview
|
||||
document: https://github.com/photoview/photoview
|
||||
10
apps/photoview/latest/.env.sample
Normal file
10
apps/photoview/latest/.env.sample
Normal file
@ -0,0 +1,10 @@
|
||||
CONTAINER_NAME="photoview"
|
||||
CACHE_PATH="./data/cache"
|
||||
DATA_PATH="./data/photos"
|
||||
PANEL_APP_PORT_HTTP="40100"
|
||||
PANEL_DB_HOST="mysql"
|
||||
PANEL_DB_NAME="photoview"
|
||||
PANEL_DB_USER="photoview"
|
||||
PANEL_DB_USER_PASSWORD="photoview_fMHR4h"
|
||||
PHOTOVIEW_DB_PORT="3306"
|
||||
|
||||
68
apps/photoview/latest/data.yml
Normal file
68
apps/photoview/latest/data.yml
Normal file
@ -0,0 +1,68 @@
|
||||
additionalProperties:
|
||||
formFields:
|
||||
- child:
|
||||
default: ""
|
||||
envKey: PANEL_DB_HOST
|
||||
labelEn: Database Service
|
||||
labelZh: 数据库服务
|
||||
required: true
|
||||
type: service
|
||||
default: mysql
|
||||
labelEn: Database Service
|
||||
labelZh: 数据库服务
|
||||
params:
|
||||
- envKey: PHOTOVIEW_DB_PORT
|
||||
key: mysql
|
||||
type: param
|
||||
value: "3306"
|
||||
required: true
|
||||
type: apps
|
||||
values:
|
||||
- label: MySQL
|
||||
value: mysql
|
||||
- default: photoview
|
||||
envKey: PANEL_DB_NAME
|
||||
labelEn: Database (requires MySQL8)
|
||||
labelZh: 数据库名(要求MySQL8)
|
||||
random: true
|
||||
required: true
|
||||
rule: paramCommon
|
||||
type: text
|
||||
- default: photoview
|
||||
envKey: PANEL_DB_USER
|
||||
labelEn: User
|
||||
labelZh: 数据库用户
|
||||
random: true
|
||||
required: true
|
||||
rule: paramCommon
|
||||
type: text
|
||||
- default: photoview
|
||||
envKey: PANEL_DB_USER_PASSWORD
|
||||
labelEn: Password
|
||||
labelZh: 数据库用户密码
|
||||
random: true
|
||||
required: true
|
||||
rule: paramComplexity
|
||||
type: password
|
||||
- default: 40100
|
||||
edit: true
|
||||
envKey: PANEL_APP_PORT_HTTP
|
||||
labelEn: Port
|
||||
labelZh: 端口
|
||||
required: true
|
||||
rule: paramPort
|
||||
type: number
|
||||
- default: ./data/photos
|
||||
edit: true
|
||||
envKey: DATA_PATH
|
||||
labelEn: Photos folder path
|
||||
labelZh: 照片文件夹路径
|
||||
required: true
|
||||
type: text
|
||||
- default: ./data/cache
|
||||
edit: true
|
||||
envKey: CACHE_PATH
|
||||
labelEn: Cache folder path
|
||||
labelZh: 缓存文件夹路径
|
||||
required: true
|
||||
type: text
|
||||
27
apps/photoview/latest/docker-compose.yml
Normal file
27
apps/photoview/latest/docker-compose.yml
Normal file
@ -0,0 +1,27 @@
|
||||
version: '3'
|
||||
services:
|
||||
photoview:
|
||||
container_name: ${CONTAINER_NAME}
|
||||
restart: always
|
||||
networks:
|
||||
- 1panel-network
|
||||
ports:
|
||||
- "${PANEL_APP_PORT_HTTP}:80"
|
||||
volumes:
|
||||
- ${CACHE_PATH}:/app/cache
|
||||
- ${DATA_PATH}:/photos:ro
|
||||
environment:
|
||||
- PHOTOVIEW_DATABASE_DRIVER=mysql
|
||||
- PHOTOVIEW_MYSQL_URL=${PANEL_DB_USER}:${PANEL_DB_USER_PASSWORD}@tcp(${PANEL_DB_HOST}:${PHOTOVIEW_DB_PORT})/${PANEL_DB_NAME}
|
||||
- PHOTOVIEW_LISTEN_IP=photoview
|
||||
- PHOTOVIEW_LISTEN_PORT=80
|
||||
- PHOTOVIEW_MEDIA_CACHE=/app/cache
|
||||
# - GODEBUG=asyncpreemptoff=1 # Optional: If you are using Samba/CIFS-Share and experience problems with "directory not found"
|
||||
# - MAPBOX_TOKEN=<YOUR TOKEN HERE> # A token can be generated for free here https://account.mapbox.com/access-tokens/
|
||||
image: viktorstrate/photoview:latest
|
||||
labels:
|
||||
createdBy: "Apps"
|
||||
|
||||
networks:
|
||||
1panel-network:
|
||||
external: true
|
||||
BIN
apps/photoview/logo.png
Normal file
BIN
apps/photoview/logo.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 4.7 KiB |
Loading…
Reference in New Issue
Block a user