Hey,
In our CI/CD we used to download the replicated CLI (via GitHub), but recently we hit tons of rate limiting from GitHub (too many downloads). As a result, we decided to start using vendor’s docker container replicated/vendor-cli
.
However, we can’t get the release notes working properly, and just wanted to see if you could help us out / have seen this issue before?
For reference, this works perfectly fine:
mountOptions=" --mount type=bind,source=../infra/kots/staging,target=../infra/kots/staging"
docker run -it --rm \
$mountOptions \
replicated/vendor-cli release create --promote test-channel --version 0.0.1 --yaml-dir ../infra/kots/staging --release-notes "CLI release 'kots-release.sh' of 'main' triggered by name.surname" \
--app "$REPLICATED_APP" \
--token "$REPLICATED_API_TOKEN"
But this doesn’t:
command="release create --promote test-channel --version 0.0.1 --yaml-dir ../infra/kots/staging --release-notes \"CLI release 'kots-release.sh' of 'main' triggered by name.surname\""
mountOptions=" --mount type=bind,source=../infra/kots/staging,target=../infra/kots/staging"
docker run -it --rm \
$mountOptions \
replicated/vendor-cli $command \
--app "$REPLICATED_APP" \
--token "$REPLICATED_API_TOKEN"
I have tried tons of different ways of parsing a string (e.g. putting it into array, trying to escape with single quote instead of double quote, even putting a release notes into a file and mounting that file), but literally nothing seems to be working. It looks like replicated treats a space as a separate argument, even if it’s quoted.
Any ideas how can we get this working?
Thanks,
Dom