Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,11 @@

All notable changes to this project will be documented in this file.

## Unreleased
### Fixed
* fix(docker): create `apps-writable` as root so bind mounted apps can be used
* fix(docker): list the apps only after `apps-writable` is a known apps path

## v0.5.0 - 2026-07-02
### Breaking changes
`runExec` and `runOcc` now return an object instead of the plain output string.
Expand Down
14 changes: 8 additions & 6 deletions lib/docker.ts
Original file line number Diff line number Diff line change
Expand Up @@ -262,13 +262,11 @@ export async function configureNextcloud(apps = ['viewer'], vendoredBranch?: str
}
console.log('│ └─ OK !')

// Build app list
const { stdout: json } = await runOcc(['app:list', '--output', 'json'], { container })
const applist = JSON.parse(json)

console.log('├─ Using "apps-writable" folder for mounted apps')
await runExec(['mkdir', '-p', '/var/www/html/apps-writable'], { container })
await runExec(['chown', 'www-data:www-data', '/var/www/html/apps-writable'], { container })
// Bind mounting an app makes Docker pre-create the directory owned by root,
// so both commands have to run as root to be able to hand it over to `www-data`
await runExec(['mkdir', '-p', '/var/www/html/apps-writable'], { container, user: 'root' })
await runExec(['chown', 'www-data:www-data', '/var/www/html/apps-writable'], { container, user: 'root' })
const appsConfig = `<?php
$CONFIG = [
'apps_paths' => [
Expand All @@ -289,6 +287,10 @@ export async function configureNextcloud(apps = ['viewer'], vendoredBranch?: str
stream.finalize()
await container.putArchive(stream, { path: '/var/www/html/config' })

// Build app list, only now that "apps-writable" is a known apps path so that mounted apps show up
const { stdout: json } = await runOcc(['app:list', '--output', 'json'], { container })
const applist = JSON.parse(json)

// Enable apps and give status
for (const app of apps) {
if (app in applist.enabled) {
Expand Down