chore(authentik): test outposts on CI (#9721)

**Description**
<!--
Please include a summary of the change and which issue is fixed. Please
also include relevant motivation and context. List any dependencies that
are required for this change.
-->
⚒️ Fixes  # <!--(issue)-->

**⚙️ Type of change**

- [ ] ⚙️ Feature/App addition
- [ ] 🪛 Bugfix
- [ ] ⚠️ Breaking change (fix or feature that would cause existing
functionality to not work as expected)
- [ ] 🔃 Refactor of current code

**🧪 How Has This Been Tested?**
<!--
Please describe the tests that you ran to verify your changes. Provide
instructions so we can reproduce. Please also list any relevant details
for your test configuration
-->

**📃 Notes:**
<!-- Please enter any other relevant information here -->

**✔️ Checklist:**

- [ ] ⚖️ My code follows the style guidelines of this project
- [ ] 👀 I have performed a self-review of my own code
- [ ] #️⃣ I have commented my code, particularly in hard-to-understand
areas
- [ ] 📄 I have made corresponding changes to the documentation
- [ ] ⚠️ My changes generate no new warnings
- [ ] 🧪 I have added tests to this description that prove my fix is
effective or that my feature works
- [ ] ⬆️ I increased versions for any altered app according to semantic
versioning

** App addition**

If this PR is an app addition please make sure you have done the
following.

- [ ] 🪞 I have opened a PR on
[truecharts/containers](https://github.com/truecharts/containers) adding
the container to TrueCharts mirror repo.
- [ ] 🖼️ I have added an icon in the Chart's root directory called
`icon.png`

---

_Please don't blindly check all the boxes. Read them and only check
those that apply.
Those checkboxes are there for the reviewer to see what is this all
about and
the status of this PR with a quick glance._
This commit is contained in:
Stavros Kois
2023-06-17 19:12:45 +03:00
committed by GitHub
parent 19a136f636
commit f07098cdfb
9 changed files with 110 additions and 12 deletions

View File

@@ -42,7 +42,9 @@ function check_chart_schema(){
yamale_output=$(yamale --schema .github/chart_schema.yaml "$chart_path/Chart.yaml")
yamale_exit_code=$?
while IFS= read -r line; do
echo -e "\t$line"
if [[ -n $line ]]; then
echo -e "\t$line"
fi
done <<< "$yamale_output"
if [ $yamale_exit_code -ne 0 ]; then
@@ -61,7 +63,9 @@ function helm_lint(){
helm_lint_output=$(helm lint --quiet "$chart_path")
helm_lint_exit_code=$?
while IFS= read -r line; do
echo -e "\t$line"
if [[ -n $line ]]; then
echo -e "\t$line"
fi
done <<< "$helm_lint_output"
if [ $helm_lint_exit_code -ne 0 ]; then
@@ -75,12 +79,19 @@ export -f helm_lint
function helm_template(){
chart_path=${1:?"No chart path provided to [Helm template]"}
values=${2:-}
if [[ -n "$values" ]]; then
values="-f $values"
fi
# Print only errors and warnings
helm_template_output=$(helm template "$chart_path" 2>&1 >/dev/null)
helm_template_output=$(helm template $values "$chart_path" 2>&1 >/dev/null)
helm_template_exit_code=$?
while IFS= read -r line; do
echo -e "\t$line"
if [[ -n $line ]]; then
echo -e "\t$line"
fi
done <<< "$helm_template_output"
if [ $helm_template_exit_code -ne 0 ]; then
@@ -98,7 +109,9 @@ function yaml_lint(){
yaml_lint_output=$(yamllint --config-file .github/yaml-lint-conf.yaml "$file_path")
yaml_lint_exit_code=$?
while IFS= read -r line; do
echo -e "\t$line"
if [[ -n $line ]]; then
echo -e "\t$line"
fi
done <<< "$yaml_lint_output"
if [ $yaml_lint_exit_code -ne 0 ]; then
@@ -132,7 +145,7 @@ function lint_chart(){
for values in $chart_path/ci/*values.yaml; do
if [ -f "${values}" ]; then
echo "👣 Helm Template - [$values]"
helm_template "$chart_path" -f "$values"
helm_template "$chart_path" "$values"
fi
done
@@ -168,6 +181,7 @@ function lint_chart(){
echo ''
} > "$curr_result_file"
cat "$curr_result_file"
# $curr_result starts with 0, and it gets set to 1 only when a linting step fails
echo $curr_result >> "$status_file"
}
export -f lint_chart