Cannot run Groovy script to list aws ecr repositories

This issue is archived. You can view it, but you can't modify it. Learn more

XMLWordPrintable

      I want to run this script in order to get aws ecr repositories:

       

      def profile = "ecr"
      def region = "us-east-1"
      def cmd_output = "aws ecr describe-repositories --region $region --output yaml".execute()
      def awk_cmd_output = cmd_output | ['awk', '/repositoryName:/ \{print $2}'].execute()
      def repo_names = awk_cmd_output.text.tokenize().reverse()
      return repo_names

      Before 2 months this script was working fine but into the latest version it's no longer working.

       

            Assignee:
            Bruno P. Kinoshita
            Reporter:
            Peter
            Archiver:
            Jenkins Service Account

              Created:
              Updated:
              Archived: