More checks in `recipe .. lint`

This commit is contained in:
3wc 2021-07-11 17:20:42 +02:00
parent 19041af9d5
commit b694c37073
1 changed files with 23 additions and 1 deletions

24
abra
View File

@ -2212,7 +2212,7 @@ sub_recipe_lint() {
local service_configs
service_configs=$($YQ e '.services.*.configs' "$compose_file")
if [ -n "$service_configs" ]; then
if grep -v "null" -q <<< "$service_configs"; then
# Check for .env.sample
if [ -f abra.sh ]; then
info "Found abra.sh"
@ -2220,6 +2220,28 @@ sub_recipe_lint() {
warning "No abra.sh, but config vars defined"
fi
fi
# Check for .drone.yml
if [ -f .drone.yml ]; then
info "Found .drone.yml"
# Check for stack-ssh-deploy CI
if $YQ e -e '.steps.[] | select(.image == "decentral1se/stack-ssh-deploy:latest")' .drone.yml > /dev/null 2>&1; then
info "Found abra auto-release"
else
warning "Missing drone-abra auto-release"
fi
# Check for drone-abra auto-release
if $YQ e -e '.steps.[] | select(.image == "decentral1se/drone-abra:latest")' .drone.yml > /dev/null 2>&1; then
info "Found abra auto-release"
else
warning "Missing drone-abra auto-release"
fi
else
warning "No .drone.yml"
fi
}
###### .. recipe <recipe> release