mirror of
https://github.com/nextcloud/server.git
synced 2025-01-30 22:37:01 +00:00
9dd158b70d
* postCreateCommand is executed too early * If git config commands run in postCreate, a global .gitconfig will be created * Copy of local .gitconfig will be skipped if .gitconfig already exists in container * Move to later stage * https://github.com/devcontainers/cli/issues/98 * https://github.com/microsoft/vscode-remote-release/issues/4855#issuecomment-831920085 Signed-off-by: GitHub <noreply@github.com>
29 lines
835 B
Bash
Executable file
29 lines
835 B
Bash
Executable file
#!/bin/bash
|
|
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )/../" >/dev/null 2>&1 && pwd )"
|
|
|
|
cd $DIR/
|
|
|
|
git submodule update --init
|
|
|
|
# Codespace config
|
|
cp .devcontainer/codespace.config.php config/codespace.config.php
|
|
|
|
# VSCode debugger profile
|
|
mkdir -p .vscode && cp .devcontainer/launch.json .vscode/launch.json
|
|
|
|
# Onetime installation setup
|
|
if [[ ! $(sudo -u ${APACHE_RUN_USER} php occ status) =~ installed:[[:space:]]*true ]]; then
|
|
echo "Running NC installation"
|
|
sudo -u ${APACHE_RUN_USER} php occ maintenance:install \
|
|
--verbose \
|
|
--database=pgsql \
|
|
--database-name=postgres \
|
|
--database-host=127.0.0.1 \
|
|
--database-port=5432 \
|
|
--database-user=postgres \
|
|
--database-pass=postgres \
|
|
--admin-user admin \
|
|
--admin-pass admin
|
|
fi
|
|
|
|
sudo service apache2 restart
|