Public Access
fix(ci): initialize missing_required before source dir check, handle empty SOURCE_DIR
Universal: Cascade Main → Dev / Cascade main → branches (push) Failing after 2s
Platform: MokoStandards CI / Gate 2: Unit Tests (8.1) (push) Has been skipped
Platform: MokoStandards CI / Gate 2: Unit Tests (8.2) (push) Has been skipped
Platform: MokoStandards CI / Gate 2: Unit Tests (8.3) (push) Has been skipped
Platform: MokoStandards CI / Gate 3: Self-Health Check (push) Has been skipped
Platform: MokoStandards CI / Gate 4: Governance (push) Has been skipped
Platform: MokoStandards CI / Gate 1: Code Quality (push) Failing after 13s
Generic: Repo Health / Site Health (push) Has been skipped
Generic: Repo Health / Access control (push) Successful in 3s
Platform: MokoStandards CI / Gate 5: Template Integrity (push) Has been skipped
Generic: Repo Health / Release configuration (push) Successful in 4s
Generic: Repo Health / Scripts governance (push) Successful in 3s
Generic: Repo Health / Repository health (push) Failing after 4s
Platform: MokoStandards CI / CI Summary (push) Failing after 1s
Universal: Cascade Main → Dev / Cascade main → branches (push) Failing after 2s
Platform: MokoStandards CI / Gate 2: Unit Tests (8.1) (push) Has been skipped
Platform: MokoStandards CI / Gate 2: Unit Tests (8.2) (push) Has been skipped
Platform: MokoStandards CI / Gate 2: Unit Tests (8.3) (push) Has been skipped
Platform: MokoStandards CI / Gate 3: Self-Health Check (push) Has been skipped
Platform: MokoStandards CI / Gate 4: Governance (push) Has been skipped
Platform: MokoStandards CI / Gate 1: Code Quality (push) Failing after 13s
Generic: Repo Health / Site Health (push) Has been skipped
Generic: Repo Health / Access control (push) Successful in 3s
Platform: MokoStandards CI / Gate 5: Template Integrity (push) Has been skipped
Generic: Repo Health / Release configuration (push) Successful in 4s
Generic: Repo Health / Scripts governance (push) Successful in 3s
Generic: Repo Health / Repository health (push) Failing after 4s
Platform: MokoStandards CI / CI Summary (push) Failing after 1s
Authored-by: Moko Consulting
This commit is contained in:
@@ -392,20 +392,6 @@ jobs:
|
||||
exit 0
|
||||
fi
|
||||
|
||||
# Source directory: src/ or htdocs/ (either is valid for extension repos)
|
||||
if [ -d "src" ]; then
|
||||
SOURCE_DIR="src"
|
||||
elif [ -d "htdocs" ]; then
|
||||
SOURCE_DIR="htdocs"
|
||||
else
|
||||
# Platform/tooling repos (deploy/, cli/, monitoring/) don't need src/
|
||||
if [ -d "deploy" ] || [ -d "cli" ] || [ -d "monitoring" ]; then
|
||||
SOURCE_DIR="(platform repo)"
|
||||
else
|
||||
missing_required+=("src/ or htdocs/ (source directory required)")
|
||||
fi
|
||||
fi
|
||||
|
||||
IFS=',' read -r -a required_artifacts <<< "${REPO_REQUIRED_ARTIFACTS}"
|
||||
IFS=',' read -r -a optional_files <<< "${REPO_OPTIONAL_FILES}"
|
||||
IFS=',' read -r -a disallowed_dirs <<< "${REPO_DISALLOWED_DIRS}"
|
||||
@@ -414,6 +400,19 @@ jobs:
|
||||
missing_required=()
|
||||
missing_optional=()
|
||||
|
||||
# Source directory: src/ or htdocs/ (either is valid for extension repos)
|
||||
SOURCE_DIR=""
|
||||
if [ -d "src" ]; then
|
||||
SOURCE_DIR="src"
|
||||
elif [ -d "htdocs" ]; then
|
||||
SOURCE_DIR="htdocs"
|
||||
elif [ -d "deploy" ] || [ -d "cli" ] || [ -d "monitoring" ]; then
|
||||
# Platform/tooling repos don't need src/
|
||||
SOURCE_DIR=""
|
||||
else
|
||||
missing_required+=("src/ or htdocs/ (source directory required)")
|
||||
fi
|
||||
|
||||
for item in "${required_artifacts[@]}"; do
|
||||
if printf '%s' "${item}" | grep -q '/$'; then
|
||||
d="${item%/}"
|
||||
@@ -579,12 +578,14 @@ jobs:
|
||||
joomla_findings+=("updates.xml missing in root (required for Joomla update server)")
|
||||
fi
|
||||
|
||||
INDEX_DIRS=("${SOURCE_DIR}" "${SOURCE_DIR}/admin" "${SOURCE_DIR}/site")
|
||||
for dir in "${INDEX_DIRS[@]}"; do
|
||||
if [ -d "${dir}" ] && [ ! -f "${dir}/index.html" ]; then
|
||||
joomla_findings+=("${dir}/index.html missing (directory listing protection)")
|
||||
fi
|
||||
done
|
||||
if [ -n "${SOURCE_DIR}" ]; then
|
||||
INDEX_DIRS=("${SOURCE_DIR}" "${SOURCE_DIR}/admin" "${SOURCE_DIR}/site")
|
||||
for dir in "${INDEX_DIRS[@]}"; do
|
||||
if [ -d "${dir}" ] && [ ! -f "${dir}/index.html" ]; then
|
||||
joomla_findings+=("${dir}/index.html missing (directory listing protection)")
|
||||
fi
|
||||
done
|
||||
fi
|
||||
|
||||
if [ "${#joomla_findings[@]}" -gt 0 ]; then
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user