Tabla de Contenidos

Photoview

Galería de fotos. Muy útil como visor si ya tenemos creada una estructura de directorios con nuestras fotos clasificadas, ya que no permite modificar o mover ficheros.

Características

Instalación

Docker

Ejemplo de docker-compose.yml:

version: "3"

services:
  db:
    image: mariadb:10.5
    restart: always
    environment:
      - MYSQL_DATABASE=photoview
      - MYSQL_USER=photoview
      - MYSQL_PASSWORD=photosecret
      - MYSQL_RANDOM_ROOT_PASSWORD=1
    volumes:
      - db_data:/var/lib/mysql

  photoview:
    image: viktorstrate/photoview:2
    restart: always
    ports:
      - "8000:80"
    depends_on:
      - db

    environment:
      - PHOTOVIEW_DATABASE_DRIVER=mysql
      - PHOTOVIEW_MYSQL_URL=photoview:photosecret@tcp(db)/photoview
      - PHOTOVIEW_LISTEN_IP=photoview
      - PHOTOVIEW_LISTEN_PORT=80
      - PHOTOVIEW_MEDIA_CACHE=/app/cache
 
      # Change This: The publicly exposed url
      # For example if the server is available from the domain example.com,
      # change this value to http://example.com/
      - PHOTOVIEW_PUBLIC_ENDPOINT=http://localhost:8000/
 
      # Optional: To enable map related features, you need to create a mapbox token.
      # A token can be generated for free here https://account.mapbox.com/access-tokens/
      # It's a good idea to limit the scope of the token to your own domain, to prevent others from using it.
      # - MAPBOX_TOKEN=<YOUR TOKEN HERE>

    volumes:
      - api_cache:/app/cache
 
      # Change this to the directory where your photos are located on your server.
      # If the photos are located at `/home/user/photos`, then change this value
      # to the following: `/home/user/photos:/photos:ro`.
      # You can mount multiple paths, if your photos are spread across multiple directories.
      - ./photos_path:/photos:ro

volumes:
  db_data:
  api_cache:

La primera vez, se solicitará crear una cuenta y será convertida en administrador. Desde la cuenta de administrador se podrá seguir creando usuarios.

Uso

Antes de que se puedan mostrar, las fotos deben ser escaneadas. Esto se puede hacer desde SettingsScanner y pulsando en Scan all users. También se puede definir un escaneado automático.