feat: add occ alias

This commit is contained in:
2026-06-25 18:43:34 +02:00
parent c0920dd46f
commit 55122123c2

View File

@@ -28,8 +28,9 @@ set -xe
# Create nextcloud user # Create nextcloud user
if ! id nextcloud >/dev/null 2>&1; then if ! id nextcloud >/dev/null 2>&1; then
useradd --base-dir %{_sharedstatedir} --create-home --shell $SHELL --system nextcloud useradd --base-dir %{_sharedstatedir} --create-home --shell $SHELL --system nextcloud
runuser --user=nextcloud -- mkdir --parents %{_sharedstatedir}/nextcloud/data
runuser --user=nextcloud -- printf 'alias occ="php /var/www/nextcloud/occ"\n' > %{_sharedstatedir}/nextcloud/.bash_profile
fi fi
runuser --user=nextcloud -- mkdir --parents %{_sharedstatedir}/nextcloud/data
# Create config file # Create config file
if ! -f %{_sysconfdir}/nextcloud/config.php; then if ! -f %{_sysconfdir}/nextcloud/config.php; then