From 92d20db1ecdc1f8500ca8fd2d62a914ef8e5c939 Mon Sep 17 00:00:00 2001 From: Nikolai Rodionov Date: Sat, 19 Oct 2024 15:41:52 +0200 Subject: [PATCH] Add CICD --- .woodpecker.yaml | 20 ++++++++++++++++++++ project.sh | 3 +++ scripts.sh | 2 +- 3 files changed, 24 insertions(+), 1 deletion(-) create mode 100644 .woodpecker.yaml create mode 100755 project.sh diff --git a/.woodpecker.yaml b/.woodpecker.yaml new file mode 100644 index 0000000..664e9ee --- /dev/null +++ b/.woodpecker.yaml @@ -0,0 +1,20 @@ +--- +when: + event: + - push + +steps: + build: + image: alpine + name: Build project + privileged: false + commands: + - envsubst < scripts.sh > project.sh + - chmod +x project.sh + environment: + MESSAGE: hello + run: + image: alpine + name: Run the project + commands: + - ./project.sh diff --git a/project.sh b/project.sh new file mode 100755 index 0000000..ebc3050 --- /dev/null +++ b/project.sh @@ -0,0 +1,3 @@ +#!/usr/bin/env bash + +echo "Hello" diff --git a/scripts.sh b/scripts.sh index 3bbfae6..0c0ff55 100755 --- a/scripts.sh +++ b/scripts.sh @@ -1,3 +1,3 @@ #!/usr/bin/env bash -echo Hello world +echo "${MESSAGE}"