├── .github ├── FUNDING.yml ├── ISSUE_TEMPLATE │ ├── bug-report.yml │ ├── config.yml │ └── feature-request.yml └── workflows │ └── build-image.yml ├── DOCKERHUB.md ├── Dockerfile ├── LICENSE ├── README.md ├── appdefs.yml ├── rootfs ├── defaults │ └── Settings.json ├── etc │ ├── cont-init.d │ │ └── 55-vdf.sh │ └── openbox │ │ └── main-window-selection.xml ├── startapp.sh └── usr │ ├── bin │ └── xdg-open │ └── share │ └── applications │ └── video-player.desktop └── src ├── ffmpeg └── build.sh └── vdf ├── build.sh ├── dialog-window-owner-fix.patch ├── disable-appearance-settings.patch ├── disable-drag-and-drop-hint.patch ├── disable-latest-release.patch ├── file-picker-suggested-start-location.patch └── set-current-folder.patch /.github/FUNDING.yml: -------------------------------------------------------------------------------- 1 | # These are supported funding model platforms 2 | 3 | github: jlesage 4 | patreon: # Replace with a single Patreon username 5 | open_collective: # Replace with a single Open Collective username 6 | ko_fi: # Replace with a single Ko-fi username 7 | tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel 8 | community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry 9 | liberapay: # Replace with a single Liberapay username 10 | issuehunt: # Replace with a single IssueHunt username 11 | otechie: # Replace with a single Otechie username 12 | custom: ["https://paypal.me/JocelynLeSage", "https://www.tesla.com/referral/jocelyn4590"] 13 | -------------------------------------------------------------------------------- /.github/ISSUE_TEMPLATE/bug-report.yml: -------------------------------------------------------------------------------- 1 | name: Bug report 2 | description: File a bug report. 3 | title: "[Bug] Provide a short description of the bug here" 4 | labels: ["bug"] 5 | body: 6 | - type: markdown 7 | attributes: 8 | value: | 9 | Thanks for taking the time to fill out this bug report! 10 | - type: textarea 11 | attributes: 12 | label: Current Behavior 13 | description: A concise description of what you're experiencing. 14 | validations: 15 | required: true 16 | - type: textarea 17 | attributes: 18 | label: Expected Behavior 19 | description: A concise description of what you expected to happen. 20 | validations: 21 | required: false 22 | - type: textarea 23 | attributes: 24 | label: Steps To Reproduce 25 | description: Steps to reproduce the behavior. 26 | validations: 27 | required: false 28 | - type: textarea 29 | attributes: 30 | label: Environment 31 | description: | 32 | Provide details about the host running the container. 33 | Examples: 34 | - Operating system (e.g. Ubuntu, Windows, TrueNAS, openmediavault, unRAID, etc). 35 | - Version of the operating system. 36 | - CPU architecture (x86-64, arm, arm64, etc). 37 | - Model of the device, if applicable (e.g. Raspberry Pi 4B, Synology DS418, QNAP TS-364, etc). 38 | - The Docker version (output of `docker version`). 39 | - Anything else specific to your environment. Examples: 40 | - Network share (NFS, CIFS) mapped to the container. 41 | - Docker running in LXC container. 42 | - etc. 43 | - If applicable, how the UI provided by the container is access: 44 | - Browser (Chrome, Firefox, Edge, etc). 45 | - Version of the browser. 46 | - OS of the browser. 47 | - Is the container accessed through a reverse proxy. 48 | - etc. 49 | value: | 50 | - OS: 51 | - OS version: 52 | - CPU: 53 | - Docker version: 54 | - Device model: 55 | - Browser/OS: 56 | validations: 57 | required: false 58 | - type: textarea 59 | attributes: 60 | label: Container creation 61 | description: | 62 | How did you create the container ? 63 | Examples: 64 | - The `docker run` command used. 65 | - The compose file used. 66 | - Screenshots of the management tool UI (e.g. Portainer, unRAID, etc) showing container settings. 67 | validations: 68 | required: true 69 | - type: textarea 70 | attributes: 71 | label: Container log 72 | description: Please copy/paste the output of `docker logs `. 73 | render: text 74 | validations: 75 | required: true 76 | - type: textarea 77 | attributes: 78 | label: Container inspect 79 | description: | 80 | If the container is running, please provide the output of `docker inspect `. 81 | **Attention**: If you defined passwords, secrets or any sensitive information via environment variables, make sure to remove them from the output. 82 | render: text 83 | validations: 84 | required: false 85 | - type: textarea 86 | attributes: 87 | label: Anything else? 88 | description: | 89 | Anything that will give more context about the issue you are encountering. 90 | 91 | Tip: You can attach images or log files by clicking this area to highlight it and then dragging files in. 92 | validations: 93 | required: false 94 | -------------------------------------------------------------------------------- /.github/ISSUE_TEMPLATE/config.yml: -------------------------------------------------------------------------------- 1 | blank_issues_enabled: false 2 | contact_links: 3 | - name: Ask a question, discuss 4 | url: https://github.com/jlesage/docker-video-duplicate-finder/discussions 5 | about: Get help using this Docker container. 6 | - name: Documentation 7 | url: https://github.com/jlesage/docker-video-duplicate-finder#readme 8 | about: Documentation about this Docker container. 9 | -------------------------------------------------------------------------------- /.github/ISSUE_TEMPLATE/feature-request.yml: -------------------------------------------------------------------------------- 1 | name: Feature request 2 | description: Suggest an idea for this project. 3 | title: "[Feature request] Provide a short description of the feature here" 4 | labels: ["enhancement"] 5 | body: 6 | - type: markdown 7 | attributes: 8 | value: | 9 | Thank you for suggesting an idea to make this project better. 10 | - type: textarea 11 | attributes: 12 | label: Idea 13 | description: | 14 | Please describe the desired behavior, pitch your idea, or suggest improvements. 15 | validations: 16 | required: true 17 | -------------------------------------------------------------------------------- /.github/workflows/build-image.yml: -------------------------------------------------------------------------------- 1 | name: Docker image CI/CD 2 | 3 | concurrency: 4 | group: ${{ github.workflow }}-${{ github.ref }} 5 | cancel-in-progress: true 6 | 7 | env: 8 | DOCKER_IMAGE_NAME: jlesage/video-duplicate-finder 9 | PLATFORMS: linux/amd64,linux/arm/v6,linux/arm/v7,linux/arm64/v8 10 | 11 | on: 12 | push: 13 | branches: '*' 14 | tags: 15 | - v[0-9][0-9].[0-9][0-9].[0-9]+ 16 | - v[0-9][0-9].[0-9][0-9].[0-9]+-pre.[0-9]+ 17 | pull_request: 18 | 19 | jobs: 20 | build: 21 | name: Build image 22 | runs-on: ubuntu-20.04 23 | 24 | steps: 25 | - name: Free disk space 26 | uses: jlumbroso/free-disk-space@main 27 | with: 28 | tool-cache: true 29 | android: true 30 | dotnet: true 31 | haskell: true 32 | large-packages: true 33 | docker-images: true 34 | swap-storage: false 35 | 36 | - name: Prepare 37 | id: prep 38 | run: | 39 | # Determine the Docker container version. 40 | VERSION=unknown 41 | if [[ $GITHUB_REF =~ refs/tags/* ]]; then 42 | # Git tag pushed: use tag as the version. 43 | VERSION=${GITHUB_REF#refs/tags/} 44 | elif [[ $GITHUB_REF =~ refs/heads/* ]]; then 45 | # Git commit pushed: use the commit SHA as the version. 46 | VERSION=${GITHUB_SHA::8} 47 | elif [[ $GITHUB_REF =~ refs/pull/* ]]; then 48 | # Pull request: use PR number as the version. 49 | VERSION=pr-${{ github.event.number }} 50 | else 51 | echo "::error::Unexpected GITHUB_REF: $GITHUB_REF" 52 | exit 1 53 | fi 54 | # Determine the version to put in container label. 55 | LABEL_VERSION=${VERSION} 56 | if [[ $GITHUB_REF =~ refs/tags/* ]]; then 57 | # Do not include the starting 'v' of the version. 58 | LABEL_VERSION=${VERSION:1} 59 | fi 60 | # Determine the Docker container tags. 61 | TAGS="${{ env.DOCKER_IMAGE_NAME }}:${VERSION}" 62 | if [[ $GITHUB_REF =~ refs/tags/* ]]; then 63 | TAGS="$TAGS,${{ env.DOCKER_IMAGE_NAME }}:latest" 64 | fi 65 | TAGS="$TAGS,$(echo $TAGS | tr ',' '\n' | sed 's|^|ghcr.io/|' | tr '\n' ',')" 66 | # Determine the release type. 67 | if [[ $GITHUB_REF =~ refs/tags/* ]]; then 68 | IS_RELEASE=yes 69 | if [[ $GITHUB_REF =~ -pre\.[0-9]+ ]]; then 70 | RELEASE_TYPE="pre" 71 | else 72 | RELEASE_TYPE="standard" 73 | fi 74 | else 75 | IS_RELEASE=no 76 | RELEASE_TYPE="n/a" 77 | fi 78 | # Print results. 79 | echo "::group::Results" 80 | echo "Github reference: $GITHUB_REF" 81 | echo "Release: $IS_RELEASE" 82 | echo "Release type: $RELEASE_TYPE" 83 | echo "Docker container version: $VERSION" 84 | echo "Docker container version label: $LABEL_VERSION" 85 | echo "Docker container tag(s): $TAGS" 86 | echo "::endgroup::" 87 | # Export outputs. 88 | echo "is_release=${IS_RELEASE}" >> $GITHUB_OUTPUT 89 | echo "release_type=${RELEASE_TYPE}" >> $GITHUB_OUTPUT 90 | echo "version=${VERSION}" >> $GITHUB_OUTPUT 91 | echo "label_version=${LABEL_VERSION}" >> $GITHUB_OUTPUT 92 | echo "tags=${TAGS}" >> $GITHUB_OUTPUT 93 | #echo "build_date=$(date -u +'%Y-%m-%dT%H:%M:%SZ')" >> $GITHUB_OUTPUT 94 | 95 | - name: Setup QEMU 96 | uses: docker/setup-qemu-action@v3 97 | with: 98 | platforms: arm,arm64,ppc64le,mips64,s390x 99 | 100 | - name: Setup Docker Buildx 101 | uses: docker/setup-buildx-action@v3 102 | 103 | - name: Login to DockerHub 104 | if: ${{ steps.prep.outputs.is_release == 'yes' }} 105 | uses: docker/login-action@v3 106 | with: 107 | username: ${{ secrets.DOCKERHUB_USERNAME }} 108 | password: ${{ secrets.DOCKERHUB_PASSWORD }} 109 | 110 | - name: Login to GitHub Container Registry 111 | if: ${{ steps.prep.outputs.is_release == 'yes' }} 112 | uses: docker/login-action@v3 113 | with: 114 | registry: ghcr.io 115 | username: ${{ github.repository_owner }} 116 | password: ${{ secrets.GITHUB_TOKEN }} 117 | 118 | - name: Build and push 119 | uses: docker/build-push-action@v6 120 | with: 121 | push: ${{ steps.prep.outputs.is_release == 'yes' }} 122 | provenance: false 123 | platforms: ${{ env.PLATFORMS }} 124 | tags: ${{ steps.prep.outputs.tags }} 125 | build-args: | 126 | DOCKER_IMAGE_VERSION=${{ steps.prep.outputs.label_version }} 127 | cache-from: type=gha,scope=${{ env.DOCKER_IMAGE_NAME }} 128 | cache-to: type=gha,mode=max,scope=${{ env.DOCKER_IMAGE_NAME }} 129 | 130 | - name: Inspect 131 | if: ${{ steps.prep.outputs.is_release == 'yes' }} 132 | run: | 133 | docker buildx imagetools inspect ${{ env.DOCKER_IMAGE_NAME }}:${{ steps.prep.outputs.version }} 134 | 135 | - name: Checkout 136 | uses: actions/checkout@v4 137 | if: ${{ steps.prep.outputs.release_type == 'standard' }} 138 | 139 | - name: Dockerhub description 140 | if: ${{ steps.prep.outputs.release_type == 'standard' }} 141 | uses: peter-evans/dockerhub-description@v4 142 | with: 143 | username: ${{ secrets.DOCKERHUB_USERNAME }} 144 | password: ${{ secrets.DOCKERHUB_PASSWORD }} 145 | repository: ${{ env.DOCKER_IMAGE_NAME }} 146 | readme-filepath: DOCKERHUB.md 147 | 148 | notification: 149 | name: Notification 150 | needs: [ build ] 151 | runs-on: ubuntu-20.04 152 | if: ${{ always() && github.event_name != 'pull_request' }} 153 | 154 | steps: 155 | - name: Pushover notification 156 | uses: desiderati/github-action-pushover@v1 157 | with: 158 | job-status: ${{ needs.build.result }} 159 | pushover-api-token: ${{ secrets.PUSHOVER_API_TOKEN }} 160 | pushover-user-key: ${{ secrets.PUSHOVER_USER_KEY }} 161 | -------------------------------------------------------------------------------- /DOCKERHUB.md: -------------------------------------------------------------------------------- 1 | # Docker container for Video Duplicate Finder 2 | [![Release](https://img.shields.io/github/release/jlesage/docker-video-duplicate-finder.svg?logo=github&style=for-the-badge)](https://github.com/jlesage/docker-video-duplicate-finder/releases/latest) 3 | [![Docker Image Size](https://img.shields.io/docker/image-size/jlesage/video-duplicate-finder/latest?logo=docker&style=for-the-badge)](https://hub.docker.com/r/jlesage/video-duplicate-finder/tags) 4 | [![Docker Pulls](https://img.shields.io/docker/pulls/jlesage/video-duplicate-finder?label=Pulls&logo=docker&style=for-the-badge)](https://hub.docker.com/r/jlesage/video-duplicate-finder) 5 | [![Docker Stars](https://img.shields.io/docker/stars/jlesage/video-duplicate-finder?label=Stars&logo=docker&style=for-the-badge)](https://hub.docker.com/r/jlesage/video-duplicate-finder) 6 | [![Build Status](https://img.shields.io/github/actions/workflow/status/jlesage/docker-video-duplicate-finder/build-image.yml?logo=github&branch=master&style=for-the-badge)](https://github.com/jlesage/docker-video-duplicate-finder/actions/workflows/build-image.yml) 7 | [![Source](https://img.shields.io/badge/Source-GitHub-blue?logo=github&style=for-the-badge)](https://github.com/jlesage/docker-video-duplicate-finder) 8 | [![Donate](https://img.shields.io/badge/Donate-PayPal-green.svg?style=for-the-badge)](https://paypal.me/JocelynLeSage) 9 | 10 | This is a Docker container for [Video Duplicate Finder](https://github.com/0x90d/videoduplicatefinder). 11 | 12 | The GUI of the application is accessed through a modern web browser (no 13 | installation or configuration needed on the client side) or via any VNC client. 14 | 15 | --- 16 | 17 | [![Video Duplicate Finder logo](https://images.weserv.nl/?url=raw.githubusercontent.com/jlesage/docker-templates/master/jlesage/images/video-duplicate-finder-icon.png&w=110)](https://github.com/0x90d/videoduplicatefinder)[![Video Duplicate Finder](https://images.placeholders.dev/?width=704&height=110&fontFamily=monospace&fontWeight=400&fontSize=52&text=Video%20Duplicate%20Finder&bgColor=rgba(0,0,0,0.0)&textColor=rgba(121,121,121,1))](https://github.com/0x90d/videoduplicatefinder) 18 | 19 | Video Duplicate Finder is a cross-platform software to find duplicated video (and 20 | image) files on hard disk based on similiarity. That means unlike other duplicate 21 | finders, this one does also finds duplicates which have a different resolution, 22 | frame rate and even watermarked. 23 | 24 | --- 25 | 26 | ## Quick Start 27 | 28 | **NOTE**: 29 | The Docker command provided in this quick start is given as an example 30 | and parameters should be adjusted to your need. 31 | 32 | Launch the Video Duplicate Finder docker container with the following command: 33 | ```shell 34 | docker run -d \ 35 | --name=video-duplicate-finder \ 36 | -p 5800:5800 \ 37 | -v /docker/appdata/video-duplicate-finder:/config:rw \ 38 | -v /home/user:/storage:rw \ 39 | jlesage/video-duplicate-finder 40 | ``` 41 | 42 | Where: 43 | 44 | - `/docker/appdata/video-duplicate-finder`: This is where the application stores its configuration, states, log and any files needing persistency. 45 | - `/home/user`: This location contains files from your host that need to be accessible to the application. 46 | 47 | Browse to `http://your-host-ip:5800` to access the Video Duplicate Finder GUI. 48 | Files from the host appear under the `/storage` folder in the container. 49 | 50 | ## Documentation 51 | 52 | Full documentation is available at https://github.com/jlesage/docker-video-duplicate-finder. 53 | 54 | ## Support or Contact 55 | 56 | Having troubles with the container or have questions? Please 57 | [create a new issue]. 58 | 59 | For other great Dockerized applications, see https://jlesage.github.io/docker-apps. 60 | 61 | [create a new issue]: https://github.com/jlesage/docker-video-duplicate-finder/issues 62 | -------------------------------------------------------------------------------- /Dockerfile: -------------------------------------------------------------------------------- 1 | # 2 | # video-duplicate-finder Dockerfile 3 | # 4 | # https://github.com/jlesage/docker-video-duplicate-finder 5 | # 6 | 7 | # Docker image version is provided via build arg. 8 | ARG DOCKER_IMAGE_VERSION= 9 | 10 | # Define software versions. 11 | ARG VIDEO_DUPLICATE_FINDER_COMMIT_SHA=e253212 12 | ARG VIDEO_DUPLICATE_FINDER_VERSION=3.0.x-${VIDEO_DUPLICATE_FINDER_COMMIT_SHA} 13 | ARG FFMPEG_VERSION=7.1 14 | 15 | # Define software download URLs. 16 | ARG VIDEO_DUPLICATE_FINDER_URL=https://github.com/0x90d/videoduplicatefinder/archive/${VIDEO_DUPLICATE_FINDER_COMMIT_SHA}.tar.gz 17 | ARG FFMPEG_URL=https://ffmpeg.org/releases/ffmpeg-${FFMPEG_VERSION}.tar.xz 18 | 19 | # Get Dockerfile cross-compilation helpers. 20 | FROM --platform=$BUILDPLATFORM tonistiigi/xx AS xx 21 | 22 | # Build Video Duplicate Finder. 23 | FROM --platform=$BUILDPLATFORM alpine:3.21 AS vdf 24 | ARG TARGETPLATFORM 25 | ARG VIDEO_DUPLICATE_FINDER_URL 26 | COPY --from=xx / / 27 | COPY src/vdf /build 28 | RUN /build/build.sh "$VIDEO_DUPLICATE_FINDER_URL" 29 | RUN xx-verify /tmp/vdf-install/VDF.GUI 30 | 31 | # Build FFmpeg. 32 | FROM --platform=$BUILDPLATFORM alpine:3.21 AS ffmpeg 33 | ARG TARGETPLATFORM 34 | ARG FFMPEG_URL 35 | COPY --from=xx / / 36 | COPY src/ffmpeg /build 37 | RUN /build/build.sh "$FFMPEG_URL" 38 | RUN xx-verify \ 39 | /tmp/ffmpeg-install/usr/bin/ffmpeg \ 40 | /tmp/ffmpeg-install/usr/bin/ffplay \ 41 | /tmp/ffmpeg-install/usr/bin/ffprobe \ 42 | /tmp/ffmpeg-install/usr/lib/lib*.so.* 43 | 44 | # Pull base image. 45 | FROM jlesage/baseimage-gui:alpine-3.21-v4.7.1 46 | 47 | ARG TARGETARCH 48 | ARG VIDEO_DUPLICATE_FINDER_VERSION 49 | ARG DOCKER_IMAGE_VERSION 50 | 51 | # Define working directory. 52 | WORKDIR /tmp 53 | 54 | # Install dependencies. 55 | RUN \ 56 | [ "${TARGETARCH:-amd64}" = "amd64" ] && _onevpl=onevpl-libs || _onevpl=; \ 57 | add-pkg \ 58 | gtk+3.0 \ 59 | icu-libs \ 60 | libice \ 61 | libsm \ 62 | libunwind \ 63 | sdl2 \ 64 | libdrm \ 65 | libpulse \ 66 | libva \ 67 | libvdpau \ 68 | $_onevpl \ 69 | adwaita-icon-theme \ 70 | font-dejavu \ 71 | pcmanfm \ 72 | jq \ 73 | # Need for the `sponge` tool. 74 | moreutils 75 | 76 | # Generate and install favicons. 77 | RUN \ 78 | APP_ICON_URL=https://raw.githubusercontent.com/jlesage/docker-templates/master/jlesage/images/video-duplicate-finder-icon.png && \ 79 | install_app_icon.sh "$APP_ICON_URL" 80 | 81 | # Add files. 82 | COPY rootfs/ / 83 | COPY --from=vdf /tmp/vdf-install /opt/vdf 84 | COPY --from=ffmpeg /tmp/ffmpeg-install/usr/bin/ffmpeg /usr/bin/ffmpeg 85 | COPY --from=ffmpeg /tmp/ffmpeg-install/usr/bin/ffplay /usr/bin/ffplay 86 | COPY --from=ffmpeg /tmp/ffmpeg-install/usr/bin/ffprobe /usr/bin/ffprobe 87 | COPY --from=ffmpeg /tmp/ffmpeg-install/usr/lib /usr/lib 88 | 89 | # Set internal environment variables. 90 | RUN \ 91 | set-cont-env APP_NAME "Video Duplicate Finder" && \ 92 | set-cont-env APP_VERSION "$VIDEO_DUPLICATE_FINDER_VERSION" && \ 93 | set-cont-env DOCKER_IMAGE_VERSION "$DOCKER_IMAGE_VERSION" && \ 94 | true 95 | 96 | # Define mountable directories. 97 | VOLUME ["/storage"] 98 | 99 | # Metadata. 100 | LABEL \ 101 | org.label-schema.name="video-duplicate-finder" \ 102 | org.label-schema.description="Docker container for Video Duplicate Finder" \ 103 | org.label-schema.version="${DOCKER_IMAGE_VERSION:-unknown}" \ 104 | org.label-schema.vcs-url="https://github.com/jlesage/docker-video-duplicate-finder" \ 105 | org.label-schema.schema-version="1.0" 106 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2025 Jocelyn Le Sage 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | 23 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Docker container for Video Duplicate Finder 2 | [![Release](https://img.shields.io/github/release/jlesage/docker-video-duplicate-finder.svg?logo=github&style=for-the-badge)](https://github.com/jlesage/docker-video-duplicate-finder/releases/latest) 3 | [![Docker Image Size](https://img.shields.io/docker/image-size/jlesage/video-duplicate-finder/latest?logo=docker&style=for-the-badge)](https://hub.docker.com/r/jlesage/video-duplicate-finder/tags) 4 | [![Docker Pulls](https://img.shields.io/docker/pulls/jlesage/video-duplicate-finder?label=Pulls&logo=docker&style=for-the-badge)](https://hub.docker.com/r/jlesage/video-duplicate-finder) 5 | [![Docker Stars](https://img.shields.io/docker/stars/jlesage/video-duplicate-finder?label=Stars&logo=docker&style=for-the-badge)](https://hub.docker.com/r/jlesage/video-duplicate-finder) 6 | [![Build Status](https://img.shields.io/github/actions/workflow/status/jlesage/docker-video-duplicate-finder/build-image.yml?logo=github&branch=master&style=for-the-badge)](https://github.com/jlesage/docker-video-duplicate-finder/actions/workflows/build-image.yml) 7 | [![Donate](https://img.shields.io/badge/Donate-PayPal-green.svg?style=for-the-badge)](https://paypal.me/JocelynLeSage) 8 | 9 | This project implements a Docker container for [Video Duplicate Finder](https://github.com/0x90d/videoduplicatefinder). 10 | 11 | The GUI of the application is accessed through a modern web browser (no 12 | installation or configuration needed on the client side) or via any VNC client. 13 | 14 | --- 15 | 16 | [![Video Duplicate Finder logo](https://images.weserv.nl/?url=raw.githubusercontent.com/jlesage/docker-templates/master/jlesage/images/video-duplicate-finder-icon.png&w=110)](https://github.com/0x90d/videoduplicatefinder)[![Video Duplicate Finder](https://images.placeholders.dev/?width=704&height=110&fontFamily=monospace&fontWeight=400&fontSize=52&text=Video%20Duplicate%20Finder&bgColor=rgba(0,0,0,0.0)&textColor=rgba(121,121,121,1))](https://github.com/0x90d/videoduplicatefinder) 17 | 18 | Video Duplicate Finder is a cross-platform software to find duplicated video (and 19 | image) files on hard disk based on similiarity. That means unlike other duplicate 20 | finders, this one does also finds duplicates which have a different resolution, 21 | frame rate and even watermarked. 22 | 23 | --- 24 | 25 | ## Table of Content 26 | 27 | * [Quick Start](#quick-start) 28 | * [Usage](#usage) 29 | * [Environment Variables](#environment-variables) 30 | * [Deployment Considerations](#deployment-considerations) 31 | * [Data Volumes](#data-volumes) 32 | * [Ports](#ports) 33 | * [Changing Parameters of a Running Container](#changing-parameters-of-a-running-container) 34 | * [Docker Compose File](#docker-compose-file) 35 | * [Docker Image Versioning](#docker-image-versioning) 36 | * [Docker Image Update](#docker-image-update) 37 | * [Synology](#synology) 38 | * [unRAID](#unraid) 39 | * [User/Group IDs](#usergroup-ids) 40 | * [Accessing the GUI](#accessing-the-gui) 41 | * [Security](#security) 42 | * [SSVNC](#ssvnc) 43 | * [Certificates](#certificates) 44 | * [VNC Password](#vnc-password) 45 | * [Web Authentication](#web-authentication) 46 | * [Configuring Users Credentials](#configuring-users-credentials) 47 | * [Reverse Proxy](#reverse-proxy) 48 | * [Routing Based on Hostname](#routing-based-on-hostname) 49 | * [Routing Based on URL Path](#routing-based-on-url-path) 50 | * [Shell Access](#shell-access) 51 | * [Support or Contact](#support-or-contact) 52 | 53 | ## Quick Start 54 | 55 | > [!IMPORTANT] 56 | > The Docker command provided in this quick start is given as an example and 57 | > parameters should be adjusted to your need. 58 | 59 | Launch the Video Duplicate Finder docker container with the following command: 60 | ```shell 61 | docker run -d \ 62 | --name=video-duplicate-finder \ 63 | -p 5800:5800 \ 64 | -v /docker/appdata/video-duplicate-finder:/config:rw \ 65 | -v /home/user:/storage:rw \ 66 | jlesage/video-duplicate-finder 67 | ``` 68 | 69 | Where: 70 | 71 | - `/docker/appdata/video-duplicate-finder`: This is where the application stores its configuration, states, log and any files needing persistency. 72 | - `/home/user`: This location contains files from your host that need to be accessible to the application. 73 | 74 | Browse to `http://your-host-ip:5800` to access the Video Duplicate Finder GUI. 75 | Files from the host appear under the `/storage` folder in the container. 76 | 77 | ## Usage 78 | 79 | ```shell 80 | docker run [-d] \ 81 | --name=video-duplicate-finder \ 82 | [-e =]... \ 83 | [-v :[:PERMISSIONS]]... \ 84 | [-p :]... \ 85 | jlesage/video-duplicate-finder 86 | ``` 87 | 88 | | Parameter | Description | 89 | |-----------|-------------| 90 | | -d | Run the container in the background. If not set, the container runs in the foreground. | 91 | | -e | Pass an environment variable to the container. See the [Environment Variables](#environment-variables) section for more details. | 92 | | -v | Set a volume mapping (allows to share a folder/file between the host and the container). See the [Data Volumes](#data-volumes) section for more details. | 93 | | -p | Set a network port mapping (exposes an internal container port to the host). See the [Ports](#ports) section for more details. | 94 | 95 | ### Environment Variables 96 | 97 | To customize some properties of the container, the following environment 98 | variables can be passed via the `-e` parameter (one for each variable). Value 99 | of this parameter has the format `=`. 100 | 101 | | Variable | Description | Default | 102 | |----------------|----------------------------------------------|---------| 103 | |`USER_ID`| ID of the user the application runs as. See [User/Group IDs](#usergroup-ids) to better understand when this should be set. | `1000` | 104 | |`GROUP_ID`| ID of the group the application runs as. See [User/Group IDs](#usergroup-ids) to better understand when this should be set. | `1000` | 105 | |`SUP_GROUP_IDS`| Comma-separated list of supplementary group IDs of the application. | (no value) | 106 | |`UMASK`| Mask that controls how permissions are set for newly created files and folders. The value of the mask is in octal notation. By default, the default umask value is `0022`, meaning that newly created files and folders are readable by everyone, but only writable by the owner. See the online umask calculator at http://wintelguy.com/umask-calc.pl. | `0022` | 107 | |`LANG`| Set the [locale](https://en.wikipedia.org/wiki/Locale_(computer_software)), which defines the application's language, **if supported**. Format of the locale is `language[_territory][.codeset]`, where language is an [ISO 639 language code](https://en.wikipedia.org/wiki/List_of_ISO_639-1_codes), territory is an [ISO 3166 country code](https://en.wikipedia.org/wiki/ISO_3166-1#Current_codes) and codeset is a character set, like `UTF-8`. For example, Australian English using the UTF-8 encoding is `en_AU.UTF-8`. | `en_US.UTF-8` | 108 | |`TZ`| [TimeZone](http://en.wikipedia.org/wiki/List_of_tz_database_time_zones) used by the container. Timezone can also be set by mapping `/etc/localtime` between the host and the container. | `Etc/UTC` | 109 | |`KEEP_APP_RUNNING`| When set to `1`, the application will be automatically restarted when it crashes or terminates. | `0` | 110 | |`APP_NICENESS`| Priority at which the application should run. A niceness value of -20 is the highest priority and 19 is the lowest priority. The default niceness value is 0. **NOTE**: A negative niceness (priority increase) requires additional permissions. In this case, the container should be run with the docker option `--cap-add=SYS_NICE`. | `0` | 111 | |`INSTALL_PACKAGES`| Space-separated list of packages to install during the startup of the container. List of available packages can be found at https://pkgs.alpinelinux.org. **ATTENTION**: Container functionality can be affected when installing a package that overrides existing container files (e.g. binaries). | (no value) | 112 | |`PACKAGES_MIRROR`| Mirror of the repository to use when installing packages. List of mirrors is available at https://mirrors.alpinelinux.org. | (no value) | 113 | |`CONTAINER_DEBUG`| Set to `1` to enable debug logging. | `0` | 114 | |`DISPLAY_WIDTH`| Width (in pixels) of the application's window. | `1920` | 115 | |`DISPLAY_HEIGHT`| Height (in pixels) of the application's window. | `1080` | 116 | |`DARK_MODE`| When set to `1`, dark mode is enabled for the application. | `0` | 117 | |`WEB_AUDIO`| When set to `1`, audio support is enabled, meaning that any audio produced by the application is played through the browser. Note that audio is not supported for VNC clients. | `0` | 118 | |`WEB_AUTHENTICATION`| When set to `1`, the application's GUI is protected via a login page when accessed via a web browser. Access is allowed only when providing valid credentials. **NOTE**: This feature requires secure connection (`SECURE_CONNECTION` environment variable) to be enabled. | `0` | 119 | |`WEB_AUTHENTICATION_TOKEN_VALIDITY_TIME`| The lifetime of a token, in hours. A token is attributed to the user after a successful login. As long as the token is valid, user can access the application's GUI without having to log in again. Once the token expires, the login page is prompted again. | `24` | 120 | |`WEB_AUTHENTICATION_USERNAME`| Optional username to configure for the web authentication. This is a quick and easy way to configure credentials for a single user. To configure credentials in a more secure way, or to add more users, see the [Web Authentication](#web-authentication) section. | (no value) | 121 | |`WEB_AUTHENTICATION_PASSWORD`| Optional password to configure for the web authentication. This is a quick and easy way to configure credentials for a single user. To configure credentials in a more secure way, or to add more users, see the [Web Authentication](#web-authentication) section. | (no value) | 122 | |`SECURE_CONNECTION`| When set to `1`, an encrypted connection is used to access the application's GUI (either via a web browser or VNC client). See the [Security](#security) section for more details. | `0` | 123 | |`SECURE_CONNECTION_VNC_METHOD`| Method used to perform the secure VNC connection. Possible values are `SSL` or `TLS`. See the [Security](#security) section for more details. | `SSL` | 124 | |`SECURE_CONNECTION_CERTS_CHECK_INTERVAL`| Interval, in seconds, at which the system verifies if web or VNC certificates have changed. When a change is detected, the affected services are automatically restarted. A value of `0` disables the check. | `60` | 125 | |`WEB_LISTENING_PORT`| Port used by the web server to serve the UI of the application. This port is used internally by the container and it is usually not required to be changed. By default, a container is created with the default bridge network, meaning that, to be accessible, each internal container port must be mapped to an external port (using the `-p` or `--publish` argument). However, if the container is created with another network type, changing the port used by the container might be useful to prevent conflict with other services/containers. **NOTE**: a value of `-1` disables listening, meaning that the application's UI won't be accessible over HTTP/HTTPs. | `5800` | 126 | |`VNC_LISTENING_PORT`| Port used by the VNC server to serve the UI of the application. This port is used internally by the container and it is usually not required to be changed. By default, a container is created with the default bridge network, meaning that, to be accessible, each internal container port must be mapped to an external port (using the `-p` or `--publish` argument). However, if the container is created with another network type, changing the port used by the container might be useful to prevent conflict with other services/containers. **NOTE**: a value of `-1` disables listening, meaning that the application's UI won't be accessible over VNC. | `5900` | 127 | |`VNC_PASSWORD`| Password needed to connect to the application's GUI. See the [VNC Password](#vnc-password) section for more details. | (no value) | 128 | |`ENABLE_CJK_FONT`| When set to `1`, open-source computer font `WenQuanYi Zen Hei` is installed. This font contains a large range of Chinese/Japanese/Korean characters. | `0` | 129 | 130 | #### Deployment Considerations 131 | 132 | Many tools used to manage Docker containers extract environment variables 133 | defined by the Docker image and use them to create/deploy the container. For 134 | example, this is done by: 135 | - The Docker application on Synology NAS 136 | - The Container Station on QNAP NAS 137 | - Portainer 138 | - etc. 139 | 140 | While this can be useful for the user to adjust the value of environment 141 | variables to fit its needs, it can also be confusing and dangerous to keep all 142 | of them. 143 | 144 | A good practice is to set/keep only the variables that are needed for the 145 | container to behave as desired in a specific setup. If the value of variable is 146 | kept to its default value, it means that it can be removed. Keep in mind that 147 | all variables are optional, meaning that none of them is required for the 148 | container to start. 149 | 150 | Removing environment variables that are not needed provides some advantages: 151 | 152 | - Prevents keeping variables that are no longer used by the container. Over 153 | time, with image updates, some variables might be removed. 154 | - Allows the Docker image to change/fix a default value. Again, with image 155 | updates, the default value of a variable might be changed to fix an issue, 156 | or to better support a new feature. 157 | - Prevents changes to a variable that might affect the correct function of 158 | the container. Some undocumented variables, like `PATH` or `ENV`, are 159 | required to be exposed, but are not meant to be changed by users. However, 160 | container management tools still show these variables to users. 161 | - There is a bug with the Container Station on QNAP and the Docker application 162 | on Synology, where an environment variable without value might not be 163 | allowed. This behavior is wrong: it's absolutely fine to have a variable 164 | without value. In fact, this container does have variables without value by 165 | default. Thus, removing unneeded variables is a good way to prevent 166 | deployment issue on these devices. 167 | 168 | ### Data Volumes 169 | 170 | The following table describes data volumes used by the container. The mappings 171 | are set via the `-v` parameter. Each mapping is specified with the following 172 | format: `:[:PERMISSIONS]`. 173 | 174 | | Container path | Permissions | Description | 175 | |-----------------|-------------|-------------| 176 | |`/config`| rw | This is where the application stores its configuration, states, log and any files needing persistency. | 177 | |`/storage`| rw | This location contains files from your host that need to be accessible to the application. | 178 | 179 | ### Ports 180 | 181 | Here is the list of ports used by the container. 182 | 183 | When using the default bridge network, ports can be mapped to the host via the 184 | `-p` parameter (one per port mapping). Each mapping is defined with the 185 | following format: `:`. The port number used inside 186 | the container might not be changeable, but you are free to use any port on the 187 | host side. 188 | 189 | See the [Docker Container Networking](https://docs.docker.com/config/containers/container-networking) 190 | documentation for more details. 191 | 192 | | Port | Protocol | Mapping to host | Description | 193 | |------|----------|-----------------|-------------| 194 | | 5800 | TCP | Optional | Port to access the application's GUI via the web interface. Mapping to the host is optional if access through the web interface is not wanted. For a container not using the default bridge network, the port can be changed with the `WEB_LISTENING_PORT` environment variable. | 195 | | 5900 | TCP | Optional | Port to access the application's GUI via the VNC protocol. Mapping to the host is optional if access through the VNC protocol is not wanted. For a container not using the default bridge network, the port can be changed with the `VNC_LISTENING_PORT` environment variable. | 196 | 197 | ### Changing Parameters of a Running Container 198 | 199 | As can be seen, environment variables, volume and port mappings are all specified 200 | while creating the container. 201 | 202 | The following steps describe the method used to add, remove or update 203 | parameter(s) of an existing container. The general idea is to destroy and 204 | re-create the container: 205 | 206 | 1. Stop the container (if it is running): 207 | ```shell 208 | docker stop video-duplicate-finder 209 | ``` 210 | 211 | 2. Remove the container: 212 | ```shell 213 | docker rm video-duplicate-finder 214 | ``` 215 | 216 | 3. Create/start the container using the `docker run` command, by adjusting 217 | parameters as needed. 218 | 219 | > [!NOTE] 220 | > Since all application's data is saved under the `/config` container folder, 221 | > destroying and re-creating a container is not a problem: nothing is lost and 222 | > the application comes back with the same state (as long as the mapping of the 223 | > `/config` folder remains the same). 224 | 225 | ## Docker Compose File 226 | 227 | Here is an example of a `docker-compose.yml` file that can be used with 228 | [Docker Compose](https://docs.docker.com/compose/overview/). 229 | 230 | Make sure to adjust according to your needs. Note that only mandatory network 231 | ports are part of the example. 232 | 233 | ```yaml 234 | version: '3' 235 | services: 236 | video-duplicate-finder: 237 | image: jlesage/video-duplicate-finder 238 | ports: 239 | - "5800:5800" 240 | volumes: 241 | - "/docker/appdata/video-duplicate-finder:/config:rw" 242 | - "/home/user:/storage:rw" 243 | ``` 244 | 245 | ## Docker Image Versioning 246 | 247 | Each release of a Docker image is versioned. Prior to october 2022, the 248 | [semantic versioning](https://semver.org) was used as the versioning scheme. 249 | 250 | Since then, versioning scheme changed to 251 | [calendar versioning](https://calver.org). The format used is `YY.MM.SEQUENCE`, 252 | where: 253 | - `YY` is the zero-padded year (relative to year 2000). 254 | - `MM` is the zero-padded month. 255 | - `SEQUENCE` is the incremental release number within the month (first release 256 | is 1, second is 2, etc). 257 | 258 | ## Docker Image Update 259 | 260 | Because features are added, issues are fixed, or simply because a new version 261 | of the containerized application is integrated, the Docker image is regularly 262 | updated. Different methods can be used to update the Docker image. 263 | 264 | The system used to run the container may have a built-in way to update 265 | containers. If so, this could be your primary way to update Docker images. 266 | 267 | An other way is to have the image be automatically updated with [Watchtower]. 268 | Watchtower is a container-based solution for automating Docker image updates. 269 | This is a "set and forget" type of solution: once a new image is available, 270 | Watchtower will seamlessly perform the necessary steps to update the container. 271 | 272 | Finally, the Docker image can be manually updated with these steps: 273 | 274 | 1. Fetch the latest image: 275 | ```shell 276 | docker pull jlesage/video-duplicate-finder 277 | ``` 278 | 279 | 2. Stop the container: 280 | ```shell 281 | docker stop video-duplicate-finder 282 | ``` 283 | 284 | 3. Remove the container: 285 | ```shell 286 | docker rm video-duplicate-finder 287 | ``` 288 | 289 | 4. Create and start the container using the `docker run` command, with the 290 | the same parameters that were used when it was deployed initially. 291 | 292 | [Watchtower]: https://github.com/containrrr/watchtower 293 | 294 | ### Synology 295 | 296 | For owners of a Synology NAS, the following steps can be used to update a 297 | container image. 298 | 299 | 1. Open the *Docker* application. 300 | 2. Click on *Registry* in the left pane. 301 | 3. In the search bar, type the name of the container (`jlesage/video-duplicate-finder`). 302 | 4. Select the image, click *Download* and then choose the `latest` tag. 303 | 5. Wait for the download to complete. A notification will appear once done. 304 | 6. Click on *Container* in the left pane. 305 | 7. Select your Video Duplicate Finder container. 306 | 8. Stop it by clicking *Action*->*Stop*. 307 | 9. Clear the container by clicking *Action*->*Reset* (or *Action*->*Clear* if 308 | you don't have the latest *Docker* application). This removes the 309 | container while keeping its configuration. 310 | 10. Start the container again by clicking *Action*->*Start*. **NOTE**: The 311 | container may temporarily disappear from the list while it is re-created. 312 | 313 | ### unRAID 314 | 315 | For unRAID, a container image can be updated by following these steps: 316 | 317 | 1. Select the *Docker* tab. 318 | 2. Click the *Check for Updates* button at the bottom of the page. 319 | 3. Click the *update ready* link of the container to be updated. 320 | 321 | ## User/Group IDs 322 | 323 | When using data volumes (`-v` flags), permissions issues can occur between the 324 | host and the container. For example, the user within the container may not 325 | exist on the host. This could prevent the host from properly accessing files 326 | and folders on the shared volume. 327 | 328 | To avoid any problem, you can specify the user the application should run as. 329 | 330 | This is done by passing the user ID and group ID to the container via the 331 | `USER_ID` and `GROUP_ID` environment variables. 332 | 333 | To find the right IDs to use, issue the following command on the host, with the 334 | user owning the data volume on the host: 335 | 336 | id 337 | 338 | Which gives an output like this one: 339 | ```text 340 | uid=1000(myuser) gid=1000(myuser) groups=1000(myuser),4(adm),24(cdrom),27(sudo),46(plugdev),113(lpadmin) 341 | ``` 342 | 343 | The value of `uid` (user ID) and `gid` (group ID) are the ones that you should 344 | be given the container. 345 | 346 | ## Accessing the GUI 347 | 348 | Assuming that container's ports are mapped to the same host's ports, the 349 | graphical interface of the application can be accessed via: 350 | 351 | * A web browser: 352 | 353 | ```text 354 | http://:5800 355 | ``` 356 | 357 | * Any VNC client: 358 | 359 | ```text 360 | :5900 361 | ``` 362 | 363 | ## Security 364 | 365 | By default, access to the application's GUI is done over an unencrypted 366 | connection (HTTP or VNC). 367 | 368 | Secure connection can be enabled via the `SECURE_CONNECTION` environment 369 | variable. See the [Environment Variables](#environment-variables) section for 370 | more details on how to set an environment variable. 371 | 372 | When enabled, application's GUI is performed over an HTTPs connection when 373 | accessed with a browser. All HTTP accesses are automatically redirected to 374 | HTTPs. 375 | 376 | When using a VNC client, the VNC connection is performed over SSL. Note that 377 | few VNC clients support this method. [SSVNC] is one of them. 378 | 379 | [SSVNC]: http://www.karlrunge.com/x11vnc/ssvnc.html 380 | 381 | ### SSVNC 382 | 383 | [SSVNC] is a VNC viewer that adds encryption security to VNC connections. 384 | 385 | While the Linux version of [SSVNC] works well, the Windows version has some 386 | issues. At the time of writing, the latest version `1.0.30` is not functional, 387 | as a connection fails with the following error: 388 | ```text 389 | ReadExact: Socket error while reading 390 | ``` 391 | However, for your convenience, an unofficial and working version is provided 392 | here: 393 | 394 | https://github.com/jlesage/docker-baseimage-gui/raw/master/tools/ssvnc_windows_only-1.0.30-r1.zip 395 | 396 | The only difference with the official package is that the bundled version of 397 | `stunnel` has been upgraded to version `5.49`, which fixes the connection 398 | problems. 399 | 400 | ### Certificates 401 | 402 | Here are the certificate files needed by the container. By default, when they 403 | are missing, self-signed certificates are generated and used. All files have 404 | PEM encoded, x509 certificates. 405 | 406 | | Container Path | Purpose | Content | 407 | |---------------------------------|----------------------------|---------| 408 | |`/config/certs/vnc-server.pem` |VNC connection encryption. |VNC server's private key and certificate, bundled with any root and intermediate certificates.| 409 | |`/config/certs/web-privkey.pem` |HTTPs connection encryption.|Web server's private key.| 410 | |`/config/certs/web-fullchain.pem`|HTTPs connection encryption.|Web server's certificate, bundled with any root and intermediate certificates.| 411 | 412 | > [!TIP] 413 | > To prevent any certificate validity warnings/errors from the browser or VNC 414 | > client, make sure to supply your own valid certificates. 415 | 416 | > [!NOTE] 417 | > Certificate files are monitored and relevant daemons are automatically 418 | > restarted when changes are detected. 419 | 420 | ### VNC Password 421 | 422 | To restrict access to your application, a password can be specified. This can 423 | be done via two methods: 424 | * By using the `VNC_PASSWORD` environment variable. 425 | * By creating a `.vncpass_clear` file at the root of the `/config` volume. 426 | This file should contain the password in clear-text. During the container 427 | startup, content of the file is obfuscated and moved to `.vncpass`. 428 | 429 | The level of security provided by the VNC password depends on two things: 430 | * The type of communication channel (encrypted/unencrypted). 431 | * How secure the access to the host is. 432 | 433 | When using a VNC password, it is highly desirable to enable the secure 434 | connection to prevent sending the password in clear over an unencrypted channel. 435 | 436 | > [!CAUTION] 437 | > Password is limited to 8 characters. This limitation comes from the Remote 438 | > Framebuffer Protocol [RFC](https://tools.ietf.org/html/rfc6143) (see section 439 | > [7.2.2](https://tools.ietf.org/html/rfc6143#section-7.2.2)). Any characters 440 | > beyond the limit are ignored. 441 | 442 | ### Web Authentication 443 | 444 | Access to the application's GUI via a web browser can be protected with a login 445 | page. When web authentication is enabled, users have to provide valid 446 | credentials, otherwise access is denied. 447 | 448 | Web authentication can be enabled by setting the `WEB_AUTHENTICATION` 449 | environment variable to `1`. 450 | 451 | See the [Environment Variables](#environment-variables) section for more details 452 | on how to set an environment variable. 453 | 454 | > [!IMPORTANT] 455 | > Secure connection must also be enabled to use web authentication. 456 | > See the [Security](#security) section for more details. 457 | 458 | #### Configuring Users Credentials 459 | 460 | Two methods can be used to configure users credentials: 461 | 462 | 1. Via container environment variables. 463 | 2. Via password database. 464 | 465 | Containers environment variables can be used to quickly and easily configure 466 | a single user. Username and pasword are defined via the following environment 467 | variables: 468 | - `WEB_AUTHENTICATION_USERNAME` 469 | - `WEB_AUTHENTICATION_PASSWORD` 470 | 471 | See the [Environment Variables](#environment-variables) section for more details 472 | on how to set an environment variable. 473 | 474 | The second method is more secure and allows multiple users to be configured. 475 | The usernames and password hashes are saved into a password database, located at 476 | `/config/webauth-htpasswd` inside the container. This database file has the 477 | same format as htpasswd files of the Apache HTTP server. Note that password 478 | themselves are not saved into the database, but only their hash. The bcrypt 479 | password hashing function is used to generate hashes. 480 | 481 | Users are managed via the `webauth-user` tool included in the container: 482 | - To add a user password: `docker exec -ti webauth-user add `. 483 | - To update a user password: `docker exec -ti webauth-user update `. 484 | - To remove a user: `docker exec webauth-user del `. 485 | - To list users: `docker exec webauth-user user`. 486 | 487 | ## Reverse Proxy 488 | 489 | The following sections contain NGINX configurations that need to be added in 490 | order to reverse proxy to this container. 491 | 492 | A reverse proxy server can route HTTP requests based on the hostname or the URL 493 | path. 494 | 495 | ### Routing Based on Hostname 496 | 497 | In this scenario, each hostname is routed to a different application/container. 498 | 499 | For example, let's say the reverse proxy server is running on the same machine 500 | as this container. The server would proxy all HTTP requests sent to 501 | `video-duplicate-finder.domain.tld` to the container at `127.0.0.1:5800`. 502 | 503 | Here are the relevant configuration elements that would be added to the NGINX 504 | configuration: 505 | 506 | ```nginx 507 | map $http_upgrade $connection_upgrade { 508 | default upgrade; 509 | '' close; 510 | } 511 | 512 | upstream docker-video-duplicate-finder { 513 | # If the reverse proxy server is not running on the same machine as the 514 | # Docker container, use the IP of the Docker host here. 515 | # Make sure to adjust the port according to how port 5800 of the 516 | # container has been mapped on the host. 517 | server 127.0.0.1:5800; 518 | } 519 | 520 | server { 521 | [...] 522 | 523 | server_name video-duplicate-finder.domain.tld; 524 | 525 | location / { 526 | proxy_pass http://docker-video-duplicate-finder; 527 | } 528 | 529 | location /websockify { 530 | proxy_pass http://docker-video-duplicate-finder; 531 | proxy_http_version 1.1; 532 | proxy_set_header Upgrade $http_upgrade; 533 | proxy_set_header Connection $connection_upgrade; 534 | proxy_read_timeout 86400; 535 | } 536 | 537 | # Needed when audio support is enabled. 538 | location /websockify-audio { 539 | proxy_pass http://docker-video-duplicate-finder; 540 | proxy_http_version 1.1; 541 | proxy_set_header Upgrade $http_upgrade; 542 | proxy_set_header Connection $connection_upgrade; 543 | proxy_read_timeout 86400; 544 | } 545 | } 546 | 547 | ``` 548 | 549 | ### Routing Based on URL Path 550 | 551 | In this scenario, the hostname is the same, but different URL paths are used to 552 | route to different applications/containers. 553 | 554 | For example, let's say the reverse proxy server is running on the same machine 555 | as this container. The server would proxy all HTTP requests for 556 | `server.domain.tld/video-duplicate-finder` to the container at `127.0.0.1:5800`. 557 | 558 | Here are the relevant configuration elements that would be added to the NGINX 559 | configuration: 560 | 561 | ```nginx 562 | map $http_upgrade $connection_upgrade { 563 | default upgrade; 564 | '' close; 565 | } 566 | 567 | upstream docker-video-duplicate-finder { 568 | # If the reverse proxy server is not running on the same machine as the 569 | # Docker container, use the IP of the Docker host here. 570 | # Make sure to adjust the port according to how port 5800 of the 571 | # container has been mapped on the host. 572 | server 127.0.0.1:5800; 573 | } 574 | 575 | server { 576 | [...] 577 | 578 | location = /video-duplicate-finder {return 301 $scheme://$http_host/video-duplicate-finder/;} 579 | location /video-duplicate-finder/ { 580 | proxy_pass http://docker-video-duplicate-finder/; 581 | # Uncomment the following line if your Nginx server runs on a port that 582 | # differs from the one seen by external clients. 583 | #port_in_redirect off; 584 | location /video-duplicate-finder/websockify { 585 | proxy_pass http://docker-video-duplicate-finder/websockify/; 586 | proxy_http_version 1.1; 587 | proxy_set_header Upgrade $http_upgrade; 588 | proxy_set_header Connection $connection_upgrade; 589 | proxy_read_timeout 86400; 590 | } 591 | } 592 | } 593 | 594 | ``` 595 | ## Shell Access 596 | 597 | To get shell access to the running container, execute the following command: 598 | 599 | ```shell 600 | docker exec -ti CONTAINER sh 601 | ``` 602 | 603 | Where `CONTAINER` is the ID or the name of the container used during its 604 | creation. 605 | 606 | ## Support or Contact 607 | 608 | Having troubles with the container or have questions? Please 609 | [create a new issue]. 610 | 611 | For other great Dockerized applications, see https://jlesage.github.io/docker-apps. 612 | 613 | [create a new issue]: https://github.com/jlesage/docker-video-duplicate-finder/issues 614 | -------------------------------------------------------------------------------- /appdefs.yml: -------------------------------------------------------------------------------- 1 | --- 2 | 3 | # 4 | # Definitions for Video Duplicate Finder docker container. 5 | # 6 | # This file is used as data source to generate README.md and unRAID template files 7 | # from Jinja2 templates. 8 | # 9 | 10 | app: 11 | id: 20 12 | name: video-duplicate-finder 13 | friendly_name: Video Duplicate Finder 14 | gui_type: x11 15 | base_os: alpine 16 | project: 17 | description: |- 18 | Video Duplicate Finder is a cross-platform software to find duplicated video (and 19 | image) files on hard disk based on similiarity. That means unlike other duplicate 20 | finders, this one does also finds duplicates which have a different resolution, 21 | frame rate and even watermarked. 22 | url: https://github.com/0x90d/videoduplicatefinder 23 | unraid: 24 | support_url: https://forums.unraid.net/topic/134636-support-video-duplicate-finder/ 25 | category: "MediaApp:Video" 26 | documentation: 27 | changelog: 28 | - version: 25.02.2 29 | date: 2025-02-16 30 | changes: 31 | - 'Updated Video Duplicate Finder to version 3.0.x-e253212.' 32 | - version: 25.02.1 33 | date: 2025-02-09 34 | changes: 35 | - 'Updated baseimage to version 4.7.1, which brings the following changes (since last used version):' 36 | - '2:Added environment variable that allows configuring the web authentication token lifetime.' 37 | - '2:Fixed compatibility issues that were introduced with support of GTK4 applications.' 38 | - '2:Increased the default service ready timeout from 5 seconds to 10 seconds and allow runtime adjustment via environment variable.' 39 | - '2:Rebuild against latest distro images to get security fixes.' 40 | - version: 24.12.1 41 | date: 2024-12-07 42 | changes: 43 | - 'Updated baseimage to version 4.6.7, which brings the following changes:' 44 | - '2:Fixed web audio feature with URL path-based reverse proxy.' 45 | - '2:Fixed TLS secure connection method for VNC that was preventing web access.' 46 | - '2:Fixed CJK font installation.' 47 | - '2:Rebuild against latest distro images to get security fixes.' 48 | - version: 24.09.1 49 | date: 2024-09-29 50 | changes: 51 | - 'Updated Video Duplicate Finder to version 3.0.x-018ad52.' 52 | - 'Updated baseimage to version 4.6.4, which brings the following changes:' 53 | - '2:Fixed web authentication feature with URL path-based reverse proxy.' 54 | - '2:Rebuild against latest distro images to get security fixes.' 55 | - version: 24.07.1 56 | date: 2024-07-03 57 | changes: 58 | - 'Updated Video Duplicate Finder to version 3.0.x-f21ddfd.' 59 | - 'Updated baseimage to version 4.6.3, which brings the following changes:' 60 | - '2:Audio support through web browser.' 61 | - '2:Web authentication support.' 62 | - '2:Better support of GTK4 applications.' 63 | - '2:Updated noVNC to version 1.5.0.' 64 | - '2:Updated web UI components (Bootstrap, Font Awesome).' 65 | - '2:When connecting, the control bar is now temporarily shown only once.' 66 | - '2:During package mirror setup, make sure to keep permissions of copied files.' 67 | - version: 24.06.1 68 | date: 2024-06-09 69 | changes: 70 | - 'Updated Video Duplicate Finder to version 3.0.x-1d93ac0.' 71 | - version: 24.01.1 72 | date: 2024-01-20 73 | changes: 74 | - 'Updated Video Duplicate Finder to version 3.0.x-5d64ab2.' 75 | - 'Updated baseimage to version 4.5.3, which brings the following changes:' 76 | - '2:Disabled fullscreen support when page is loaded into an iFrame.' 77 | - '2:Rebuilt against latest distro images to get security fixes.' 78 | - version: 23.11.2 79 | date: 2023-11-19 80 | changes: 81 | - 'Updated baseimage to version 4.5.2, which brings the following changes:' 82 | - '2:Fixed issue that would cause the helper that takes ownership of a directory to fail when using a very high user or group ID.' 83 | - version: 23.11.1 84 | date: 2023-11-10 85 | changes: 86 | - 'Updated baseimage to version 4.5.1, which brings the following changes:' 87 | - '2:Mirror for packages installation can be set via the `PACKAGES_MIRROR` environment variable.' 88 | - '2:Improved the way the `take-ownership` script is working.' 89 | - '2:Readiness and minimum running time checks should not be done for a service defined with an interval.' 90 | - '2:Raise an error when a synched service fails to start.' 91 | - '2:Minimum running time check of a service was using an incorrect way to verify if process is still alive.' 92 | - '2:Fixed installation of CJK font.' 93 | - version: 23.08.1 94 | date: 2023-08-13 95 | changes: 96 | - 'Updated Video Duplicate Finder to version 3.0.x-424e8c6.' 97 | - 'Fixed usage of native FFmpeg llibraries.' 98 | - version: 23.05.1 99 | date: 2023-05-27 100 | changes: 101 | - 'Updated Video Duplicate Finder to version 3.0.x-c7908e7.' 102 | - 'Updated baseimage to version 4.4.2, which brings the following changes:' 103 | - '2:Rebuilt against latest distro images to get security fixes.' 104 | - '2:Updated X server to version 1.20.14.' 105 | - version: 23.04.1 106 | date: 2023-04-30 107 | changes: 108 | - 'Updated baseimage to version 4.4.1, which brings the following changes:' 109 | - '2:Updated TigerVNC to version 1.13.1.' 110 | - version: 23.03.2 111 | date: 2023-03-25 112 | changes: 113 | - 'Updated Video Duplicate Finder to version 3.0.x-a8660f6.' 114 | - version: 23.03.1 115 | date: 2023-03-05 116 | changes: 117 | - 'Updated baseimage to version 4.4.0, which brings the following changes:' 118 | - '2:Updated components providing access to application''s UI over web.' 119 | - '2:Improved web UI usage with touch devices.' 120 | - '2:Fixed issue with initialization of Linux users and groups when the `GROUP_ID` is also part of `SUP_GROUP_IDS`.' 121 | - version: 23.02.4 122 | date: 2023-02-25 123 | changes: 124 | - 'Updated Video Duplicate Finder to version 3.0.x-625a85f.' 125 | - 'Updated baseimage to version 4.3.6, which brings robustness related enhancements.' 126 | - version: 23.02.3 127 | date: 2023-02-12 128 | changes: 129 | - 'Updated Video Duplicate Finder to version 3.0.x-73d33ed.' 130 | - version: 23.02.2 131 | date: 2023-02-08 132 | changes: 133 | - 'Updated baseimage to version 4.3.4, which brings the following changes:' 134 | - '2:Fixed error message from openbox about missing Fontconfig cache directory.' 135 | - 'Do not use the OCI Docker image format yet to keep better compatibility (e.g with older docker clients).' 136 | - version: 23.02.1 137 | date: 2023-02-04 138 | changes: 139 | - 'Initial release.' 140 | 141 | container: 142 | storage_permissions: rw 143 | 144 | # Environment variables. 145 | environment_variables: [] 146 | 147 | # Volumes 148 | volumes: [] 149 | 150 | # Network ports 151 | ports: [] 152 | 153 | # Devices 154 | devices: [] 155 | -------------------------------------------------------------------------------- /rootfs/defaults/Settings.json: -------------------------------------------------------------------------------- 1 | { 2 | "Includes":["/storage"], 3 | "UseNativeFfmpegBinding":true, 4 | "HardwareAccelerationMode":0 5 | } 6 | -------------------------------------------------------------------------------- /rootfs/etc/cont-init.d/55-vdf.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | set -e # Exit immediately if a command exits with a non-zero status. 4 | set -u # Treat unset variables as an error. 5 | 6 | # Install default config file if no one exists. 7 | [ -f /config/Settings.json ] || cp /defaults/Settings.json /config/Settings.json 8 | 9 | # Handle dark mode. 10 | if is-bool-val-true "${DARK_MODE:-0}"; then 11 | DARKMODE_VAL="true" 12 | else 13 | DARKMODE_VAL="false" 14 | fi 15 | jq -c -M ".DarkMode = $DARKMODE_VAL" /config/Settings.json | sponge /config/Settings.json 16 | 17 | # vim:ft=sh:ts=4:sw=4:et:sts=4 18 | -------------------------------------------------------------------------------- /rootfs/etc/openbox/main-window-selection.xml: -------------------------------------------------------------------------------- 1 | normal 2 | Video Duplicate Finder * 3 | -------------------------------------------------------------------------------- /rootfs/startapp.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | export HOME=/config 3 | cd /storage 4 | exec /opt/vdf/VDF.GUI 5 | # vim:ft=sh:ts=4:sw=4:et:sts=4 6 | -------------------------------------------------------------------------------- /rootfs/usr/bin/xdg-open: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | ARG="$1" 4 | 5 | if [ -z "$ARG" ]; then 6 | exit 1 7 | fi 8 | 9 | if [ -d "$ARG" ]; then 10 | # We are trying to open a folder. 11 | pcmanfm "$ARG" 2>/dev/null 12 | elif [ -f "$ARG" ] ; then 13 | # We are trying to open a file. 14 | # Check if the file is a video. 15 | if [ "$(ffprobe -v error -select_streams v:0 -show_entries stream=codec_type -of csv=p=0 "$ARG" 2>/dev/null)" = "video" ]; then 16 | # This is a video file. Start playing with with ffplay. 17 | # Use the current screen size to determine the size of the ffplay window. 18 | DISPLAY_SIZE="$(obxprop --root | grep "^_NET_DESKTOP_GEOMETRY" | cut -d'=' -f2 | tr -d ',' | awk '{print $1; print $2}')" 19 | X="$(echo "$DISPLAY_SIZE" | head -n1)" 20 | Y="$(echo "$DISPLAY_SIZE" | tail -n1)" 21 | ffplay -loglevel quiet -x "$(expr "$X" / 2)" -y "$(expr "$Y" / 2)" "$ARG" 2>/dev/null 22 | else 23 | # Not a video file: open the folder containing the file. 24 | pcmanfm "$(dirname "$ARG")" 2>/dev/null 25 | fi 26 | else 27 | echo "don't know how to open: $ARG" 28 | exit 1 29 | fi 30 | -------------------------------------------------------------------------------- /rootfs/usr/share/applications/video-player.desktop: -------------------------------------------------------------------------------- 1 | [Desktop Entry] 2 | Type=Application 3 | Name=Video Player for VDF 4 | GenericName=Video Player 5 | Exec=xdg-open %f 6 | Categories=AudioVideo;Audio;Video;Player; 7 | MimeType=application/ogg;application/x-ogg;application/mxf;application/sdp;application/smil;application/x-smil;application/streamingmedia;application/x-streamingmedia;application/vnd.rn-realmedia;application/vnd.rn-realmedia-vbr;audio/aac;audio/x-aac;audio/vnd.dolby.heaac.1;audio/vnd.dolby.heaac.2;audio/aiff;audio/x-aiff;audio/m4a;audio/x-m4a;application/x-extension-m4a;audio/mp1;audio/x-mp1;audio/mp2;audio/x-mp2;audio/mp3;audio/x-mp3;audio/mpeg;audio/mpeg2;audio/mpeg3;audio/mpegurl;audio/x-mpegurl;audio/mpg;audio/x-mpg;audio/rn-mpeg;audio/musepack;audio/x-musepack;audio/ogg;audio/scpls;audio/x-scpls;audio/vnd.rn-realaudio;audio/wav;audio/x-pn-wav;audio/x-pn-windows-pcm;audio/x-realaudio;audio/x-pn-realaudio;audio/x-ms-wma;audio/x-pls;audio/x-wav;video/mpeg;video/x-mpeg2;video/x-mpeg3;video/mp4v-es;video/x-m4v;video/mp4;application/x-extension-mp4;video/divx;video/vnd.divx;video/msvideo;video/x-msvideo;video/ogg;video/quicktime;video/vnd.rn-realvideo;video/x-ms-afs;video/x-ms-asf;audio/x-ms-asf;application/vnd.ms-asf;video/x-ms-wmv;video/x-ms-wmx;video/x-ms-wvxvideo;video/x-avi;video/avi;video/x-flic;video/fli;video/x-flc;video/flv;video/x-flv;video/x-theora;video/x-theora+ogg;video/x-matroska;video/mkv;audio/x-matroska;application/x-matroska;video/webm;audio/webm;audio/vorbis;audio/x-vorbis;audio/x-vorbis+ogg;video/x-ogm;video/x-ogm+ogg;application/x-ogm;application/x-ogm-audio;application/x-ogm-video;application/x-shorten;audio/x-shorten;audio/x-ape;audio/x-wavpack;audio/x-tta;audio/AMR;audio/ac3;audio/eac3;audio/amr-wb;video/mp2t;audio/flac;audio/mp4;application/x-mpegurl;video/vnd.mpegurl;application/vnd.apple.mpegurl;audio/x-pn-au;video/3gp;video/3gpp;video/3gpp2;audio/3gpp;audio/3gpp2;video/dv;audio/dv;audio/opus;audio/vnd.dts;audio/vnd.dts.hd;audio/x-adpcm;application/x-cue;audio/m3u; 8 | Terminal=false 9 | NoDisplay=true 10 | -------------------------------------------------------------------------------- /src/ffmpeg/build.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | set -e # Exit immediately if a command exits with a non-zero status. 4 | set -u # Treat unset variables as an error. 5 | 6 | # Set same default compilation flags as abuild. 7 | export CFLAGS="-fomit-frame-pointer" 8 | export CXXFLAGS="$CFLAGS" 9 | export CPPFLAGS="$CFLAGS" 10 | export LDFLAGS="-fuse-ld=lld -Wl,--as-needed,-O1,--sort-common -Wl,--strip-all" 11 | 12 | export CC=xx-clang 13 | export CXX=xx-clang++ 14 | 15 | SCRIPT_DIR="$(cd "$(dirname "$0")" && pwd)" 16 | 17 | function log { 18 | echo ">>> $*" 19 | } 20 | 21 | FFMPEG_URL="${1:-}" 22 | 23 | if [ -z "$FFMPEG_URL" ]; then 24 | log "ERROR: FFmpeg URL missing." 25 | exit 1 26 | fi 27 | 28 | # 29 | # Install required packages. 30 | # 31 | HOST_PKGS=" \ 32 | curl \ 33 | build-base \ 34 | clang \ 35 | lld \ 36 | llvm \ 37 | nasm \ 38 | pkgconfig \ 39 | " 40 | 41 | TARGET_PKGS="\ 42 | g++ \ 43 | sdl2-dev \ 44 | dav1d-dev \ 45 | libva-dev \ 46 | libvdpau-dev \ 47 | vulkan-loader-dev \ 48 | " 49 | 50 | _asm= 51 | _onevpl= 52 | case "$(xx-info arch)" in 53 | amd64) 54 | _onevpl="--enable-libvpl" 55 | TARGET_PKGS="$TARGET_PKGS onevpl-dev" 56 | ;; 57 | 386) 58 | _asm="--disable-asm" 59 | ;; 60 | arm64) 61 | ;; 62 | arm) 63 | ;; 64 | *) 65 | echo "ERROR: Unsupported architecture: $(xx-info arch)" 66 | exit 1 67 | ;; 68 | esac 69 | 70 | log "Installing required Alpine packages..." 71 | apk --no-cache add $HOST_PKGS 72 | xx-apk --no-cache --no-scripts add $TARGET_PKGS 73 | xx-clang --setup-target-triple 74 | 75 | # 76 | # Download sources. 77 | # 78 | 79 | log "Downloading FFmpeg package..." 80 | mkdir /tmp/ffmpeg 81 | curl -# -L -f ${FFMPEG_URL} | tar xJ --strip 1 -C /tmp/ffmpeg 82 | 83 | # 84 | # Compile FFmpeg. 85 | # 86 | 87 | log "Configuring FFmpeg..." 88 | ( 89 | CROSS_FLAGS= 90 | if xx-info is-cross; then 91 | CROSS_FLAGS="\ 92 | --enable-cross-compile \ 93 | --arch=$(xx-info pkg-arch) \ 94 | --target-os=linux \ 95 | " 96 | fi 97 | 98 | cd /tmp/ffmpeg && \ 99 | ./configure \ 100 | $CROSS_FLAGS \ 101 | --cc=xx-clang \ 102 | --cxx=xx-clang++ \ 103 | --strip=$(xx-info)-strip \ 104 | --pkg-config=$(xx-info)-pkg-config \ 105 | --prefix=/usr \ 106 | --optflags="-O3" \ 107 | --disable-doc \ 108 | --disable-network \ 109 | --enable-shared \ 110 | --disable-static \ 111 | $_asm \ 112 | --enable-gpl \ 113 | --enable-version3 \ 114 | --enable-pic \ 115 | --enable-pthreads \ 116 | --enable-libdav1d \ 117 | --enable-vaapi \ 118 | --enable-vdpau \ 119 | --enable-vulkan \ 120 | $_onevpl \ 121 | ) 122 | 123 | log "Compiling FFmpeg..." 124 | make -C /tmp/ffmpeg -j$(nproc) 125 | 126 | log "Installing FFmpeg..." 127 | DESTDIR=/tmp/ffmpeg-install make -C /tmp/ffmpeg install 128 | rm -r /tmp/ffmpeg-install/usr/lib/pkgconfig 129 | -------------------------------------------------------------------------------- /src/vdf/build.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | set -e # Exit immediately if a command exits with a non-zero status. 4 | set -u # Treat unset variables as an error. 5 | 6 | SCRIPT_DIR="$(cd "$(dirname "$0")" && pwd)" 7 | 8 | function log { 9 | echo ">>> $*" 10 | } 11 | 12 | VIDEO_DUPLICATE_FINDER_URL="${1:-}" 13 | 14 | if [ -z "$VIDEO_DUPLICATE_FINDER_URL" ]; then 15 | log "ERROR: Video Duplicate Finder URL missing." 16 | exit 1 17 | fi 18 | 19 | # 20 | # Install required packages. 21 | # 22 | apk --no-cache add \ 23 | curl \ 24 | patch \ 25 | dotnet9-sdk \ 26 | 27 | # 28 | # Download sources. 29 | # 30 | 31 | log "Downloading Video Duplicate Finder package..." 32 | mkdir /tmp/vdf 33 | curl -# -L -f ${VIDEO_DUPLICATE_FINDER_URL} | tar xz --strip 1 -C /tmp/vdf 34 | 35 | # 36 | # Compile Video Duplicate Finder. 37 | # 38 | 39 | log "Patching Video Duplicate Finder..." 40 | PATCHES="\ 41 | disable-appearance-settings.patch \ 42 | disable-latest-release.patch \ 43 | disable-drag-and-drop-hint.patch \ 44 | set-current-folder.patch \ 45 | file-picker-suggested-start-location.patch \ 46 | dialog-window-owner-fix.patch \ 47 | " 48 | for PATCH in $PATCHES; do 49 | echo "Applying $PATCH..." 50 | patch -p1 -d /tmp/vdf < "$SCRIPT_DIR"/"$PATCH" 51 | done 52 | 53 | # Determine the dotnet arch. 54 | case "$(xx-info arch)" in 55 | amd64) dotnet_arch=x64;; 56 | arm64) dotnet_arch=arm64;; 57 | arm) dotnet_arch=arm;; 58 | *) echo "ERROR: Unsupported arch: $(xx-info arch)." && exit 1;; 59 | esac 60 | 61 | log "Building Video Duplicate Finder..." 62 | ( 63 | cd /tmp/vdf && \ 64 | dotnet nuget add source https://www.myget.org/F/sixlabors/api/v3/index.json 65 | dotnet publish -c Release --self-contained -r "linux-musl-$dotnet_arch" -o /tmp/vdf-install 66 | ) 67 | -------------------------------------------------------------------------------- /src/vdf/dialog-window-owner-fix.patch: -------------------------------------------------------------------------------- 1 | commit 0b438cb17ce1b92e5d2988e58897f0108bdd35e6 2 | Author: Jocelyn Le Sage 3 | Date: Sun Feb 16 11:41:21 2025 -0500 4 | 5 | Make sure to set the owner of input and message box windows. 6 | This fixes issues seen in some environments (e.g. Linux with Openbox), 7 | where the state of the main window was changed when displaying an input 8 | or message box. The focus was also not set to the new displayed window. 9 | 10 | diff --git a/VDF.GUI/Views/InputBoxView.xaml.cs b/VDF.GUI/Views/InputBoxView.xaml.cs 11 | index e14a7c5..1b1b79a 100644 12 | --- a/VDF.GUI/Views/InputBoxView.xaml.cs 13 | +++ b/VDF.GUI/Views/InputBoxView.xaml.cs 14 | @@ -52,6 +52,7 @@ namespace VDF.GUI.Views { 15 | ((InputBoxVM)DataContext).HasYesButton = (buttons & MessageBoxButtons.Yes) != 0; 16 | 17 | InitializeComponent(); 18 | + Owner = ApplicationHelpers.MainWindow; 19 | 20 | if (!VDF.GUI.Data.SettingsFile.Instance.DarkMode) 21 | RequestedThemeVariant = Avalonia.Styling.ThemeVariant.Light; 22 | diff --git a/VDF.GUI/Views/MessageBoxView.xaml.cs b/VDF.GUI/Views/MessageBoxView.xaml.cs 23 | index f02098b..55f0bca 100644 24 | --- a/VDF.GUI/Views/MessageBoxView.xaml.cs 25 | +++ b/VDF.GUI/Views/MessageBoxView.xaml.cs 26 | @@ -57,6 +57,7 @@ namespace VDF.GUI.Views { 27 | 28 | DataContext = vm; 29 | InitializeComponent(); 30 | + Owner = ApplicationHelpers.MainWindow; 31 | if (!VDF.GUI.Data.SettingsFile.Instance.DarkMode) 32 | RequestedThemeVariant = Avalonia.Styling.ThemeVariant.Light; 33 | //Opened += MessageBoxView_Opened; 34 | -------------------------------------------------------------------------------- /src/vdf/disable-appearance-settings.patch: -------------------------------------------------------------------------------- 1 | --- a/VDF.GUI/Views/MainWindow.xaml 2 | +++ b/VDF.GUI/Views/MainWindow.xaml 3 | @@ -1658,21 +1658,27 @@ 4 | Text="Appearance" /> 5 | 6 | 7 | + 14 | + 21 | + 28 | 9 | + 16 | 17 | 23 | + 30 | 31 | 32 | 33 | -------------------------------------------------------------------------------- /src/vdf/disable-latest-release.patch: -------------------------------------------------------------------------------- 1 | --- a/VDF.GUI/Views/MainWindow.xaml 2 | +++ b/VDF.GUI/Views/MainWindow.xaml 3 | @@ -232,6 +232,7 @@ 4 | 5 | 6 | 7 | + 16 | 17 | 18 | SaveLogCommand => ReactiveCommand.CreateFromTask(async () => { 24 | var result = await Utils.PickerDialogUtils.SaveFilePicker(new FilePickerSaveOptions() { 25 | + SuggestedStartLocation = await ApplicationHelpers.MainWindow.StorageProvider.TryGetFolderFromPathAsync(CoreUtils.CurrentFolder), 26 | DefaultExtension = ".txt", 27 | }); 28 | if (string.IsNullOrEmpty(result)) return; 29 | -------------------------------------------------------------------------------- /src/vdf/set-current-folder.patch: -------------------------------------------------------------------------------- 1 | Force the "current folder" to be `/config`, instead of the folder where reside VDF. 2 | --- a/VDF.Core/Utils/CoreUtils.cs 3 | +++ b/VDF.Core/Utils/CoreUtils.cs 4 | @@ -22,7 +22,7 @@ namespace VDF.Core.Utils { 5 | public static string CurrentFolder; 6 | static CoreUtils() { 7 | IsWindows = RuntimeInformation.IsOSPlatform(OSPlatform.Windows); 8 | - CurrentFolder = Path.GetDirectoryName(typeof(CoreUtils).Assembly.Location)!; 9 | + CurrentFolder = "/config"; 10 | } 11 | } 12 | } 13 | --------------------------------------------------------------------------------