.forgejo/workflows/ci.yaml: WIP, preparing for nsupdate
/ deploy_script (push) Successful in 1s
Details
/ deploy_script (push) Successful in 1s
Details
This commit is contained in:
parent
b0a4b35a2a
commit
ca4f15b67b
|
@ -9,34 +9,35 @@ jobs:
|
|||
steps:
|
||||
- name: Reload bind
|
||||
shell: bash
|
||||
run: git diff HEAD^ HEAD > zone_diff.txt
|
||||
while IFS= read -r line; do
|
||||
case "$line" in
|
||||
"--- "*".zone")
|
||||
CURRENT_ZONE=$(basename "$line" .zone | sed 's/--- //')
|
||||
;;
|
||||
"+++"*)
|
||||
;;
|
||||
"-"* | "+"*)
|
||||
if [[ $line == -* ]]; then # Enregistrement supprimé
|
||||
RECORD=$(echo "$line" | sed 's/^-//')
|
||||
echo - $RECORD
|
||||
run: echo OK
|
||||
# run: git diff HEAD^ HEAD > zone_diff.txt
|
||||
# while IFS= read -r line; do
|
||||
# case "$line" in
|
||||
# "--- "*".zone")
|
||||
# CURRENT_ZONE=$(basename "$line" .zone | sed 's/--- //')
|
||||
# ;;
|
||||
# "+++"*)
|
||||
# ;;
|
||||
# "-"* | "+"*)
|
||||
# if [[ $line == -* ]]; then # Enregistrement supprimé
|
||||
# RECORD=$(echo "$line" | sed 's/^-//')
|
||||
# echo - $RECORD
|
||||
# echo nsupdate -k $TSIG_KEY <<EOF
|
||||
# server $DNS_SERVER
|
||||
# zone $CURRENT_ZONE
|
||||
# update delete $RECORD
|
||||
# send
|
||||
# EOF
|
||||
elif [[ $line == +* ]]; then # Enregistrement ajouté
|
||||
RECORD=$(echo "$line" | sed 's/^+//')
|
||||
echo + $RECORD
|
||||
# elif [[ $line == +* ]]; then # Enregistrement ajouté
|
||||
# RECORD=$(echo "$line" | sed 's/^+//')
|
||||
# echo + $RECORD
|
||||
# nsupdate -k $TSIG_KEY <<EOF
|
||||
# server $DNS_SERVER
|
||||
# zone $CURRENT_ZONE
|
||||
# update add $RECORD
|
||||
# send
|
||||
# EOF
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
done < zone_diff.txt
|
||||
# fi
|
||||
# ;;
|
||||
# esac
|
||||
# done < zone_diff.txt
|
Loading…
Reference in New Issue