Last active
June 14, 2022 22:22
-
-
Save pivotaljohn/a7ac9e295dbebe00b0aa15a76f7ce42a to your computer and use it in GitHub Desktop.
Native ytt equivalent of GitLab's !reference
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! .gitlab-ci.yml | |
#@ load("@ytt:template", "template") | |
#@ load("helpers.lib.yaml", "setup", "teardown") | |
test: | |
script: | |
- #@ template.replace(setup()) | |
- echo running my own command | |
- #@ template.replace(teardown()) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! Content of helpers.lib.yaml | |
--- | |
#@ def setup(): | |
- echo creating environment1 | |
- echo creating environment2 | |
#@ end | |
--- | |
#@ def teardown(): | |
- echo deleting environment1 | |
- echo deleting environment2 | |
#@ end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment