Uploaded image for project: 'Bitbucket Cloud'
  1. Bitbucket Cloud
  2. BCLOUD-20207

File path in artifacts block can't render variable names

    XMLWordPrintable

Details

    Description

      Issue Summary

      Define a file path in artifacts block in bitbucket-pipelines.yaml fails to render the value and generate artifacts.

      Steps to Reproduce

      • Use the following config:
      ..
      ..
      - step:
          name: Test
          script:
               - mkdir app && ls && git archive --format=zip master -o ./app/$APP_NAME.zip && ls ./app
          artifacts:
               - app/$APP_NAME.zip
      

      Artifacts won't be generated.

      Expected Results

      It should generate an artifact with name $APP_NAME.zip

      Actual Results

      Workaround

      To use glob patters:

      ..
      - step:
          name: Test
          script:
               - mkdir app && ls && git archive --format=zip master -o ./app/$APP_NAME.zip && ls ./app
          artifacts:
               - app/*.zip
      

      Attachments

        Activity

          People

            Unassigned Unassigned
            ssingh4 Saurabh Singh (Inactive)
            Votes:
            4 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: