Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(verif): in delivery config, use "image" instead of "repository/t…
…ag" (#1819) * feat(verif): "image" instead of "repository.tag" # Problem Previously, the container image specified in a `verifyWith` section was identified by "repository" and "tag" fields, for example: ``` verifyWith: - type: test-container repository: acme/mytests tag: stable ... ``` However, `repository` is a confusing name, as everybody calls this an `image`. In addition, the convention with specifying images is to add the tag afterwards as a comment. # Proposed solution Enable users to specify the image name and tag using a field named `image`. ``` verifyWith: - type: test-container image: acme/mytests:stable ``` ## Deprecating the older syntax Note: to avoid breaking existing apps, the original syntax (repository/tag) still works, the code supports both for now. However, this older syntax should be considered deprecated, and we are going to remove it once we track down all apps that are using it and convert them over. ## Code changes ### TestContainerVerification TestContainerVerification is the class that is deserialized with the `verifyWith` entry in the delivery config. It now takes a nullable `image` field, which will become non-nullable in a future PR. . The `repository` and `tag` fields are now also nullable. Those will go away in a future PR. ### ContainerJobConfig ContainerJobConfig now has an imageId property that is responsible for identifying whether the newer (image) field is in use or the old (repository/tag) is in use, and using this info to compute the correct `imageId` field that ultimately gets passed to orca. This PR also removes reference to the `digest` field in ContainerJobConfig, which we never used. * fix(pr): refactor based on feedback * fix(pr): zap whitespace * fix(pr): disable flakey test * fix(pr): zap whitespace
- Loading branch information