Skip to content

fix: [BUG] Devcontainer does not produce a working environment on a clean set... - #8001

Merged
vitormattos merged 2 commits into
LibreSign:mainfrom
Roshan931:prilog/fix-error-devcontainer-defaults-to-php-8-2-and-08-21-2026-3d1636
Aug 22, 2026
Merged

fix: [BUG] Devcontainer does not produce a working environment on a clean set...#8001
vitormattos merged 2 commits into
LibreSign:mainfrom
Roshan931:prilog/fix-error-devcontainer-defaults-to-php-8-2-and-08-21-2026-3d1636

Conversation

@Roshan931

Copy link
Copy Markdown
Contributor

Fixes #7985

Root cause

Devcontainer defaults to PHP 8.2 and setup.sh swallows step failures

Changes

  • Default the devcontainer image to PHP 8.3 (matching composer.json platform 8.3, psalm phpVersion 8.3 and the Nextcloud 35 requirement), and make setup.sh strict (set -Eeo pipefail plus an ERR trap) so any failing step reports the exact file/line/command and exits non-zero instead of falsely printing success.

@vitormattos vitormattos left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for working on this!

Changing PHP 8.2 to 8.3 fixes the current problem with Nextcloud master.

As a follow-up, we can create an issue in nextcloud-docker-development to review the image/tag naming so Dependabot can help keep the devcontainer PHP version updated in the future.

About setup.sh, I'm not sure we should make every setup error fatal because is a development environment, the developer may need the container running to investigate and fix the problem.

I would prefer to keep the setup.sh behavior unchanged in this PR and handle error reporting separately if needed.

@github-project-automation github-project-automation Bot moved this from 0. Backlog to 1. to do in Roadmap Aug 21, 2026
@Roshan931

Copy link
Copy Markdown
Contributor Author

Reverted the setup.sh changes so the PR only bumps the devcontainer default PHP image to 83, and checked the restored script with bash -n.

@vitormattos
vitormattos merged commit ab721ae into LibreSign:main Aug 22, 2026
63 of 64 checks passed
@github-project-automation github-project-automation Bot moved this from 1. to do to 4. to release in Roadmap Aug 22, 2026
maia-andre added a commit to maia-andre/libresign that referenced this pull request Aug 23, 2026
Reference the new ghcr.io/librecodecoop/nextcloud-dev:8.3 image
(published by LibreCodeCoop/nextcloud-docker-development#124) with a
literal tag instead of interpolating PHP_VERSION into the image name,
and add a docker ecosystem entry for /.devcontainer to dependabot.yml.

Dependabot only updates version-like tags, never image names, and
cannot parse interpolated references — so with the old scheme the
devcontainer PHP version could only be bumped by hand (as in LibreSign#8001).
Now Dependabot opens the bump PR when a new PHP version image is
published.

To run the devcontainer with a different PHP version, edit the image
tag locally.

Ref LibreCodeCoop/nextcloud-docker-development#123

Assisted-by: Claude Code:claude-fable-5
Signed-off-by: André Maia <andrefnkmm@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: 4. to release

Development

Successfully merging this pull request may close these issues.

[BUG] Devcontainer does not produce a working environment on a clean setup.

2 participants