├── .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 ├── etc │ ├── cont-init.d │ │ └── 55-cloudberrybackup.sh │ ├── machine-id │ └── services.d │ │ ├── app │ │ └── cbbLocalManagement.dep │ │ ├── cbbLocalManagement │ │ ├── is_ready │ │ ├── priority │ │ ├── ready_timeout │ │ ├── respawn │ │ ├── run │ │ └── sgid │ │ ├── cbbWebAccess │ │ ├── cbbLocalManagement.dep │ │ ├── disabled │ │ ├── priority │ │ ├── respawn │ │ ├── run │ │ └── sgid │ │ └── default │ │ └── cbbWebAccess.dep ├── startapp.sh └── usr │ └── share │ └── applications │ └── msp360-backup.desktop └── src └── cloudberry-backup └── build.sh /.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-cloudberry-backup/discussions 5 | about: Get help using this Docker container. 6 | - name: Documentation 7 | url: https://github.com/jlesage/docker-cloudberry-backup#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/cloudberry-backup 9 | PLATFORMS: linux/amd64 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-22.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-22.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 MSP360 Backup (formerly CloudBerry) 2 | [![Release](https://img.shields.io/github/release/jlesage/docker-cloudberry-backup.svg?logo=github&style=for-the-badge)](https://github.com/jlesage/docker-cloudberry-backup/releases/latest) 3 | [![Docker Image Size](https://img.shields.io/docker/image-size/jlesage/cloudberry-backup/latest?logo=docker&style=for-the-badge)](https://hub.docker.com/r/jlesage/cloudberry-backup/tags) 4 | [![Docker Pulls](https://img.shields.io/docker/pulls/jlesage/cloudberry-backup?label=Pulls&logo=docker&style=for-the-badge)](https://hub.docker.com/r/jlesage/cloudberry-backup) 5 | [![Docker Stars](https://img.shields.io/docker/stars/jlesage/cloudberry-backup?label=Stars&logo=docker&style=for-the-badge)](https://hub.docker.com/r/jlesage/cloudberry-backup) 6 | [![Build Status](https://img.shields.io/github/actions/workflow/status/jlesage/docker-cloudberry-backup/build-image.yml?logo=github&branch=master&style=for-the-badge)](https://github.com/jlesage/docker-cloudberry-backup/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-cloudberry-backup) 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 [MSP360 Backup](https://www.msp360.com/backup/). 11 | 12 | The graphical user interface (GUI) of the application can be accessed through a 13 | modern web browser, requiring no installation or configuration on the client 14 | 15 | --- 16 | 17 | [![MSP360 Backup logo](https://images.weserv.nl/?url=raw.githubusercontent.com/jlesage/docker-templates/master/jlesage/images/cloudberry-backup-icon.png&w=110)](https://www.msp360.com/backup/)[![MSP360 Backup](https://images.placeholders.dev/?width=416&height=110&fontFamily=monospace&fontWeight=400&fontSize=52&text=MSP360%20Backup&bgColor=rgba(0,0,0,0.0)&textColor=rgba(121,121,121,1))](https://www.msp360.com/backup/) 18 | 19 | Backup files and folders to cloud storage of your choice: Amazon S3, Azure Blob 20 | Storage, Google Cloud Storage, HP Cloud, Rackspace Cloud Files, OpenStack, 21 | DreamObjects and other. 22 | 23 | --- 24 | 25 | ## Quick Start 26 | 27 | **NOTE**: 28 | The Docker command provided in this quick start is an example, and parameters 29 | should be adjusted to suit your needs. 30 | 31 | Launch the MSP360 Backup docker container with the following command: 32 | ```shell 33 | docker run -d \ 34 | --name=cloudberry-backup \ 35 | -p 5800:5800 \ 36 | -v /docker/appdata/cloudberry-backup:/config:rw \ 37 | -v /home/user:/storage:ro \ 38 | jlesage/cloudberry-backup 39 | ``` 40 | 41 | Where: 42 | 43 | - `/docker/appdata/cloudberry-backup`: Stores the application's configuration, state, logs, and any files requiring persistency. 44 | - `/home/user`: Contains files from the host that need to be accessible to the application. 45 | 46 | Access the MSP360 Backup GUI by browsing to `http://your-host-ip:5800`. 47 | Files from the host appear under the `/storage` folder in the container. 48 | 49 | ## Documentation 50 | 51 | Full documentation is available at https://github.com/jlesage/docker-cloudberry-backup. 52 | 53 | ## Support or Contact 54 | 55 | Having troubles with the container or have questions? Please 56 | [create a new issue](https://github.com/jlesage/docker-cloudberry-backup/issues). 57 | 58 | For other Dockerized applications, visit https://jlesage.github.io/docker-apps. 59 | -------------------------------------------------------------------------------- /Dockerfile: -------------------------------------------------------------------------------- 1 | # 2 | # clouberry-backup Dockerfile 3 | # 4 | # https://github.com/jlesage/docker-cloudberry-backup 5 | # 6 | 7 | # Docker image version is provided via build arg. 8 | ARG DOCKER_IMAGE_VERSION= 9 | 10 | # Define software versions. 11 | ARG CLOUDBERRYBACKUP_VERSION=4.4.1.129 12 | ARG CLOUDBERRYBACKUP_TIMESTAMP=20250605033231 13 | 14 | # Define software download URLs. 15 | ARG CLOUDBERRYBACKUP_URL=https://download.msp360.com/ubuntu14_MSP360_MSP360Backup_v${CLOUDBERRYBACKUP_VERSION}_${CLOUDBERRYBACKUP_TIMESTAMP}.deb 16 | 17 | # Build CloudBerry Backup. 18 | FROM ubuntu:20.04 AS cbb 19 | ARG CLOUDBERRYBACKUP_URL 20 | COPY src/cloudberry-backup/build.sh /build-cloudberry-backup.sh 21 | RUN /build-cloudberry-backup.sh "$CLOUDBERRYBACKUP_URL" 22 | 23 | # Pull base image. 24 | FROM jlesage/baseimage-gui:alpine-3.16-v4.8.2 25 | 26 | ARG CLOUDBERRYBACKUP_VERSION 27 | ARG DOCKER_IMAGE_VERSION 28 | 29 | # Define working directory. 30 | WORKDIR /tmp 31 | 32 | # Install CloudBerry Backup. 33 | COPY --from=cbb ["/opt/local/MSP360 Backup", "/opt/local/MSP360 Backup"] 34 | COPY --from=cbb ["/opt/local/Online Backup", "/defaults/Online Backup"] 35 | COPY --from=cbb /usr/lib/x86_64-linux-gnu/gconv /usr/lib/x86_64-linux-gnu/gconv 36 | COPY --from=cbb /usr/lib/locale/locale-archive /usr/lib/locale/locale-archive 37 | RUN \ 38 | # Setup symbolic links for stuff that need to be outside the container. 39 | ln -s /config/"Online Backup" /opt/local/"Online Backup" && \ 40 | # Fix PAM authentication for web interface. 41 | ln -s base-auth /etc/pam.d/common-auth 42 | 43 | # Install dependencies. 44 | RUN \ 45 | add-pkg \ 46 | dpkg \ 47 | mkpasswd 48 | 49 | # Generate and install favicons. 50 | RUN \ 51 | APP_ICON_URL=https://github.com/jlesage/docker-templates/raw/master/jlesage/images/cloudberry-backup-icon.png && \ 52 | install_app_icon.sh "$APP_ICON_URL" 53 | 54 | # Add files. 55 | COPY rootfs/ / 56 | 57 | # Set internal environment variables. 58 | RUN \ 59 | set-cont-env APP_NAME "MSP360 Backup" && \ 60 | set-cont-env APP_VERSION "$CLOUDBERRYBACKUP_VERSION" && \ 61 | set-cont-env DOCKER_IMAGE_VERSION "$DOCKER_IMAGE_VERSION" && \ 62 | true 63 | 64 | # Set public environment variables. 65 | ENV \ 66 | CBB_WEB_INTERFACE_USER="" \ 67 | CBB_WEB_INTERFACE_PASSWORD="" 68 | 69 | # Define mountable directories. 70 | VOLUME ["/storage"] 71 | 72 | # Expose ports. 73 | # - 43210: CloudBerry Backup web interface (HTTP). 74 | # - 43211: CloudBerry Backup web interface (HTTPs). 75 | EXPOSE 43210 43211 76 | 77 | # Metadata. 78 | LABEL \ 79 | org.label-schema.name="cloudberry-backup" \ 80 | org.label-schema.description="Docker container for MSP360 Backup" \ 81 | org.label-schema.version="${DOCKER_IMAGE_VERSION:-unknown}" \ 82 | org.label-schema.vcs-url="https://github.com/jlesage/docker-cloudberry-backup" \ 83 | org.label-schema.schema-version="1.0" 84 | -------------------------------------------------------------------------------- /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 MSP360 Backup (formerly CloudBerry) 2 | [![Release](https://img.shields.io/github/release/jlesage/docker-cloudberry-backup.svg?logo=github&style=for-the-badge)](https://github.com/jlesage/docker-cloudberry-backup/releases/latest) 3 | [![Docker Image Size](https://img.shields.io/docker/image-size/jlesage/cloudberry-backup/latest?logo=docker&style=for-the-badge)](https://hub.docker.com/r/jlesage/cloudberry-backup/tags) 4 | [![Docker Pulls](https://img.shields.io/docker/pulls/jlesage/cloudberry-backup?label=Pulls&logo=docker&style=for-the-badge)](https://hub.docker.com/r/jlesage/cloudberry-backup) 5 | [![Docker Stars](https://img.shields.io/docker/stars/jlesage/cloudberry-backup?label=Stars&logo=docker&style=for-the-badge)](https://hub.docker.com/r/jlesage/cloudberry-backup) 6 | [![Build Status](https://img.shields.io/github/actions/workflow/status/jlesage/docker-cloudberry-backup/build-image.yml?logo=github&branch=master&style=for-the-badge)](https://github.com/jlesage/docker-cloudberry-backup/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 provides a Docker container for [MSP360 Backup](https://www.msp360.com/backup/). 10 | 11 | The graphical user interface (GUI) of the application can be accessed through a 12 | modern web browser, requiring no installation or configuration on the client 13 | side, or via any VNC client. 14 | 15 | --- 16 | 17 | [![MSP360 Backup logo](https://images.weserv.nl/?url=raw.githubusercontent.com/jlesage/docker-templates/master/jlesage/images/cloudberry-backup-icon.png&w=110)](https://www.msp360.com/backup/)[![MSP360 Backup](https://images.placeholders.dev/?width=416&height=110&fontFamily=monospace&fontWeight=400&fontSize=52&text=MSP360%20Backup&bgColor=rgba(0,0,0,0.0)&textColor=rgba(121,121,121,1))](https://www.msp360.com/backup/) 18 | 19 | Backup files and folders to cloud storage of your choice: Amazon S3, Azure Blob 20 | Storage, Google Cloud Storage, HP Cloud, Rackspace Cloud Files, OpenStack, 21 | DreamObjects and other. 22 | 23 | --- 24 | 25 | ## Table of Contents 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 and Tags](#docker-image-versioning-and-tags) 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 | * [Web Audio](#web-audio) 51 | * [Web File Manager](#web-file-manager) 52 | * [Shell Access](#shell-access) 53 | * [CloudBerry Backup Web Interface](#cloudberry-backup-web-interface) 54 | * [Credentials](#credentials) 55 | * [Support or Contact](#support-or-contact) 56 | 57 | ## Quick Start 58 | 59 | > [!IMPORTANT] 60 | > The Docker command provided in this quick start is an example, and parameters 61 | > should be adjusted to suit your needs. 62 | 63 | Launch the MSP360 Backup docker container with the following command: 64 | 65 | ```shell 66 | docker run -d \ 67 | --name=cloudberry-backup \ 68 | -p 5800:5800 \ 69 | -v /docker/appdata/cloudberry-backup:/config:rw \ 70 | -v /home/user:/storage:ro \ 71 | jlesage/cloudberry-backup 72 | ``` 73 | 74 | Where: 75 | 76 | - `/docker/appdata/cloudberry-backup`: Stores the application's configuration, state, logs, and any files requiring persistency. 77 | - `/home/user`: Contains files from the host that need to be accessible to the application. 78 | 79 | Access the MSP360 Backup GUI by browsing to `http://your-host-ip:5800`. 80 | Files from the host appear under the `/storage` folder in the container. 81 | 82 | ## Usage 83 | 84 | ```shell 85 | docker run [-d] \ 86 | --name=cloudberry-backup \ 87 | [-e =]... \ 88 | [-v :[:PERMISSIONS]]... \ 89 | [-p :]... \ 90 | jlesage/cloudberry-backup 91 | ``` 92 | 93 | | Parameter | Description | 94 | |-----------|-------------| 95 | | -d | Runs the container in the background. If not set, the container runs in the foreground. | 96 | | -e | Passes an environment variable to the container. See [Environment Variables](#environment-variables) for details. | 97 | | -v | Sets a volume mapping to share a folder or file between the host and the container. See [Data Volumes](#data-volumes) for details. | 98 | | -p | Sets a network port mapping to expose an internal container port to the host). See [Ports](#ports) for details. | 99 | 100 | ### Environment Variables 101 | 102 | To customize the container's behavior, you can pass environment variables using 103 | the `-e` parameter in the format `=`. 104 | 105 | | Variable | Description | Default | 106 | |----------------|----------------------------------------------|---------| 107 | |`USER_ID`| ID of the user the application runs as. See [User/Group IDs](#usergroup-ids) for details. | `1000` | 108 | |`GROUP_ID`| ID of the group the application runs as. See [User/Group IDs](#usergroup-ids) for details. | `1000` | 109 | |`SUP_GROUP_IDS`| Comma-separated list of supplementary group IDs for the application. | (no value) | 110 | |`UMASK`| Mask controlling permissions for newly created files and folders, specified in octal notation. By default, `0022` ensures files and folders are readable by all but writable only by the owner. See the umask calculator at http://wintelguy.com/umask-calc.pl. | `0022` | 111 | |`LANG`| Sets the [locale](https://en.wikipedia.org/wiki/Locale_(computer_software)), defining the application's language, if supported. Format 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 UTF-8 is `en_AU.UTF-8`. | `en_US.UTF-8` | 112 | |`TZ`| [TimeZone](http://en.wikipedia.org/wiki/List_of_tz_database_time_zones) used by the container. The timezone can also be set by mapping `/etc/localtime` between the host and the container. | `Etc/UTC` | 113 | |`KEEP_APP_RUNNING`| When set to `1`, the application is automatically restarted if it crashes or terminates. | `0` | 114 | |`APP_NICENESS`| Priority at which the application runs. A niceness value of -20 is the highest, 19 is the lowest and 0 the default. **NOTE**: A negative niceness (priority increase) requires additional permissions. The container must be run with the Docker option `--cap-add=SYS_NICE`. | `0` | 115 | |`INSTALL_PACKAGES`| Space-separated list of packages to install during container startup. List of available packages can be found at https://pkgs.alpinelinux.org. | (no value) | 116 | |`PACKAGES_MIRROR`| Mirror of the repository to use when installing packages. List of mirrors is available at https://mirrors.alpinelinux.org. | (no value) | 117 | |`CONTAINER_DEBUG`| When set to `1`, enables debug logging. | `0` | 118 | |`DISPLAY_WIDTH`| Width (in pixels) of the application's window. | `1920` | 119 | |`DISPLAY_HEIGHT`| Height (in pixels) of the application's window. | `1080` | 120 | |`DARK_MODE`| When set to `1`, enables dark mode for the application. See Dark Mode](#dark-mode) for details. | `0` | 121 | |`WEB_AUDIO`| When set to `1`, enables audio support, allowing audio produced by the application to play through the browser. See [Web Audio](#web-audio) for details. | `0` | 122 | |`WEB_FILE_MANAGER`| When set to `1`, enables the web file manager, allowing interaction with files inside the container through the web browser, supporting operations like renaming, deleting, uploading, and downloading. See [Web File Manager](#web-file-manager) for details. | `0` | 123 | |`WEB_FILE_MANAGER_ALLOWED_PATHS`| Comma-separated list of paths within the container that the file manager can access. By default, the container's entire filesystem is not accessible, and this variable specifies allowed paths. If set to `AUTO`, commonly used folders and those mapped to the container are automatically allowed. The value `ALL` allows access to all paths (no restrictions). See [Web File Manager](#web-file-manager) for details. | `AUTO` | 124 | |`WEB_FILE_MANAGER_DENIED_PATHS`| Comma-separated list of paths within the container that the file manager cannot access. A denied path takes precedence over an allowed path. See [Web File Manager](#web-file-manager) for details. | (no value) | 125 | |`WEB_AUTHENTICATION`| When set to `1`, protects the application's GUI with a login page when accessed via a web browser. Access is granted only with valid credentials. This feature requires the secure connection to be enabled. See [Web Authentication](#web-authentication) for details. | `0` | 126 | |`WEB_AUTHENTICATION_TOKEN_VALIDITY_TIME`| Lifetime of a token, in hours. A token is assigned to the user after successful login. As long as the token is valid, the user can access the application's GUI without logging in again. Once the token expires, the login page is displayed again. | `24` | 127 | |`WEB_AUTHENTICATION_USERNAME`| Optional username for web authentication. Provides a quick and easy way to configure credentials for a single user. For more secure configuration or multiple users, see the [Web Authentication](#web-authentication) section. | (no value) | 128 | |`WEB_AUTHENTICATION_PASSWORD`| Optional password for web authentication. Provides a quick and easy way to configure credentials for a single user. For more secure configuration or multiple users, see the [Web Authentication](#web-authentication) section. | (no value) | 129 | |`SECURE_CONNECTION`| When set to `1`, uses an encrypted connection to access the application's GUI (via web browser or VNC client). See [Security](#security) for details. | `0` | 130 | |`SECURE_CONNECTION_VNC_METHOD`| Method used for encrypted VNC connections. Possible values are `SSL` or `TLS`. See [Security](#security) for details. | `SSL` | 131 | |`SECURE_CONNECTION_CERTS_CHECK_INTERVAL`| Interval, in seconds, at which the system checks if web or VNC certificates have changed. When a change is detected, affected services are automatically restarted. A value of `0` disables the check. | `60` | 132 | |`WEB_LISTENING_PORT`| Port used by the web server to serve the application's GUI. This port is internal to the container and typically does not need to be changed. By default, a container uses the default bridge network, requiring each internal port to be mapped to an external port (using the `-p` or `--publish` argument). If another network type is used, changing this port may prevent conflicts with other services/containers. **NOTE**: A value of `-1` disables HTTP/HTTPS access to the application's GUI. | `5800` | 133 | |`VNC_LISTENING_PORT`| Port used by the VNC server to serve the application's GUI. This port is internal to the container and typically does not need to be changed. By default, a container uses the default bridge network, requiring each internal port to be mapped to an external port (using the `-p` or `--publish` argument). If another network type is used, changing this port may prevent conflicts with other services/containers. **NOTE**: A value of `-1` disables VNC access to the application's GUI. | `5900` | 134 | |`VNC_PASSWORD`| Password required to connect to the application's GUI. See the [VNC Password](#vnc-password) section for details. | (no value) | 135 | |`ENABLE_CJK_FONT`| When set to `1`, installs the open-source font `WenQuanYi Zen Hei`, supporting a wide range of Chinese/Japanese/Korean characters. | `0` | 136 | |`CBB_WEB_INTERFACE_USER`| Username to use to login to the CloudBerry Backup's web interface. | (no value) | 137 | |`CBB_WEB_INTERFACE_PASSWORD`| Password to use to login to the CloudBerry Backup's web interface. | (no value) | 138 | 139 | #### Deployment Considerations 140 | 141 | Many tools used to manage Docker containers extract environment variables 142 | defined by the Docker image to create or deploy the container. 143 | 144 | For example, this behavior is seen in: 145 | - The Docker application on Synology NAS 146 | - The Container Station on QNAP NAS 147 | - Portainer 148 | - etc. 149 | 150 | While this is useful for users to adjust environment variable values to suit 151 | their needs, keeping all of them can be confusing and even risky. 152 | 153 | A good practice is to set or retain only the variables necessary for the 154 | container to function as desired in your setup. If a variable is left at its 155 | default value, it can be removed. Keep in mind that all environment variables 156 | are optional; none are required for the container to start. 157 | 158 | Removing unneeded environment variables offers several benefits: 159 | 160 | - Prevents retaining variables no longer used by the container. Over time, 161 | with image updates, some variables may become obsolete. 162 | - Allows the Docker image to update or fix default values. With image updates, 163 | default values may change to address issues or support new features. 164 | - Avoids changes to variables that could disrupt the container's 165 | functionality. Some undocumented variables, like `PATH` or `ENV`, are 166 | required but not meant to be modified by users, yet container management 167 | tools may expose them. 168 | - Addresses a bug in Container Station on QNAP and the Docker application on 169 | Synology, where variables without values may not be allowed. This behavior 170 | is incorrect, as variables without values are valid. Removing unneeded 171 | variables prevents deployment issues on these devices. 172 | 173 | ### Data Volumes 174 | 175 | The following table describes the data volumes used by the container. Volume 176 | mappings are set using the `-v` parameter with a value in the format 177 | `:[:PERMISSIONS]`. 178 | 179 | | Container path | Permissions | Description | 180 | |-----------------|-------------|-------------| 181 | |`/config`| rw | Stores the application's configuration, state, logs, and any files requiring persistency. | 182 | |`/storage`| ro | Contains files from the host that need to be accessible to the application. | 183 | 184 | ### Ports 185 | 186 | The following table lists the ports used by the container. 187 | 188 | When using the default bridge network, ports can be mapped to the host using the 189 | `-p` parameter with value in the format `:`. The 190 | internal container port may not be changeable, but you can use any port on the 191 | host side. 192 | 193 | See the Docker [Docker Container Networking](https://docs.docker.com/config/containers/container-networking) 194 | documentation for details. 195 | 196 | | Port | Protocol | Mapping to Host | Description | 197 | |------|----------|-----------------|-------------| 198 | | 5800 | TCP | Optional | Port to access the application's GUI via the web interface. Mapping to the host is optional if web access is not needed. For non-default bridge networks, the port can be changed with the `WEB_LISTENING_PORT` environment variable. | 199 | | 5900 | TCP | Optional | Port to access the application's GUI via the VNC protocol. Mapping to the host is optional if VNC access is not needed. For non-default bridge networks, the port can be changed with the `VNC_LISTENING_PORT` environment variable. | 200 | | 43210 | TCP | Optional | Port used to access the CloudBerry Backup's web interface via HTTP. | 201 | | 43211 | TCP | Optional | Port used to access the CloudBerry Backup's web interface via HTTPs. | 202 | 203 | ### Changing Parameters of a Running Container 204 | 205 | Environment variables, volume mappings, and port mappings are specified when 206 | creating the container. To modify these parameters for an existing container, 207 | follow these steps: 208 | 209 | 1. Stop the container (if it is running): 210 | ```shell 211 | docker stop cloudberry-backup 212 | ``` 213 | 214 | 2. Remove the container: 215 | ```shell 216 | docker rm cloudberry-backup 217 | ``` 218 | 219 | 3. Recreate and start the container using the `docker run` command, adjusting 220 | parameters as needed. 221 | 222 | > [!NOTE] 223 | > Since all application data is saved under the `/config` container folder, 224 | > destroying and recreating the container does not result in data loss, and the 225 | > application resumes with the same state, provided the `/config` folder 226 | > mapping remains unchanged. 227 | 228 | ### Docker Compose File 229 | 230 | Below is an example `docker-compose.yml` file for use with 231 | [Docker Compose](https://docs.docker.com/compose/overview/). 232 | 233 | Adjust the configuration to suit your needs. Only mandatory settings are 234 | included in this example. 235 | 236 | ```yaml 237 | version: '3' 238 | services: 239 | cloudberry-backup: 240 | image: jlesage/cloudberry-backup 241 | ports: 242 | - "5800:5800" 243 | volumes: 244 | - "/docker/appdata/cloudberry-backup:/config:rw" 245 | - "/home/user:/storage:ro" 246 | ``` 247 | 248 | ## Docker Image Versioning and Tags 249 | 250 | Each release of a Docker image is versioned, and each version as its own image 251 | tag. Before October 2022, the versioning scheme followed 252 | [semantic versioning](https://semver.org). 253 | 254 | Since then, the versioning scheme has shifted to 255 | [calendar versioning](https://calver.org) with the format `YY.MM.SEQUENCE`, 256 | where: 257 | - `YY` is the zero-padded year (relative to year 2000). 258 | - `MM` is the zero-padded month. 259 | - `SEQUENCE` is the incremental release number within the month (first release 260 | is 1, second is 2, etc). 261 | 262 | View all available tags on [Docker Hub] or check the [Releases] page for version 263 | details. 264 | 265 | [Releases]: https://github.com/jlesage/docker-cloudberry-backup/releases 266 | [Docker Hub]: https://hub.docker.com/r/jlesage/cloudberry-backup/tags 267 | 268 | ## Docker Image Update 269 | 270 | The Docker image is regularly updated to incorporate new features, fix issues, 271 | or integrate newer versions of the containerized application. Several methods 272 | can be used to update the Docker image. 273 | 274 | If your system provides a built-in method for updating containers, this should 275 | be your primary approach. 276 | 277 | Alternatively, you can use [Watchtower], a container-based solution for 278 | automating Docker image updates. Watchtower seamlessly handles updates when a 279 | new image is available. 280 | 281 | To manually update the Docker image, follow these steps: 282 | 283 | 1. Fetch the latest image: 284 | ```shell 285 | docker pull jlesage/cloudberry-backup 286 | ``` 287 | 288 | 2. Stop the container: 289 | ```shell 290 | docker stop cloudberry-backup 291 | ``` 292 | 293 | 3. Remove the container: 294 | ```shell 295 | docker rm cloudberry-backup 296 | ``` 297 | 298 | 4. Recreate and start the container using the `docker run` command, with the 299 | same parameters used during initial deployment. 300 | 301 | [Watchtower]: https://github.com/containrrr/watchtower 302 | 303 | ### Synology 304 | 305 | For Synology NAS users, follow these steps to update a container image: 306 | 307 | 1. Open the *Docker* application. 308 | 2. Click *Registry* in the left pane. 309 | 3. In the search bar, type the name of the container (`jlesage/cloudberry-backup`). 310 | 4. Select the image, click *Download*, and choose the `latest` tag. 311 | 5. Wait for the download to complete. A notification will appear once done. 312 | 6. Click *Container* in the left pane. 313 | 7. Select your MSP360 Backup container. 314 | 8. Stop it by clicking *Action* -> *Stop*. 315 | 9. Clear the container by clicking *Action* -> *Reset* (or *Action* -> 316 | *Clear* if you don't have the latest *Docker* application). This removes 317 | the container while keeping its configuration. 318 | 10. Start the container again by clicking *Action* -> *Start*. **NOTE**: The 319 | container may temporarily disappear from the list while it is recreated. 320 | 321 | ### unRAID 322 | 323 | For unRAID users, update a container image with these steps: 324 | 325 | 1. Select the *Docker* tab. 326 | 2. Click the *Check for Updates* button at the bottom of the page. 327 | 3. Click the *apply update* link of the container to be updated. 328 | 329 | ## User/Group IDs 330 | 331 | When mapping data volumes (using the `-v` flag of the `docker run` command), 332 | permission issues may arise between the host and the container. Files and 333 | folders in a data volume are owned by a user, which may differ from the user 334 | running the application. Depending on permissions, this could prevent the 335 | container from accessing the shared volume. 336 | 337 | To avoid this, specify the user the application should run as using the 338 | `USER_ID` and `GROUP_ID` environment variables. 339 | 340 | To find the appropriate IDs, run the following command on the host for the user 341 | owning the data volume: 342 | 343 | ```shell 344 | id 345 | ``` 346 | 347 | This produces output like: 348 | 349 | ``` 350 | uid=1000(myuser) gid=1000(myuser) groups=1000(myuser),4(adm),24(cdrom),27(sudo),46(plugdev),113(lpadmin) 351 | ``` 352 | 353 | Use the `uid` (user ID) and `gid` (group ID) values to configure the container. 354 | 355 | ## Accessing the GUI 356 | 357 | Assuming the container's ports are mapped to the same host's ports, access the 358 | application's GUI as follows: 359 | 360 | - Via a web browser: 361 | 362 | ```text 363 | http://:5800 364 | ``` 365 | 366 | - Via any VNC client: 367 | 368 | ```text 369 | :5900 370 | ``` 371 | 372 | ## Security 373 | 374 | By default, access to the application's GUI uses an unencrypted connection (HTTP 375 | or VNC). 376 | 377 | A secure connection can be enabled via the `SECURE_CONNECTION` environment 378 | variable. See the [Environment Variables](#environment-variables) section for 379 | details on configuring environment variables. 380 | 381 | When enabled, the GUI is accessed over HTTPS when using a browser, with all HTTP 382 | accesses redirected to HTTPS. 383 | 384 | For VNC clients, the connection can be secured using on of two methods, 385 | configured via the `SECURE_CONNECTION_VNC_METHOD` environment variable: 386 | 387 | - `SSL`: An SSL tunnel is used to transport the VNC connection. Few VNC 388 | clients supports this method; [SSVNC] is one that does. 389 | - `TLS`: A VNC security type negotiated during the VNC handshake. It uses TLS 390 | to establish a secure connection. Clients may optionally validate the 391 | server’s certificate. Valid certificates must be provided for this 392 | validation to succeed. See [Certificates](#certificates) for details. 393 | [TigerVNC] is a client that supports TLS encryption. 394 | 395 | [TigerVNC]: https://tigervnc.org 396 | 397 | ### SSVNC 398 | 399 | [SSVNC] is a VNC viewer that adds encryption to VNC connections by using an 400 | SSL tunnel to transport the VNC traffic. 401 | 402 | While the Linux version of [SSVNC] works well, the Windows version has issues. 403 | At the time of writing, the latest version `1.0.30` fails with the error: 404 | 405 | ```text 406 | ReadExact: Socket error while reading 407 | ``` 408 | 409 | For convenience, an unofficial, working version is provided here: 410 | 411 | https://github.com/jlesage/docker-baseimage-gui/raw/master/tools/ssvnc_windows_only-1.0.30-r1.zip 412 | 413 | This version upgrades the bundled `stunnel` to version `5.49`, resolving the 414 | connection issues. 415 | 416 | [SSVNC]: http://www.karlrunge.com/x11vnc/ssvnc.html 417 | 418 | ### Certificates 419 | 420 | The following certificate files are required by the container. If missing, 421 | self-signed certificates are generated and used. All files are PEM-encoded x509 422 | certificates. 423 | 424 | | Container Path | Purpose | Content | 425 | |---------------------------------|----------------------------|---------| 426 | |`/config/certs/vnc-server.pem` |VNC connection encryption. |VNC server's private key and certificate, bundled with any root and intermediate certificates.| 427 | |`/config/certs/web-privkey.pem` |HTTPS connection encryption.|Web server's private key.| 428 | |`/config/certs/web-fullchain.pem`|HTTPS connection encryption.|Web server's certificate, bundled with any root and intermediate certificates.| 429 | 430 | > [!TIP] 431 | > To avoid certificate validity warnings or errors in browsers or VNC clients, 432 | > provide your own valid certificates. 433 | 434 | > [!NOTE] 435 | > Certificate files are monitored, and relevant services are restarted when 436 | > changes are detected. 437 | 438 | ### VNC Password 439 | 440 | To restrict access to your application, set a password using one of two methods: 441 | - Via the `VNC_PASSWORD` environment variable. 442 | - Via a `.vncpass_clear` file at the root of the `/config` volume, containing 443 | the password in clear text. During container startup, the content is 444 | obfuscated and moved to `.vncpass`. 445 | 446 | The security of the VNC password depends on: 447 | - The communication channel (encrypted or unencrypted). 448 | - The security of host access. 449 | 450 | When using a VNC password, enable a secure connection to prevent sending the 451 | password in clear text over an unencrypted channel. 452 | 453 | Unauthorized users with sufficient host privileges can retrieve the password by: 454 | 455 | - Viewing the `VNC_PASSWORD` environment variable via `docker inspect`. By 456 | default, the `docker` command requires root access, but it can be configured 457 | to allow users in a specific group. 458 | - Decrypting the `/config/.vncpass` file, which requires root or `USER_ID` 459 | permissions. 460 | 461 | > [!CAUTION] 462 | > VNC password is limited to 8 characters. This limitation comes from the Remote 463 | > Framebuffer Protocol [RFC](https://tools.ietf.org/html/rfc6143) (see section 464 | > [7.2.2](https://tools.ietf.org/html/rfc6143#section-7.2.2)). 465 | 466 | ### Web Authentication 467 | 468 | Access to the application's GUI via a web browser can be protected with a login 469 | page. When enabled, users must provide valid credentials to gain access. 470 | 471 | Enable web authentication by setting the `WEB_AUTHENTICATION` environment 472 | variable to `1`. See the [Environment Variables](#environment-variables) section 473 | for details on configuring environment variables. 474 | 475 | > [!IMPORTANT] 476 | > Web authentication requires a secure connection to be enabled. See 477 | > [Security](#security) for details. 478 | 479 | #### Configuring Users Credentials 480 | 481 | User credentials can be configured in two ways: 482 | 483 | 1. Via container environment variables. 484 | 2. Via a password database. 485 | 486 | Container environment variables provide a quick way to configure a single user. 487 | Set the username and password using: 488 | - `WEB_AUTHENTICATION_USERNAME` 489 | - `WEB_AUTHENTICATION_PASSWORD` 490 | 491 | See the [Environment Variables](#environment-variables) section for details on 492 | configuring environment variables. 493 | 494 | For a more secure method or to configure multiple users, use a password database 495 | at `/config/webauth-htpasswd` within the container. This file uses the Apache 496 | HTTP server's htpasswd format, storing bcrypt-hashed passwords. 497 | 498 | Manage users with the `webauth-user` tool: 499 | - Add a user: `docker exec -ti webauth-user add ` 500 | - Update a user: `docker exec -ti webauth-user update ` 501 | - Remove a user: `docker exec webauth-user del ` 502 | - List users: `docker exec webauth-user list` 503 | 504 | ## Reverse Proxy 505 | 506 | The following sections provide NGINX configurations for setting up a reverse 507 | proxy to this container. 508 | 509 | A reverse proxy server can route HTTP requests based on the hostname or URL 510 | path. 511 | 512 | ### Routing Based on Hostname 513 | 514 | In this scenario, each hostname is routed to a different application or 515 | container. 516 | 517 | For example, if the reverse proxy server runs on the same machine as this 518 | container, it would proxy all HTTP requests for `cloudberry-backup.domain.tld` to 519 | the container at `127.0.0.1:5800`. 520 | 521 | Here are the relevant configuration elements to add to the NGINX configuration: 522 | 523 | ```nginx 524 | map $http_upgrade $connection_upgrade { 525 | default upgrade; 526 | '' close; 527 | } 528 | 529 | upstream docker-cloudberry-backup { 530 | # If the reverse proxy server is not running on the same machine as the 531 | # Docker container, use the IP of the Docker host here. 532 | # Make sure to adjust the port according to how port 5800 of the 533 | # container has been mapped on the host. 534 | server 127.0.0.1:5800; 535 | } 536 | 537 | server { 538 | [...] 539 | 540 | server_name cloudberry-backup.domain.tld; 541 | 542 | location / { 543 | proxy_pass http://docker-cloudberry-backup; 544 | } 545 | 546 | location /websockify { 547 | proxy_pass http://docker-cloudberry-backup; 548 | proxy_http_version 1.1; 549 | proxy_set_header Upgrade $http_upgrade; 550 | proxy_set_header Connection $connection_upgrade; 551 | proxy_read_timeout 86400; 552 | } 553 | 554 | # Needed when audio support is enabled. 555 | location /websockify-audio { 556 | proxy_pass http://docker-cloudberry-backup; 557 | proxy_http_version 1.1; 558 | proxy_set_header Upgrade $http_upgrade; 559 | proxy_set_header Connection $connection_upgrade; 560 | proxy_read_timeout 86400; 561 | } 562 | } 563 | 564 | ``` 565 | 566 | ### Routing Based on URL Path 567 | 568 | In this scenario, the same hostname is used, but different URL paths route to 569 | different applications or containers. For example, if the reverse proxy server 570 | runs on the same machine as this container, it would proxy all HTTP requests for 571 | `server.domain.tld/filebot` to the container at `127.0.0.1:5800`. 572 | 573 | Here are the relevant configuration elements to add to the NGINX configuration: 574 | 575 | ```nginx 576 | map $http_upgrade $connection_upgrade { 577 | default upgrade; 578 | '' close; 579 | } 580 | 581 | upstream docker-cloudberry-backup { 582 | # If the reverse proxy server is not running on the same machine as the 583 | # Docker container, use the IP of the Docker host here. 584 | # Make sure to adjust the port according to how port 5800 of the 585 | # container has been mapped on the host. 586 | server 127.0.0.1:5800; 587 | } 588 | 589 | server { 590 | [...] 591 | 592 | location = /cloudberry-backup {return 301 $scheme://$http_host/cloudberry-backup/;} 593 | location /cloudberry-backup/ { 594 | proxy_pass http://docker-cloudberry-backup/; 595 | # Uncomment the following line if your Nginx server runs on a port that 596 | # differs from the one seen by external clients. 597 | #port_in_redirect off; 598 | location /cloudberry-backup/websockify { 599 | proxy_pass http://docker-cloudberry-backup/websockify; 600 | proxy_http_version 1.1; 601 | proxy_set_header Upgrade $http_upgrade; 602 | proxy_set_header Connection $connection_upgrade; 603 | proxy_read_timeout 86400; 604 | } 605 | # Needed when audio support is enabled. 606 | location /cloudberry-backup/websockify-audio { 607 | proxy_pass http://docker-cloudberry-backup/websockify-audio; 608 | proxy_http_version 1.1; 609 | proxy_set_header Upgrade $http_upgrade; 610 | proxy_set_header Connection $connection_upgrade; 611 | proxy_read_timeout 86400; 612 | } 613 | } 614 | } 615 | 616 | ``` 617 | 618 | ### Web Audio 619 | 620 | The container supports streaming audio from the application, played through the 621 | user's web browser. Audio is not supported for VNC clients. 622 | 623 | Audio is streamed with the following specification: 624 | 625 | * Raw PCM format 626 | * 2 channels 627 | * 16-bit sample depth 628 | * 44.1kHz sample rate 629 | 630 | Enable web audio by setting `WEB_AUDIO` to `1`. See the 631 | [Environment Variables](#environment-variables) section for details on 632 | configuring environment variables. 633 | 634 | ### Web File Manager 635 | 636 | The container includes a simple file manager for interacting with container 637 | files through a web browser, supporting operations like renaming, deleting, 638 | uploading, and downloading. 639 | 640 | Enable the file manager by setting `WEB_FILE_MANAGER` to `1`. See the 641 | [Environment Variables](#environment-variables) section for details on 642 | configuring environment variables. 643 | 644 | By default, the container's entire filesystem is not accessible. The 645 | `WEB_FILE_MANAGER_ALLOWED_PATHS` environment variable is a comma-separated list 646 | that specifies which paths within the container are allowed to be accessed. When 647 | set to `AUTO` (the default), it automatically includes commonly used folders and 648 | any folders mapped to the container. 649 | 650 | The `WEB_FILE_MANAGER_DENIED_PATHS` environment variable defines which paths are 651 | explicitly denied access by the file manager. A denied path takes precedence 652 | over an allowed one. 653 | 654 | ## Shell Access 655 | 656 | To access the shell of a running container, execute the following command: 657 | 658 | ```shell 659 | docker exec -ti CONTAINER sh 660 | ``` 661 | 662 | Where `CONTAINER` is the ID or the name of the container used during its 663 | creation. 664 | 665 | ## CloudBerry Backup Web Interface 666 | 667 | CloudBerry Backup provides its own web interface. It can be accessed 668 | via HTTP port 43210 and/or HTTPs port 43211. 669 | 670 | ### Credentials 671 | 672 | A username and password must be configured before being able to login to the web interface. 673 | 674 | The username is set via the `CBB_WEB_INTERFACE_USER` environment variable. 675 | 676 | There are two ways of setting the password: 677 | - Via the `CBB_WEB_INTERFACE_PASSWORD` environment variable. 678 | - By storing the password hash in `/config/.cbb_web_interface_pass_hash` 679 | (container path). 680 | 681 | The password hash can be generated by the command `mkpasswd`. For example, to 682 | generate the hash using the SHA-512 method: 683 | ``` 684 | mkpasswd -m sha-512 685 | ``` 686 | 687 | The whole output of the command must be saved into 688 | `/config/.cbb_web_interface_pass_hash`. Here is an example of the output: 689 | ``` 690 | $6$VkhGUiCpmE$Mqm8k4oBKF0O4gqstzUvq32FJ3nxgAMjyhqbESCPj8nqSvcQoZw4d/U.oQYN/rsh4FonIoPjsvOn/WQSG84RE/ 691 | ``` 692 | 693 | An other way of generating the password hash is to set the password in 694 | clear-text in `/config/.cbb_web_interface_clear_text_pass`. When the container 695 | starts, a hash is performed using the content of this file and is automatically 696 | saved to `/config/.cbb_web_interface_pass_hash`. Then, the clear-text password 697 | file is deleted. 698 | 699 | ## Support or Contact 700 | 701 | Having troubles with the container or have questions? Please 702 | [create a new issue](https://github.com/jlesage/docker-cloudberry-backup/issues). 703 | 704 | For other Dockerized applications, visit https://jlesage.github.io/docker-apps. 705 | -------------------------------------------------------------------------------- /appdefs.yml: -------------------------------------------------------------------------------- 1 | --- 2 | 3 | # 4 | # Definitions for CloudBerry Backup 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: 2 12 | name: cloudberry-backup 13 | friendly_name: MSP360 Backup 14 | title_name: MSP360 Backup (formerly CloudBerry) 15 | gui_type: x11 16 | base_os: alpine 17 | project: 18 | description: |- 19 | Backup files and folders to cloud storage of your choice: Amazon S3, Azure Blob 20 | Storage, Google Cloud Storage, HP Cloud, Rackspace Cloud Files, OpenStack, 21 | DreamObjects and other. 22 | url: https://www.msp360.com/backup/ 23 | unraid: 24 | name: CloudBerryBackup 25 | support_url: https://forums.unraid.net/topic/57217-support-cloudberry-backup/ 26 | category: "Backup:" 27 | documentation: 28 | sections: 29 | - title: CloudBerry Backup Web Interface 30 | level: 2 31 | content: |- 32 | CloudBerry Backup provides its own web interface. It can be accessed 33 | via HTTP port 43210 and/or HTTPs port 43211. 34 | - title: Credentials 35 | level: 3 36 | content: |- 37 | A username and password must be configured before being able to login to the web interface. 38 | 39 | The username is set via the `CBB_WEB_INTERFACE_USER` environment variable. 40 | 41 | There are two ways of setting the password: 42 | - Via the `CBB_WEB_INTERFACE_PASSWORD` environment variable. 43 | - By storing the password hash in `/config/.cbb_web_interface_pass_hash` 44 | (container path). 45 | 46 | The password hash can be generated by the command `mkpasswd`. For example, to 47 | generate the hash using the SHA-512 method: 48 | ``` 49 | mkpasswd -m sha-512 50 | ``` 51 | 52 | The whole output of the command must be saved into 53 | `/config/.cbb_web_interface_pass_hash`. Here is an example of the output: 54 | ``` 55 | $6$VkhGUiCpmE$Mqm8k4oBKF0O4gqstzUvq32FJ3nxgAMjyhqbESCPj8nqSvcQoZw4d/U.oQYN/rsh4FonIoPjsvOn/WQSG84RE/ 56 | ``` 57 | 58 | An other way of generating the password hash is to set the password in 59 | clear-text in `/config/.cbb_web_interface_clear_text_pass`. When the container 60 | starts, a hash is performed using the content of this file and is automatically 61 | saved to `/config/.cbb_web_interface_pass_hash`. Then, the clear-text password 62 | file is deleted. 63 | changelog: 64 | - version: 25.07.1 65 | date: 2025-07-05 66 | changes: 67 | - 'Updated MSP360 Backup to version 4.4.1.129.' 68 | - 'Updated baseimage to version 4.8.2, which brings the following changes:' 69 | - '2:Fixed automatic reconnect of the web interface when web authentication is enabled.' 70 | - '2:Fixed some resources that could not be accessed behind a reverse proxy based on URL path.' 71 | - version: 25.06.2 72 | date: 2025-06-25 73 | changes: 74 | - 'Updated baseimage to version 4.8.1, which brings the following changes:' 75 | - '2:Fixed crash with some binaries on systems using old kernel.' 76 | - version: 25.06.1 77 | date: 2025-06-20 78 | changes: 79 | - 'Updated MSP360 Backup to version 4.3.4.349.' 80 | - 'Updated baseimage to version 4.8.0, which brings the following changes:' 81 | - '2:Added automatic reconnect support of the web interface.' 82 | - '2:Added web file manager.' 83 | - '2:Updated noVNC to version 1.6.0.' 84 | - '2:Updated web UI components (Bootstrap).' 85 | - '2:Do not ask VNC password when accessing the web interface and web authentication is enabled.' 86 | - version: 25.02.1 87 | date: 2025-02-09 88 | changes: 89 | - 'Updated MSP360 Backup to version 4.3.3.255.' 90 | - 'Updated baseimage to version 4.7.1, which brings the following changes (since last used version):' 91 | - '2:Added environment variable that allows configuring the web authentication token lifetime.' 92 | - '2:Fixed compatibility issues that were introduced with support of GTK4 applications.' 93 | - '2:Increased the default service ready timeout from 5 seconds to 10 seconds and allow runtime adjustment via environment variable.' 94 | - '2:Rebuild against latest distro images to get security fixes.' 95 | - version: 24.12.1 96 | date: 2024-12-07 97 | changes: 98 | - 'Updated baseimage to version 4.6.7, which brings the following changes:' 99 | - '2:Fixed web audio feature with URL path-based reverse proxy.' 100 | - '2:Fixed TLS secure connection method for VNC that was preventing web access.' 101 | - '2:Fixed CJK font installation.' 102 | - '2:Rebuild against latest distro images to get security fixes.' 103 | - version: 24.10.1 104 | date: 2024-10-28 105 | changes: 106 | - 'Updated MSP360 Backup to version 4.3.1.115.' 107 | - version: 24.09.1 108 | date: 2024-09-29 109 | changes: 110 | - 'Updated baseimage to version 4.6.4, which brings the following changes:' 111 | - '2:Fixed web authentication feature with URL path-based reverse proxy.' 112 | - '2:Rebuild against latest distro images to get security fixes.' 113 | - version: 24.08.1 114 | date: 2024-08-30 115 | changes: 116 | - 'Updated MSP360 Backup to version 4.3.0.54.' 117 | - version: 24.07.1 118 | date: 2024-07-04 119 | changes: 120 | - 'Updated MSP360 Backup to version 4.2.4.340.' 121 | - 'Updated baseimage to version 4.6.3, which brings the following changes:' 122 | - '2:Audio support through web browser.' 123 | - '2:Web authentication support.' 124 | - '2:Better support of GTK4 applications.' 125 | - '2:Updated noVNC to version 1.5.0.' 126 | - '2:Updated web UI components (Bootstrap, Font Awesome).' 127 | - '2:When connecting, the control bar is now temporarily shown only once.' 128 | - '2:During package mirror setup, make sure to keep permissions of copied files.' 129 | - version: 24.01.1 130 | date: 2024-01-20 131 | changes: 132 | - 'Updated MSP360 Backup (formerly CloudBerry) to version 4.2.0.81.' 133 | - 'Updated baseimage to version 4.5.3, which brings the following changes:' 134 | - '2:Disabled fullscreen support when page is loaded into an iFrame.' 135 | - '2:Rebuilt against latest distro images to get security fixes.' 136 | - version: 23.11.2 137 | date: 2023-11-19 138 | changes: 139 | - 'Updated baseimage to version 4.5.2, which brings the following changes:' 140 | - '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.' 141 | - version: 23.11.1 142 | date: 2023-11-10 143 | changes: 144 | - 'Updated baseimage to version 4.5.1, which brings the following changes:' 145 | - '2:Mirror for packages installation can be set via the `PACKAGES_MIRROR` environment variable.' 146 | - '2:Improved the way the `take-ownership` script is working.' 147 | - '2:Readiness and minimum running time checks should not be done for a service defined with an interval.' 148 | - '2:Raise an error when a synched service fails to start.' 149 | - '2:Minimum running time check of a service was using an incorrect way to verify if process is still alive.' 150 | - '2:Fixed installation of CJK font.' 151 | - version: 23.10.1 152 | date: 2023-10-16 153 | changes: 154 | - 'Updated CloudBerry Backup to version 4.1.5.822.' 155 | - version: 23.08.1 156 | date: 2023-08-04 157 | changes: 158 | - 'Updated CloudBerry Backup to version 4.1.3.513.' 159 | - version: 23.06.1 160 | date: 2023-06-07 161 | changes: 162 | - 'Updated baseimage to version 4.4.2, which brings the following changes:' 163 | - '2:Rebuilt against latest distro images to get security fixes.' 164 | - '2:Updated X server to version 1.20.14.' 165 | - version: 23.05.1 166 | date: 2023-05-16 167 | changes: 168 | - 'Updated CloudBerry Backup to version 4.1.1.137.' 169 | - version: 23.04.2 170 | date: 2023-04-29 171 | changes: 172 | - 'Updated baseimage to version 4.4.1, which brings the following changes:' 173 | - '2:Updated TigerVNC to version 1.13.1.' 174 | - version: 23.04.1 175 | date: 2023-04-05 176 | changes: 177 | - 'Updated CloudBerry Backup to version 4.1.0.103.' 178 | - version: 23.03.2 179 | date: 2023-03-11 180 | changes: 181 | - 'Updated CloudBerry Backup to version 4.0.3.412.' 182 | - version: 23.03.1 183 | date: 2023-03-05 184 | changes: 185 | - 'Updated baseimage to version 4.4.0, which brings the following changes:' 186 | - '2:Updated components providing access to application''s UI over web.' 187 | - '2:Improved web UI usage with touch devices.' 188 | - '2:Fixed issue with initialization of Linux users and groups when the `GROUP_ID` is also part of `SUP_GROUP_IDS`.' 189 | - '2:Limit the maximum number of opened files on system having a very large, unlimited value. This prevents unnecessary waste of CPU resources and time for applications trying to close all possible file descriptors.' 190 | - version: 23.02.2 191 | date: 2023-02-08 192 | changes: 193 | - 'Updated baseimage to version 4.3.4, which brings the following changes:' 194 | - '2:Fixed error message from openbox about missing Fontconfig cache directory.' 195 | - 'Do not use the OCI Docker image format yet to keep better compatibility (e.g with older docker clients).' 196 | - version: 23.02.1 197 | date: 2023-02-04 198 | changes: 199 | - 'Updated baseimage to version 4.3.3, which brings robustness related enhancements.' 200 | - version: 23.01.1 201 | date: 2023-01-04 202 | changes: 203 | - 'Update of the baseimage to version 4.3.1 brings the following changes:' 204 | - '2:Control menu can be moved to the right side of the screen.' 205 | - '2:Automatic focus of the clipboard text box when opening the control menu.' 206 | - '2:Automatic close of the control menu when clicking into the application.' 207 | - '2:Rotation of the internal web server log files.' 208 | - version: 22.12.4 209 | date: 2022-12-23 210 | changes: 211 | - 'Updated CloudBerry Backup to version 4.0.2.402.' 212 | - 'More time is allowed to the backup service to start.' 213 | - version: 22.12.3 214 | date: 2022-12-11 215 | changes: 216 | - 'Implemented workaround for issue seen with Synology devices where container would not start after an image update. The problem is caused by Synology explicitly setting all environment variables and keeping values from the old version.' 217 | - version: 22.12.2 218 | date: 2022-12-09 219 | changes: 220 | - 'Fixed CloudBerry Backup version number stored into the image.' 221 | - version: 22.12.1 222 | date: 2022-12-09 223 | changes: 224 | - 'Updated CloudBerry Backup to version 4.0.1.310.' 225 | - 'Versioning scheme of the Docker image changed to `YY.MM.SEQUENCE`.' 226 | - 'Update of the baseimage to version 4.2.1 brings the following new features:' 227 | - '2:Support for remote window resize.' 228 | - '2:Updated the web UI with a new, simplified and less intrusive look.' 229 | - version: 1.28.0 230 | date: 2022-09-13 231 | changes: 232 | - 'Updated CloudBerry Backup to version 4.0.0.260.' 233 | - version: 1.27.1 234 | date: 2022-03-12 235 | changes: 236 | - 'Fixed issue where files whith special characters were not processed.' 237 | - version: 1.27.0 238 | date: 2022-03-06 239 | changes: 240 | - 'Updated CloudBerry Backup to version 3.3.2.22.' 241 | - version: 1.26.1 242 | date: 2022-02-03 243 | changes: 244 | - 'Fixed CloudBerry Backup Web Interface login.' 245 | - 'Updated baseimage to version 3.5.8, which brings to following changes:' 246 | - '2:Updated installed packages to get latest security fixes.' 247 | - version: 1.26.0 248 | date: 2021-12-16 249 | changes: 250 | - 'Updated CloudBerry Backup to version 3.3.0.11.' 251 | - version: 1.25.0 252 | date: 2021-11-23 253 | changes: 254 | - 'Updated CloudBerry Backup to version 3.2.3.156.' 255 | - version: 1.24.1 256 | date: 2021-01-05 257 | changes: 258 | - 'Updated CloudBerry Backup to version 3.1.3.17.' 259 | - version: 1.24.0 260 | date: 2020-10-20 261 | changes: 262 | - 'Updated CloudBerry Backup to version 3.1.0.83.' 263 | - version: 1.23.0 264 | date: 2020-07-19 265 | changes: 266 | - 'Upgraded CloudBerry Backup to version 3.0.2.122.' 267 | - 'Now using baseimage v3.5.6, which brings the following changes:' 268 | - '2:Upgraded glibc to version 2.31 on Alpine Linux images with glibc integrated.' 269 | - '2:Updated installed packages to get latest security fixes.' 270 | - '2:Adjusted the log monitor target for recent versions of YAD.' 271 | - version: 1.22.0 272 | date: 2020-05-09 273 | changes: 274 | - 'Upgraded CloudBerry Backup to version 3.0.0.100.' 275 | - 'The backup engine now runs under the configured user.' 276 | - '2:NOTE: Make sure `USER_ID` and `GROUP_ID` environment variables are properly set to allow CloudBerry Backup to access your files.' 277 | - 'Now using baseimage v3.5.3, which brings the following changes:' 278 | - '2:Updated installed packages to get latest security fixes.' 279 | - '2:Make sure the tzdata is installed.' 280 | - version: 1.21.2 281 | date: 2019-12-08 282 | changes: 283 | - 'Upgraded CloudBerry Backup to version 2.10.1.36.' 284 | - version: 1.21.1 285 | date: 2019-10-27 286 | changes: 287 | - 'Upgraded CloudBerry Backup to version 2.10.1.26.' 288 | - version: 1.21.0 289 | date: 2019-10-24 290 | changes: 291 | - 'Upgraded CloudBerry Backup to version 2.10.0.123.' 292 | - version: 1.20.3 293 | date: 2019-08-27 294 | changes: 295 | - 'Upgraded CloudBerry Backup to version 2.9.4.12.' 296 | - version: 1.20.2 297 | date: 2019-08-16 298 | changes: 299 | - 'Upgraded CloudBerry Backup to version 2.9.3.15.' 300 | - version: 1.20.1 301 | date: 2019-07-31 302 | changes: 303 | - 'Upgraded CloudBerry Backup to version 2.9.2.14.' 304 | - version: 1.20.0 305 | date: 2019-07-05 306 | changes: 307 | - 'Upgraded CloudBerry Backup to version 2.9.1.16.' 308 | - version: 1.19.0 309 | date: 2019-05-17 310 | changes: 311 | - 'Upgraded CloudBerry Backup to version 2.9.0.114.' 312 | - version: 1.18.1 313 | date: 2019-04-24 314 | changes: 315 | - 'Now using baseimage v3.5.2, which brings the following changes:' 316 | - '2:Updated installed packages to get latest security fixes.' 317 | - '2:Fixed issue where the container could have a zombie process.' 318 | - '2:Fixed issue where the password would not be submitted when pressing the enter key in the password modal.' 319 | - '2:Use relative path for favicon ressources to be more friendly with reverse proxy senarios.' 320 | - version: 1.18.0 321 | date: 2019-04-05 322 | changes: 323 | - 'Upgraded CloudBerry Backup to version 2.8.3.10.' 324 | - version: 1.17.0 325 | date: 2019-03-07 326 | changes: 327 | - 'Upgraded CloudBerry to version 2.8.1.14.' 328 | - version: 1.16.0 329 | date: 2019-02-27 330 | changes: 331 | - 'Upgraded CloudBerry Backup to version 2.8.0.35.' 332 | - 'Make sure to start the UI only when the management service is ready.' 333 | - version: 1.15.0 334 | date: 2018-10-02 335 | changes: 336 | - 'Upgraded CloudBerry Backup to version 2.6.0.31.' 337 | - version: 1.14.1 338 | date: 2018-09-18 339 | changes: 340 | - 'Now using baseimage v3.5.1, which brings the following changes:' 341 | - '2:Updated installed packages to get latest security fixes.' 342 | - version: 1.14.0 343 | date: 2018-09-06 344 | changes: 345 | - 'Upgraded CloudBerry Backup to version 2.5.1.26.' 346 | - version: 1.13.1 347 | date: 2018-08-08 348 | changes: 349 | - 'Upgraded CloudBerry Backup to version 2.5.0.39.' 350 | - version: 1.13.0 351 | date: 2018-07-17 352 | changes: 353 | - 'Upgraded CloudBerry Backup to version 2.5.0.32.' 354 | - 'Now using baseimage v3.4.0, which is based on Alpine Linux 3.8.' 355 | - version: 1.12.3 356 | date: 2018-06-08 357 | changes: 358 | - 'Upgraded CloudBerry Backup to version 2.4.3.11.' 359 | - version: 1.12.2 360 | date: 2018-05-16 361 | changes: 362 | - 'Upgraded CloudBerry Backup to version 2.4.2.4.' 363 | - version: 1.12.1 364 | date: 2018-04-07 365 | changes: 366 | - 'Upgraded CloudBerry Backup to version 2.4.1.6.' 367 | - version: 1.12.0 368 | date: 2018-03-27 369 | changes: 370 | - 'Updapted CloudBerry Backup to version 2.4.0.17.' 371 | - 'Switched to a baseimage based on Alpine Linux 3.7.' 372 | - version: 1.11.3 373 | date: 2018-03-02 374 | changes: 375 | - 'Now using baseimage v3.3.4, which brings the following changes (since last used version):' 376 | - '2:Make sure the log monitor is started after the X server.' 377 | - '2:Fixed an issue where the log monitor `yad` target would use XDG folders of the application.' 378 | - '2:Fixed issue where log monitor states were not cleared during container startup.' 379 | - version: 1.11.2 380 | date: 2018-02-03 381 | changes: 382 | - 'Now using baseimage v3.3.2, which brings the following changes:' 383 | - '2:Restored timezone support in Alpine Linux images with glibc.' 384 | - '2:Fixed issue in `add-pkg` helper where a package could be incorrectly detected as installed.' 385 | - version: 1.11.1 386 | date: 2018-01-30 387 | changes: 388 | - 'Now using baseimage v3.3.1, which brings the following changes:' 389 | - '2:Adjusted the way some ressources are accessed to better support reverse proxy to the container.' 390 | - version: 1.11.0 391 | date: 2018-01-26 392 | changes: 393 | - 'Upgraded CloudBerry Backup to version 2.3.0.12.' 394 | - version: 1.10.0 395 | date: 2018-01-22 396 | changes: 397 | - 'Now using baseimage v3.3.0, which brings the following changes (since last used version):' 398 | - '2:For Alpine Linux images with glibc, automatically update dynamic linker''s cache after new libraries are installed.' 399 | - '2:Fixed the LANG environment variable not being set properly.' 400 | - '2:Added the ability to automatically install a CJK (Chinese/Japanese/Korean) font.' 401 | - 'Upgraded CloudBerry Backup to version 2.2.1.9.' 402 | - version: 1.9.3 403 | date: 2018-01-11 404 | changes: 405 | - 'Fixed issue where libraries were not found.' 406 | - version: 1.9.2 407 | date: 2018-01-11 408 | changes: 409 | - 'Now using baseimage v3.2.2, which brings the following changes (since last used version):' 410 | - '2:Upgraded S6 overlay to version 1.21.2.2.' 411 | - '2:Upgraded glibc to version 2.26 (Alpine Linux glibc images).' 412 | - '2:Adjusted the way ownership of /config is taken to better support cases where the folder is mapped to a network share.' 413 | - 'Small adjustment to the way ownership of files are taken.' 414 | - version: 1.9.1 415 | date: 2017-12-12 416 | changes: 417 | - 'Now using baseimage v3.1.4, which brings the following changes:' 418 | - '2:Set 2 worker processes for nginx.' 419 | - version: 1.9.0 420 | date: 2017-12-04 421 | changes: 422 | - 'Upgraded CloudBerry Backup to version 2.2.0.76.' 423 | - version: 1.8.2 424 | date: 2017-11-20 425 | changes: 426 | - 'Now using baseimage v3.1.3, which brings the following changes:' 427 | - '2:Upgraded S6 overlay to version 1.21.2.1.' 428 | - version: 1.8.1 429 | date: 2017-11-07 430 | changes: 431 | - 'Now using baseimage v3.1.2, which brings the following changes (from last used version):' 432 | - '2:Fixed an issue where a self-disabled service could be restarted.' 433 | - '2:Upgraded S6 overlay to version 1.21.2.0.' 434 | - '2:Use a more efficient way to monitor status files.' 435 | - version: 1.8.0 436 | date: 2017-10-29 437 | changes: 438 | - 'Now using baseimage v3.1.0, which brings the following changes:' 439 | - '2:Upgraded S6 overlay to version 1.21.1.1.' 440 | - '2:Enhanced integration of service dependencies functionality.' 441 | - '2:Added a simple log monitor.' 442 | - '2:Fixed race condition where container''s exit code would not be the expected one.' 443 | - '2:Fixed issue where application''s GUI fails to displayed when accessing it through the web interface via standard ports 80/443.' 444 | - version: 1.7.0 445 | date: 2017-10-09 446 | changes: 447 | - 'Now using baseimage v3.0.2, which brings the following changes:' 448 | - '2:Better support for service dependencies.' 449 | - '2:Added support for secure access to the application''s GUI.' 450 | - version: 1.6.0 451 | date: 2017-09-20 452 | changes: 453 | - 'Now using baseimage v2.0.9, which brings the following changes:' 454 | - '2:Restore default `/etc/shadow` during container startup.' 455 | - 'Upgraded CloudBerry Backup to version 2.1.0.81.' 456 | - 'Added support for the new CloudBerry Backup native web interface.' 457 | - version: 1.5.8 458 | date: 2017-09-08 459 | changes: 460 | - 'Now using baseimage v2.0.8, which brings the following changes:' 461 | - '2:Fixed duplicated entries in /etc/passwd and /etc/group that were created after a restart of the container.' 462 | - 'Upgraded CloudBerry Backup to version 2.0.3.30.' 463 | - version: 1.5.7 464 | date: 2017-09-06 465 | changes: 466 | - 'Now using baseimage v2.0.7, which brings the following changes:' 467 | - '2:Fixed timezone support on alpine-glibc images.' 468 | - 'Upgraded CloudBerry Backup to version 2.0.3.26.' 469 | - 'Minor fix in displayed app title.' 470 | - version: 1.5.6 471 | date: 2017-08-28 472 | changes: 473 | - 'Upgraded CloudBerry Backup to version 2.0.3.25.' 474 | - version: 1.5.5 475 | date: 2017-08-14 476 | changes: 477 | - 'Now using baseimage v2.0.6, which brings the following changes:' 478 | - '2:Upgraded S6 overlay to version 1.20.0.0.' 479 | - version: 1.5.4 480 | date: 2017-07-31 481 | changes: 482 | - 'Now using baseimage v2.0.5, which brings the following changes (from last used version):' 483 | - '2:Clear the environment of the container during startup.' 484 | - '2:Clear the /tmp folder during startup.' 485 | - '2:Cleanly terminate the X server when container is restarted/stopped.' 486 | - '2:Improved robustness of X server starting process.' 487 | - '2:Removed unneeded files from the image.' 488 | - version: 1.5.3 489 | date: 2017-07-27 490 | changes: 491 | - 'Now using baseimage v2.0.3, which brings the following changes:' 492 | - '2:Improved robustness of the X server starting process.' 493 | - version: 1.5.2 494 | date: 2017-07-23 495 | changes: 496 | - 'Now using baseimage v2.0.2, which brings the following changes:' 497 | - '2:Proper VNC port is exposed.' 498 | - version: 1.5.1 499 | date: 2017-07-18 500 | changes: 501 | - 'Now using baseimage v2.0.1, which brings the following changes:' 502 | - '2:Internal enhancements.' 503 | - '2:Clean temporary files left by npm.' 504 | - version: 1.5.0 505 | date: 2017-07-17 506 | changes: 507 | - 'Now using baseimage v2.0.0, which brings the following changes:' 508 | - '2:Various internal enhancements.' 509 | - '2:Fixed the way a service waits for another one.' 510 | - version: 1.4.0 511 | date: 2017-07-04 512 | changes: 513 | - 'Now using baseimage v1.5.0, which brings the following changes:' 514 | - '2:Added the UMASK environment variable to control how file permissions are set for newly created files.' 515 | - '2:Added the X11VNC_EXTRA_OPTS environment variable used to pass additional arguments to the x11vnc server.' 516 | - '2:By default, activate auto-scaling of application''s window.' 517 | - '2:Applied latest Alpine Linux security updates.' 518 | - version: 1.3.1 519 | date: 2017-06-22 520 | changes: 521 | - 'Now using baseimage v1.4.3, which brings the following changes:' 522 | - '2:Updated Alpine Linux to version 3.6.2.' 523 | - version: 1.3.0 524 | date: 2017-06-22 525 | changes: 526 | - 'Switched to Alpine Linux 3.6 baseimage.' 527 | - version: 1.2.0 528 | date: 2017-06-21 529 | changes: 530 | - 'Upgraded CloudBerry Backup to version 2.0.2.39.' 531 | - 'Now using baseimage v1.4.2, which brings the following changes (from last used version):' 532 | - '2:Associate the application''s icon to a unique version to avoid browser cache issues.' 533 | - '2:Fixed prefix of some service related messages.' 534 | - '2:Added support for supplying supplementary groups of the application.' 535 | - '2:Improved process startup and shutdown.' 536 | - '2:When container is stopped or restarted, processes are now terminated gracefully and in proper order. This allow the GUI application to execute its termination routine.' 537 | - '2:No more error messages when container is stopped or restarted.' 538 | - version: 1.1.2 539 | date: 2017-05-30 540 | changes: 541 | - 'Now using baseimage v1.3.2, which brings the following changes:' 542 | - '2:Fixed password modal window not showing up when required.' 543 | - version: 1.1.1 544 | date: 2017-05-17 545 | changes: 546 | - 'Now using baseimage v1.3.1, which brings the following changes:' 547 | - '2:Better font is used.' 548 | - version: 1.1.0 549 | date: 2017-05-15 550 | changes: 551 | - 'Now using baseimage v1.3.0, which brings the following changes:' 552 | - '2:Added support for application''s niceness configuration.' 553 | - version: 1.0.3 554 | date: 2017-05-12 555 | changes: 556 | - 'Now using baseimage v1.2.3, which brings the following changes:' 557 | - '2:Adjusted the default display width to 1280 pixels, as documented.' 558 | - version: 1.0.2 559 | date: 2017-05-11 560 | changes: 561 | - 'Now using baseimage v1.2.2, which brings the following changes:' 562 | - '2:Fixed issue with the web UI, where the remote application''s window was not taking the available height after activating/deactivating the hideable navigation bar.' 563 | - version: 1.0.1 564 | date: 2017-05-10 565 | changes: 566 | - 'Now using baseimage v1.2.1, which brings the following changes:' 567 | - '2:Fixed issue where clipboard content was lost on modal window closure.' 568 | - version: 1.0.0 569 | date: 2017-05-09 570 | changes: 571 | - 'Initial release.' 572 | 573 | container: 574 | storage_permissions: ro 575 | 576 | # Environment variables. 577 | environment_variables: 578 | - name: CBB_WEB_INTERFACE_USER 579 | description: >- 580 | Username to use to login to the CloudBerry Backup's web interface. 581 | type: public 582 | unraid_template: 583 | title: CloudBerry Backup Web Interface User 584 | description: >- 585 | User name to use to login to the CloudBerry Backup's web interface. 586 | display: advanced 587 | required: false 588 | mask: false 589 | - name: CBB_WEB_INTERFACE_PASSWORD 590 | description: >- 591 | Password to use to login to the CloudBerry Backup's web interface. 592 | type: public 593 | unraid_template: 594 | title: CloudBerry Backup Web Interface Password 595 | description: >- 596 | Password to use to login to the CloudBerry Backup's web interface. 597 | **Warning**: See documentation for a more secure way to specify the password. 598 | display: advanced 599 | required: false 600 | mask: true 601 | 602 | # Volumes 603 | volumes: [] 604 | 605 | # Network ports 606 | ports: 607 | - number: 43210 608 | protocol: tcp 609 | description: >- 610 | Port used to access the CloudBerry Backup's web interface via HTTP. 611 | mandatory: false 612 | unraid_template: 613 | title: CloudBerry Backup Web Interface HTTP Port 614 | default: 43210 615 | display: advanced 616 | required: false 617 | mask: false 618 | - number: 43211 619 | protocol: tcp 620 | description: >- 621 | Port used to access the CloudBerry Backup's web interface via HTTPs. 622 | mandatory: false 623 | unraid_template: 624 | title: CloudBerry Backup Web Interface HTTPs Port 625 | default: 43211 626 | display: advanced 627 | required: false 628 | mask: false 629 | 630 | # Devices 631 | devices: [] 632 | -------------------------------------------------------------------------------- /rootfs/etc/cont-init.d/55-cloudberrybackup.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 | log() { 7 | echo "$*" 8 | } 9 | 10 | OWNER_ID="00000000-0000-0000-0000-000000000000" 11 | 12 | # Make sure default directories exist. 13 | mkdir -p /config/etc 14 | mkdir -p /config/"Online Backup" 15 | 16 | # Generate machine id 17 | if [ ! -f /config/machine-id ]; then 18 | log "generating machine-id..." 19 | cat /proc/sys/kernel/random/uuid | tr -d '-' > /config/machine-id 20 | fi 21 | 22 | # Handle initial start and upgrade scenarios. 23 | NEW_VERSION="$(cat /defaults/"Online Backup"/"$OWNER_ID"/config/cloudBackup.conf | grep -w buildVersion | cut -d ':' -f2 | tr -d ' ')" 24 | if [ ! -d /opt/local/"Online Backup"/"$OWNER_ID" ] 25 | then 26 | # No existing config found. 27 | 28 | if [ -f /opt/local/"MSP360 Backup"/etc/config/cloudBackup.conf ]; then 29 | # We are upgrading from an old version. 30 | CUR_VERSION="$(cat /opt/local/"MSP360 Backup"/etc/config/cloudBackup.conf | grep -w buildVersion | cut -d ':' -f2 | tr -d ' ')" 31 | log "Upgrading CloudBerry Backup configuration from version $CUR_VERSION to $NEW_VERSION..." 32 | cp -pr /defaults/"Online Backup"/* /config/"Online Backup"/ 33 | su-exec "$USER_ID:$GROUP_ID" touch /tmp/.upgrade_performed 34 | else 35 | # We are starting for the first time. 36 | log "CloudBerry Backup config not found, copying default one..." 37 | cp -pr /defaults/"Online Backup"/* /config/"Online Backup"/ 38 | fi 39 | 40 | # Location of HID changed. Make sure to move it. 41 | if [ -f /config/HID ]; then 42 | # During upgrade, CBB expects the HID to be at the old location and 43 | # it must be able to move the file to the new location. 44 | mv /config/HID /opt/local/"MSP360 Backup"/share/ 45 | chmod a+w /opt/local/"MSP360 Backup"/share 46 | fi 47 | 48 | /opt/local/"MSP360 Backup"/bin/cbbUpdater 49 | else 50 | # Existing config found. Check if CloudBerry Backup version changed. 51 | CUR_VERSION="$(cat /opt/local/"Online Backup"/"$OWNER_ID"/config/cloudBackup.conf | grep -w buildVersion | cut -d ':' -f2 | tr -d ' ')" 52 | if [ "$CUR_VERSION" != "$NEW_VERSION" ]; then 53 | log "Upgrading CloudBerry Backup configuration from version $CUR_VERSION to $NEW_VERSION..." 54 | su-exec "$USER_ID:$GROUP_ID" touch /tmp/.upgrade_performed 55 | 56 | # Some files are replaced during normal upgrade. These are the ones 57 | # under /opt/local/MSP360 Backup/etc/config/ from the .deb package. 58 | for FILE in cloudBackup.conf wt_config.xml 59 | do 60 | cp /defaults/"Online Backup"/"$OWNER_ID"/config/$FILE /opt/local/"Online Backup"/"$OWNER_ID"/config/ 61 | done 62 | 63 | /opt/local/"MSP360 Backup"/bin/cbbUpdater 64 | fi 65 | fi 66 | 67 | # Convert CloudBerry web interface's clear-text password to password hash. 68 | if [ -f /config/.cbb_web_interface_clear_text_pass ]; then 69 | cat /config/.cbb_web_interface_clear_text_pass | mkpasswd -m sha-512 -P 0 > /config/.cbb_web_interface_pass_hash 70 | rm /config/.cbb_web_interface_clear_text_pass 71 | log "Converted CloudBerry web interface's clear-text password to password hash." 72 | fi 73 | 74 | # Handle password for CloudBerry web interface. 75 | if [ "${CBB_WEB_INTERFACE_USER:-UNSET}" = "UNSET" ]; then 76 | log "CloudBerry Backup web interface disabled: No user name defined." 77 | elif id "$CBB_WEB_INTERFACE_USER" >/dev/null 2>&1; then 78 | log "CloudBerry Backup web interface disabled: User name '$CBB_WEB_INTERFACE_USER' is reserved." 79 | else 80 | if [ -f /config/.cbb_web_interface_pass_hash ]; then 81 | PASS="$(cat /config/.cbb_web_interface_pass_hash)" 82 | elif [ "${CBB_WEB_INTERFACE_PASSWORD:-UNSET}" != "UNSET" ]; then 83 | PASS="$(echo "$CBB_WEB_INTERFACE_PASSWORD" | mkpasswd -m sha-512 -P 0)" 84 | else 85 | PASS=UNSET 86 | fi 87 | 88 | # Create a Linux user matching credentials. 89 | if [ "$PASS" != "UNSET" ]; then 90 | useradd --system \ 91 | --no-create-home \ 92 | --no-user-group \ 93 | --shell /sbin/nologin \ 94 | --home-dir /dev/null \ 95 | --password "$PASS" \ 96 | $CBB_WEB_INTERFACE_USER 97 | su-exec "$USER_ID:$GROUP_ID" touch /tmp/.cbb_web_interface_enabled 98 | else 99 | log "CloudBerry Backup web interface disabled: No password defined." 100 | fi 101 | fi 102 | 103 | # vim: set ft=sh : 104 | -------------------------------------------------------------------------------- /rootfs/etc/machine-id: -------------------------------------------------------------------------------- 1 | /config/machine-id -------------------------------------------------------------------------------- /rootfs/etc/services.d/app/cbbLocalManagement.dep: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jlesage/docker-cloudberry-backup/34e8b0865dd7851319c0291b40dc339b79fbbb8f/rootfs/etc/services.d/app/cbbLocalManagement.dep -------------------------------------------------------------------------------- /rootfs/etc/services.d/cbbLocalManagement/is_ready: -------------------------------------------------------------------------------- 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 | [ -e /tmp/"MSP360 Backup"/CBB_COMMAND.sock ] 7 | [ -e /tmp/"MSP360 Backup"/CBB_CONFIG.sock ] 8 | [ -e /tmp/"MSP360 Backup"/CBB_NOTIFICATION.sock ] 9 | [ -e /tmp/"MSP360 Backup"/CBB_REBRANDING.sock ] 10 | [ -e /tmp/"MSP360 Backup"/CBB_REPLY_*.sock ] 11 | 12 | # vim:ts=4:sw=4:et:sts=4 13 | -------------------------------------------------------------------------------- /rootfs/etc/services.d/cbbLocalManagement/priority: -------------------------------------------------------------------------------- 1 | /defaults/service/priority -------------------------------------------------------------------------------- /rootfs/etc/services.d/cbbLocalManagement/ready_timeout: -------------------------------------------------------------------------------- 1 | 30000 2 | -------------------------------------------------------------------------------- /rootfs/etc/services.d/cbbLocalManagement/respawn: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jlesage/docker-cloudberry-backup/34e8b0865dd7851319c0291b40dc339b79fbbb8f/rootfs/etc/services.d/cbbLocalManagement/respawn -------------------------------------------------------------------------------- /rootfs/etc/services.d/cbbLocalManagement/run: -------------------------------------------------------------------------------- 1 | /opt/local/MSP360 Backup/bin/cbbLocalManagement -------------------------------------------------------------------------------- /rootfs/etc/services.d/cbbLocalManagement/sgid: -------------------------------------------------------------------------------- 1 | ../app/sgid -------------------------------------------------------------------------------- /rootfs/etc/services.d/cbbWebAccess/cbbLocalManagement.dep: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jlesage/docker-cloudberry-backup/34e8b0865dd7851319c0291b40dc339b79fbbb8f/rootfs/etc/services.d/cbbWebAccess/cbbLocalManagement.dep -------------------------------------------------------------------------------- /rootfs/etc/services.d/cbbWebAccess/disabled: -------------------------------------------------------------------------------- 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 | if [ -f /tmp/.cbb_web_interface_enabled ]; then 7 | echo "false" 8 | else 9 | echo "true" 10 | fi 11 | 12 | # vim:ft=sh:ts=4:sw=4:et:sts=4 13 | -------------------------------------------------------------------------------- /rootfs/etc/services.d/cbbWebAccess/priority: -------------------------------------------------------------------------------- 1 | /defaults/service/priority -------------------------------------------------------------------------------- /rootfs/etc/services.d/cbbWebAccess/respawn: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jlesage/docker-cloudberry-backup/34e8b0865dd7851319c0291b40dc339b79fbbb8f/rootfs/etc/services.d/cbbWebAccess/respawn -------------------------------------------------------------------------------- /rootfs/etc/services.d/cbbWebAccess/run: -------------------------------------------------------------------------------- 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 | exec 2>&1 /opt/local/"MSP360 Backup"/bin/cbbWebAccess >> /config/"Online Backup"/00000000-0000-0000-0000-000000000000/logs/log_WebAccess_output.log 7 | 8 | # vim: set ft=sh : 9 | -------------------------------------------------------------------------------- /rootfs/etc/services.d/cbbWebAccess/sgid: -------------------------------------------------------------------------------- 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 | SHADOW_GRP_ID="$(getent group shadow | cut -d':' -f3)" 7 | if [ -n "${SUP_GROUP_IDS:-}" ]; then 8 | SUP_GROUP_IDS="$SUP_GROUP_IDS,$SHADOW_GRP_ID" 9 | else 10 | SUP_GROUP_IDS="$SHADOW_GRP_ID" 11 | fi 12 | 13 | echo "$SUP_GROUP_IDS" | tr ',' '\n' 14 | 15 | # vim:ts=4:sw=4:et:sts=4 16 | -------------------------------------------------------------------------------- /rootfs/etc/services.d/default/cbbWebAccess.dep: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jlesage/docker-cloudberry-backup/34e8b0865dd7851319c0291b40dc339b79fbbb8f/rootfs/etc/services.d/default/cbbWebAccess.dep -------------------------------------------------------------------------------- /rootfs/startapp.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 | #export QT_DEBUG_PLUGINS=1 7 | 8 | PIDS= 9 | 10 | notify() { 11 | for N in $(ls /etc/logmonitor/targets.d/*/send) 12 | do 13 | timeout 1800 "$N" "$1" "$2" "$3" & 14 | PIDS="$PIDS $!" 15 | done 16 | } 17 | 18 | # Verify if CloudBerry Backup has been upgraded. 19 | if [ -f /tmp/.upgrade_performed ]; then 20 | notify "$APP_NAME upgraded." "$APP_NAME has been upgraded. The upgrade can take several minutes to complete. During this time, the UI might only show a black screen." "INFO" 21 | rm /tmp/.upgrade_performed 22 | fi 23 | 24 | # Wait for all PIDs to terminate. 25 | set +e 26 | for PID in "$PIDS"; do 27 | wait $PID 28 | done 29 | set -e 30 | 31 | cd /config 32 | exec /opt/local/"MSP360 Backup"/bin/cbbGUI 33 | 34 | # vim:ft=sh:ts=4:sw=4:et:sts=4 35 | -------------------------------------------------------------------------------- /rootfs/usr/share/applications/msp360-backup.desktop: -------------------------------------------------------------------------------- 1 | [Desktop Entry] 2 | Type=Application 3 | Name=CloudBerry Backup 4 | Exec="/opt/local/CloudBerry Backup/bin/cbbgui" 5 | Icon=/opt/local/CloudBerry Backup/share/images/MainIcon.ico 6 | Categories=Network;Database;Office; 7 | -------------------------------------------------------------------------------- /src/cloudberry-backup/build.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | set -e 4 | set -o pipefail 5 | 6 | export DEBIAN_FRONTEND=noninteractive 7 | 8 | function log { 9 | echo ">>> $*" 10 | } 11 | 12 | if [ -z "${1:-}" ]; then 13 | echo "ERROR: CloudBerry Backup URL not provided." 14 | exit 1 15 | fi 16 | 17 | CLOUDBERRYBACKUP_URL="$1" 18 | 19 | log "Updating APT cache..." 20 | apt update 21 | 22 | log "Installing build prerequisites..." 23 | apt upgrade -y 24 | apt install -y --no-install-recommends \ 25 | locales \ 26 | wget \ 27 | ca-certificates \ 28 | patchelf \ 29 | libgl1 \ 30 | libxrender1 \ 31 | libxcursor1 \ 32 | libdbus-1-3 \ 33 | 34 | # Generate locale. 35 | locale-gen en_US.UTF-8 36 | 37 | # Download CloudBerry Backup. 38 | log "Downloading CloudBerry Backup..." 39 | wget "$CLOUDBERRYBACKUP_URL" -O /tmp/cbb.deb 40 | 41 | # Install CloudBerry Backup. 42 | log "Installing CloudBerry Backup..." 43 | dpkg --force-all --install /tmp/cbb.deb 44 | 45 | service msp360-backup stop 46 | service msp360-backupWA stop 47 | 48 | rm /opt/local/"Online Backup"/00000000-0000-0000-0000-000000000000/logs/* 49 | rm /opt/local/"Online Backup"/00000000-0000-0000-0000-000000000000/config/HID 50 | 51 | # Replace libudev.so.0 packaged with CloudBerry Backup, which causes an error 52 | # when loading the QT xcb plugin. 53 | rm /opt/local/"MSP360 Backup"/lib/libudev.so.0 54 | cp $(find /lib/x86_64-linux-gnu/ -type f -name "libudev.so*") /opt/local/"MSP360 Backup"/lib/libudev.so.0 55 | 56 | # Modify installed scripts to use sh instead of bash. 57 | find /opt/local/"MSP360 Backup"/bin/ -type f -exec sed 's/^#!\/bin\/bash/#!\/bin\/sh/' -i {} ';' 58 | 59 | # Extra libraries that need to be installed into the CloudBerry Backup lib 60 | # folder. These libraries are loaded dynamically (dlopen) and are not catched 61 | # by tracking dependencies. 62 | EXTRA_LIBS=" 63 | /lib/x86_64-linux-gnu/libnss_dns 64 | /lib/x86_64-linux-gnu/libnss_files 65 | /lib/x86_64-linux-gnu/libdbus-1.so.3 66 | /usr/lib/x86_64-linux-gnu/libXfixes.so.3 67 | /usr/lib/x86_64-linux-gnu/libXrender.so.1 68 | /usr/lib/x86_64-linux-gnu/libXcursor.so.1 69 | " 70 | 71 | log "Copying extra libraries..." 72 | for LIB in $EXTRA_LIBS 73 | do 74 | cp -av "$LIB"* /opt/local/"MSP360 Backup"/lib/ 75 | done 76 | 77 | # Extract dependencies of all binaries and libraries. 78 | log "Extracting shared library dependencies..." 79 | find /opt/local/"MSP360 Backup"/raw_bin /opt/local/"MSP360 Backup"/lib -type f -executable -or -name 'lib*.so*' -or -name '*.so' | while read BIN 80 | do 81 | RAW_DEPS="$(LD_LIBRARY_PATH="/opt/local/MSP360 Backup/lib" ldd "$BIN")" 82 | echo "Dependencies for $BIN:" 83 | echo "================================" 84 | echo "$RAW_DEPS" 85 | echo "================================" 86 | 87 | if echo "$RAW_DEPS" | grep -q " not found"; then 88 | echo "ERROR: Some libraries are missing!" 89 | exit 1 90 | fi 91 | 92 | LD_LIBRARY_PATH="/opt/local/MSP360 Backup/lib" ldd "$BIN" | (grep " => " || true) | cut -d'>' -f2 | sed 's/^[[:space:]]*//' | cut -d'(' -f1 | while read dep 93 | do 94 | dep_real="$(realpath "$dep")" 95 | dep_basename="$(basename "$dep_real")" 96 | 97 | # Skip already-processed libraries. 98 | [ ! -f "/opt/local/MSP360 Backup/lib/$dep_basename" ] || continue 99 | 100 | echo " -> Found library: $dep" 101 | cp "$dep_real" "/opt/local/MSP360 Backup/lib/" 102 | while true; do 103 | [ -L "$dep" ] || break; 104 | ln -sf "$dep_basename" "/opt/local/MSP360 Backup"/lib/$(basename $dep) 105 | dep="$(readlink -f "$dep")" 106 | done 107 | done 108 | done 109 | 110 | log "Patching ELF of binaries..." 111 | find "/opt/local/MSP360 Backup/raw_bin" -type f -executable -exec echo " -> Setting interpreter of {}..." ';' -exec patchelf --set-interpreter "/opt/local/MSP360 Backup/lib/ld-linux-x86-64.so.2" {} ';' 112 | find "/opt/local/MSP360 Backup/raw_bin" -type f -executable -exec echo " -> Setting rpath of {}..." ';' -exec patchelf --set-rpath '$ORIGIN/../lib' {} ';' 113 | 114 | log "Patching ELF of libraries..." 115 | find "/opt/local/MSP360 Backup/lib" -type f -name "lib*" -exec echo " -> Setting rpath of {}..." ';' -exec patchelf --set-rpath '$ORIGIN' {} ';' 116 | 117 | log "Copying interpreter..." 118 | cp -av /lib/x86_64-linux-gnu/ld-* "/opt/local/MSP360 Backup/lib/" 119 | 120 | log "CloudBerry backup build successfully." 121 | --------------------------------------------------------------------------------