Unable to download artifact Shared artifact

I have my first, very simple build and deployment flows I'm trying to produce. The build is successful but the deploy is not. It dies with:

Unable to download artifact Shared artifact: [Script_art], pattern: [*.*] anchored at: [.]

Looks like I basically have no idea how to configure my artifact correctly. If I go to my default job in my build project I defined an artifact with a location of "." and a copy pattern of "*.*". The artifact is selected in the Artifact Download task in the Deploy project but always fails with the above message.

Since the "build" is really just a Bitbucket pull and a follow up powershell script to copy the files to a different location there should not be much to dig through to to fix... but I don't know what I'm doing here so any help would be appreciated!

12 answers

Do you see the artifact listed on the "Artifacts" tab of the build result?

0 votes

Hi Claude,

With the configuration you have in place for your artifact, Bamboo would consider all files in the build's target directory for inclusion in the artifact. It will not consider subdirectories, because in this case the copy pattern should be "**/*".

You said you use Powershell to move files around - are they still in the "target" directory? If you're having trouble figuring this out, please feel free to open a ticket at support.atlassian.com.

-Christian 

@Tim Crall - yes I see my artifact "Script_art" in the Artiifacts tab of my "Default Job" under my "Default Stage" in my build "Build projects / DSC / Sysconfig".

@Christian Glockner [Atlassian] This "build" is only the checkout of a bunch of powershell scripts and then a follow up task that copies them (via a powershell command) to a second directory. I am out of town for a few days so when I get back I will try this build.

 

@Christian Glockner [Atlassian]

Still getting an error when I try using the **/* pattern. The files are not moved but copied to a second directory and I verified they are still there:

PS C:\Users\user001\bamboo-agent-home\xml-data\build-dir> ls


Directory: C:\Users\user001\bamboo-agent-home\xml-data\build-dir


Mode LastWriteTime Length Name
---- ------------- ------ ----
d----- 4/24/2016 12:13 PM 786433-851969
d----- 4/23/2016 6:09 PM DSC-SYS-JOB1
d----- 4/24/2016 12:13 PM repositoryData


PS C:\Users\user001\bamboo-agent-home\xml-data\build-dir> cd .\DSC-SYS-JOB1
PS C:\Users\usr001\bamboo-agent-home\xml-data\build-dir\DSC-SYS-JOB1> ls


Directory: C:\Users\user001\bamboo-agent-home\xml-data\build-dir\DSC-SYS-JOB1


Mode LastWriteTime Length Name
---- ------------- ------ ----
-a---- 4/23/2016 6:09 PM 522 dsc_pushover_alert.ps1
-a---- 4/23/2016 6:09 PM 2031 Get-NewAesKey.psm1
-a---- 4/23/2016 6:09 PM 151 README.md

 

Unable to download artifact Shared artifact: [Script_art], pattern: [**/*] anchored at: [.]

Im seeing the same result.   I have a build which produces the artifact, and I can see it in the Artifacts tab on the completed build.  When I attempt to deploy this artifact using a deployment plan, I get

Unable to download artifact Shared artifact: [buildPlanArtifact], pattern: [*.tar.gz] anchored at: [target]

 

Very frustrating.  My only workaround was to do this on another identical agent, but now its happening there.

I had this too today, but  just deleted the problematic Deployment plan and created a new, that worked.

0 votes

did anyone ever solve this issue?

Me too facing similar issue.Artifact_download_issue.PNG

0 votes
vaibhav I'm New Here Dec 17, 2017

Try to save each artifact manually (open artifact definition, check/uncheck shared, click on save) - that helped me resolve the issue.

I was having similar issue, i cloned the existing plan having the issue and gave a different name to the new plan. That seemed to do the trick and the issue is fixed now. Though this does not answer the cause of the issue in the original plan, i'm able to move on and continue with my work. If you are still having issues, please note down the steps of the original plan and create a brand new plan (without using clone method) and use the steps noted down for original plan to create the new one. Another user Peter above suggested creating new plan as well. Cloning of the plan - IF works, saves time of not having to add the build steps manually for the new plan.

Same here. Apparently it works only if I change the "Destination path" on the deployment end to anything but what was used before. 

There definitely seems to be some bug when using "Artifact download" task with the "Build" plans. I have No issues if i'm using the exact same (i.e. exact same configuration) for the "Artifact download" task in the "Deployment" projects within Bamboo. I'm consistently seeing this, which results in the error reported in this thread. Not sure if anyone else have used this task ("Artifact download") in the "Build" section and has that working without issues OR were able to resolve the issue there. Any suggestions to resolve this, is much appreciated. Thank You.

I have tried many of the solutions from this thread and they work, but only for a brief period and them I am back to the same issue.  Usually it will work only a day or two...this is very frustrating.

I may be able to provide another piece to the puzzle here.

 

I have a simple plan with two jobs, and one job (the default) is disabled.

 

It turns out, artifact download was trying to copy artifacts from the disabled default job. I was able to confirm this by renaming the artifact to something unique in my disabled job and I noticed in the publish logs it was trying to download that one! I fixed my issue by deleting my disabled job entirely.

 

Can anyone clarify why Bamboo Artifact Download takes the last job's artifact even if said job is disabled?

Suggest an answer

Log in or Join to answer
Community showcase
Renan Battaglin
Published May 18, 2017 in Bamboo

FAQ: How to Upgrade Bamboo Server

Bamboo 5.9 will no longer be supported after June 12, 2017. What does this mean? As part of our End of Life policy, Atlassian supports major versions for two years after the first major iteratio...

1,079 views 0 5
Read article

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you
Atlassian Team Tour

Join us on the Team Tour

We're bringing product updates and pro tips on teamwork to ten cities around the world.

Save your spot