Skip to content

Commit ba29779

Browse files
author
Maurice Faber
committed
fix: drone gen [ci skip]
1 parent 978eb0e commit ba29779

File tree

3 files changed

+9
-3
lines changed

3 files changed

+9
-3
lines changed

bin/gen-drone.sh

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22
set -eu
33
set -o pipefail
44

5-
65
ENV_DIR=${ENV_DIR:-./env}
76
. $ENV_DIR/.secrets
87

@@ -33,7 +32,7 @@ function template_drone_config() {
3332
cat $templatePath | sed -e "s/__CLOUD/${CLOUD}/g" -e "s/__CLUSTER/${CLUSTER}/g" \
3433
-e "s/__IMAGE_TAG/${otomi_image_tag}/g" -e "s|__WEBHOOK|${webhook}|g" \
3534
-e "s/__CUSTOMER/${customer_name}/g" \
36-
> $target
35+
>$target
3736
}
3837

3938
for_each_cluster template_drone_config

bin/otomi

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -329,6 +329,11 @@ function execute() {
329329
kubectl config use $K8S_CONTEXT
330330
drun bin/bootstrap.sh 1
331331
;;
332+
gen-drone)
333+
check_kube_context=0
334+
evaluate_secrets
335+
drun bin/gen-drone.sh
336+
;;
332337
test)
333338
validate_cluster_env
334339
evaluate_secrets

bin/pre-commit.sh

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,10 @@
11
#!/usr/bin/env bash
22
set -e
3+
set -o pipefail
4+
5+
ENV_DIR=${ENV_DIR:-./env}
36

47
match="clusters.yaml"
5-
set -o pipefail
68
if git -C $ENV_DIR diff --name-only | grep $match >/dev/null; then
79
bin/gen-drone.sh
810
fi

0 commit comments

Comments
 (0)