Initial structure, tooling, README and LICENSE
This commit is contained in:
commit
d2f70d85b4
5 changed files with 61 additions and 0 deletions
15
LICENSE
Normal file
15
LICENSE
Normal file
|
@ -0,0 +1,15 @@
|
||||||
|
Recycled Cloud CDIST types
|
||||||
|
Copyright (C) 2020 Timothée Floure / e-Durable SA
|
||||||
|
|
||||||
|
This program is free software: you can redistribute it and/or modify
|
||||||
|
it under the terms of the GNU General Public License as published by
|
||||||
|
the Free Software Foundation, either version 3 of the License, or
|
||||||
|
(at your option) any later version.
|
||||||
|
|
||||||
|
This program is distributed in the hope that it will be useful,
|
||||||
|
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
GNU General Public License for more details.
|
||||||
|
|
||||||
|
You should have received a copy of the GNU General Public License
|
||||||
|
along with this program. If not, see <https://www.gnu.org/licenses/>.
|
10
README.md
Normal file
10
README.md
Normal file
|
@ -0,0 +1,10 @@
|
||||||
|
# Recycled Cloud CDIST types
|
||||||
|
|
||||||
|
The repository contains [cdist](https://www.cdi.st/) types used to define the
|
||||||
|
recycled cloud infrastructure. They usually are called from the
|
||||||
|
[cdist-workdir](https://code.recycled.cloud/e-Durable/cdist-workdir)
|
||||||
|
repository. You can refer to the [Recycled Cloud
|
||||||
|
documentation](https://wiki.recycled.cloud/en/recycled_cloud/home) for details.
|
||||||
|
|
||||||
|
Unless specified otherwise, the content of this repository is licensed under
|
||||||
|
the GPLv3.
|
15
scripts/run-manpage-checks.sh
Executable file
15
scripts/run-manpage-checks.sh
Executable file
|
@ -0,0 +1,15 @@
|
||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
# Move to top-level cdist-contrib directory.
|
||||||
|
cd $(dirname $0)/..
|
||||||
|
|
||||||
|
# Check that each type has a man page.
|
||||||
|
status=0
|
||||||
|
for t in type/*; do
|
||||||
|
if [ ! -f "$t/man.rst" ]; then
|
||||||
|
echo "No manpage for type $t!"
|
||||||
|
status=1
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
|
||||||
|
exit $status
|
21
scripts/run-shellcheck.sh
Executable file
21
scripts/run-shellcheck.sh
Executable file
|
@ -0,0 +1,21 @@
|
||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
SHELLCHECKCMD="shellcheck -s sh -f gcc -x"
|
||||||
|
# Skip SC2154 for variables starting with __ since such variables are cdist
|
||||||
|
# environment variables.
|
||||||
|
SHELLCHECK_SKIP=': __.*is referenced but not assigned.*\[SC2154\]'
|
||||||
|
SHELLCHECKTMP=".shellcheck.tmp"
|
||||||
|
|
||||||
|
# Move to top-level cdist-contrib directory.
|
||||||
|
cd $(dirname $0)/..
|
||||||
|
|
||||||
|
check () {
|
||||||
|
find type/ -type f $1 $2 -exec ${SHELLCHECKCMD} {} + | grep -v "${SHELLCHECK_SKIP}" > "${SHELLCHECKTMP}"
|
||||||
|
test ! -s "${SHELLCHECKTMP}" || { cat "${SHELLCHECKTMP}"; exit 1; }
|
||||||
|
}
|
||||||
|
|
||||||
|
check -path "*/explorer/*"
|
||||||
|
check -path "*/files/*.sh"
|
||||||
|
check -name manifest
|
||||||
|
check -name gencode-local
|
||||||
|
check -name gencode-remote
|
0
type/.keep
Normal file
0
type/.keep
Normal file
Reference in a new issue