nextcloud / nextcloud/app_api

Ability to override the default persistent volume mount

Open
#668 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement priority: low
Dominant language
PHP
Stars
196
Forks
26
Avg merge
4d 15h
Merged PRs (30d)
31

Description

Describe why it is important and where it will be useful

Most if not all apps put their persistent data in this volume so it would be nice to override it so the local data can be used/the data can be kept even after the ex-app is removed completely (with data).

Describe your proposed solution

Check for the mount mapping in the docker container, if it tries to bind the exact same path as the persistent volume, do not try to mount the persistent volume and use this one.
A sample ex-app register command to mount a volume:

occ app_api:app:register APP_ID harp_proxy_docker --wait-finish --mount /path/in/local/storage/persistent_storage_my_app:/nc_app_APP_ID_data
Describe alternatives you've considered, if relevant

No response

Additional context

No response

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the occ app_api:app:register entry point and trace how the --mount option and persistent volume are mapped into the Docker container. Reproduce the sample registration with a mount targeting /nc_app_APP_ID_data, then verify that the explicit mount replaces the persistent volume and that the data remains after the app is removed.

Written by the indexing model from the issue text.

Assessment

Tech stack
docker, php
Domain
infrastructure
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.