nextcloud/.devcontainer/postStart.sh
Robin Windey 88fde78a79
feat: Update Nextcloud Devcontainer
Removed deprecations:
* docker-compose version
* apt-key add command in docker installation

Updates:
* Upgrade from PHP8.3 to PHP8.4 (currently recommended for NC) from ppa:ondrej/php
* Use nodejs 22 by default

Optimization:
* Just install docker-ce-cli, not the full docker suite (speeds up docker build)
* Make sure user "devcontainer" has UID 1000. This increases the containers filesystem compatibility to most (unix-based) host systems because the default user there always has 1000 as well
* Ensure devcontainer user has access to docker without sudo

Signed-off-by: Robin Windey <ro.windey@gmail.com>
2025-10-07 04:38:33 +00:00

13 lines
414 B
Bash
Executable file

#!/bin/bash
#
# SPDX-FileCopyrightText: 2023 Nextcloud GmbH and Nextcloud contributors
# SPDX-License-Identifier: AGPL-3.0-or-later
#
# Set git safe.directory
git config --global --add safe.directory /var/www/html
git config --global --add safe.directory /var/www/html/3rdparty
# Ensure devcontainer user has access to docker socket
if [ -S /var/run/docker.sock ]; then
sudo chmod 666 /var/run/docker.sock
fi