-
-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
validate Nextcloud config after modifying
If the insertafter regex fails, the line is written at EOF. This was breaking the Nextcloud config. See: https://docs.ansible.com/ansible/latest/collections/ansible/builtin/lineinfile_module.html datadirectory was absent because I hadn't yet walked through the Nextcloud web-based setup wizard.
- Loading branch information
Showing
2 changed files
with
22 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
#!/bin/bash | ||
|
||
set -o errexit | ||
set -o nounset | ||
set -o pipefail | ||
set -o xtrace | ||
|
||
# Ansible discards stdout. Write to stderr so Ansible outputs something useful when this script exits nonzero (e.g. why PHP linting failed). | ||
docker run --rm --interactive php:8.2-apache-bookworm php -l < "$1" | tr '\n' '|' > /dev/stderr |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters