-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(werft): add application version param support
Implements werf#6390 The current implementation scope: * Add `applicationVersion` global param support to `werf.yml` * Add `applicationVersionFile` global param support to `werf.yml` * Plain/text, JSON, YAML files can be used as `applicationVersionFile` params * Giterminism is enforced for `applicationVersionFile` param * Gitemenis dev mode is supported for `applicationVersionFile` param * Handle corner case when both `applicationVersion` and `applicationVersionFile` params are set * `applicationVersion` value is available in nelm templates by using `$.Values.werf.applicationVersion` variable `werf.yaml` file content: ``` project: demo-app configVersion: 1 applicationVersion: v0.0.1 --- image: backend dockerfile: backend.Dockerfile --- image: frontend dockerfile: frontend.Dockerfile ``` `werf.yaml` file content: ``` project: demo-app configVersion: 1 applicationVersionFile: ./version.json --- image: backend dockerfile: backend.Dockerfile --- image: frontend dockerfile: frontend.Dockerfile ``` `./version.json` file content: ``` { "version": "v0.0.1" } ``` `werf.yaml` file content: ``` project: demo-app configVersion: 1 applicationVersionFile: ./version.yaml --- image: backend dockerfile: backend.Dockerfile --- image: frontend dockerfile: frontend.Dockerfile ``` `./version.yaml` file content: ``` version: v0.0.1 ``` `werf.yaml` file content: ``` project: demo-app configVersion: 1 applicationVersionFile: ./version --- image: backend dockerfile: backend.Dockerfile --- image: frontend dockerfile: frontend.Dockerfile ``` `./version` file content: ``` v0.0.1 ```
- Loading branch information
Showing
9 changed files
with
137 additions
and
32 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,12 @@ | ||
package config | ||
|
||
type Meta struct { | ||
ConfigVersion int | ||
Project string | ||
Deploy MetaDeploy | ||
Cleanup MetaCleanup | ||
GitWorktree MetaGitWorktree | ||
Build MetaBuild | ||
ApplicationVersion string | ||
ApplicationVersionFile string | ||
ConfigVersion int | ||
Project string | ||
Deploy MetaDeploy | ||
Cleanup MetaCleanup | ||
GitWorktree MetaGitWorktree | ||
Build MetaBuild | ||
} |
This file contains 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
This file contains 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
This file contains 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