-
Notifications
You must be signed in to change notification settings - Fork 203
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
s3Upload() doesn't work if includePathPattern
matches multiple files
#83
Comments
can you try again with 1.27 |
Version 1.27 I have the build directory:
I want to upload it to S3:
It only uploads |
This issue is still unresolved in 1.31 |
Can you please describe your setup? I cannot reproduce the problem. |
My pipeline looks similar to this:
I can confirm that the tar files are in the build directory. And the following is what i'm actually using:
|
Seems it's known bug but still waiting for taking into consideration: One of the workaround would be usage of pipeline findFiles: |
The problem is that I cannot reproduce it on my test setup to debug the root cause. |
Is there an online playground for jenkins pipeline, or some other ways how to share the whole build job? Because the setup that is failing for me is literally the official example: |
I am also seeing this error :/ |
Same here. This works:
Take out the comment on Is there something I can do on my end to allow debugging/log files/etc.? |
Having the same problem. Trying to upload the contents of an entire folder to the root of the S3 bucket, where the files list is something like: ls -l assets/marketing/
-rw-rw-r--. 1 jenkins jenkins 85598 Jan 11 16:52 ai_logo.png
-rw-rw-r--. 1 jenkins jenkins 1559 Jan 11 16:52 favicon-16x16.png
-rw-rw-r--. 1 jenkins jenkins 2366 Jan 11 16:52 favicon-32x32.png
-rw-rw-r--. 1 jenkins jenkins 1150 Jan 11 16:52 favicon.ico
-rw-rw-r--. 1 jenkins jenkins 180092 Jan 11 16:52 header.jpg
-rw-rw-r--. 1 jenkins jenkins 3635 Jan 15 13:19 index.html
-rw-rw-r--. 1 jenkins jenkins 15173 Jan 11 16:52 logo.png
-rw-rw-r--. 1 jenkins jenkins 268 Jan 15 10:48 README.md
-rw-rw-r--. 1 jenkins jenkins 487 Jan 11 17:35 ribbon.css
-rw-rw-r--. 1 jenkins jenkins 1825 Jan 11 16:52 style.css The following will fail to upload anything:
And this version will upload only one of each file type:
|
The only useful work-around while still using withAWS and s3Upload is currently by using a findFiles glob and looping through the resulting list. It works fine, and will make it easy to convert a Jenkinsfile over when s3Upload gets fixed, but here is an example for anyone else:
|
It does not keep the relative path, it will upload files in every sub folders into the root of the bucket. |
Hey @weidonglian I haven't tried it but findFiles glob includes
As a value. I would check that out (you may have to remove $PWD) and then put the value in for path: I know it is a awful work-around, but it is the only thing I've been able to make work so far. |
I believe I may be able to clarify the issue a bit here. The problem appears to arise on Windows agents, but not on *nix agents. Example pipeline
When running on a *nix agent, the commands all properly upload files. When running on a windows agent (e.g. change |
Can you try what happens if you use |
This bug does happen on Linux.
…On Thu, Feb 21, 2019 at 9:35 AM Thorsten Hoeger ***@***.***> wrote:
Can you try what happens if you use \ as path separator?
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#83 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AAmUy8p6KaRr-zQGLseuyBDnWcSrg-buks5vPtjKgaJpZM4Tu66k>
.
|
Using A potential work-around for this issue (if both windows-like and unix-like nodes are available) is to stash files on the Windows node and unstash them to a *nix node before the s3Upload command is executed. |
@ryan-summers it totally happens on *nix agents as well. In fact, I didn't even know you could use a windows agent. |
Perhaps the windows vs. *nix agents upload is a different issue then. |
Any progress on this? Running into same issue on *nix agents as well. |
Seems to be an issue only on slaves. If you run the exact same pipeline on the master, it appears to work. See: https://issues.jenkins-ci.org/browse/JENKINS-44000 |
I was having this exact same problem, building the plugin from source resolved my issue (docker slaves). |
This works fine in slave too.. Example Pipeline stage stage('Deployment')
|
Hi, is there any progress on this or has it been resolved? I am on v1.36, using it to separate regular vs gz files. perhaps I am using it the wrong way also. Help appreciated.
|
Version 1.26
Assuming we have the following content in the
build
directory:And we want to upload it to S3:
This works:
This doesn't work and only uploads
mapping.txt
:This doesn't work either and doesn't upload anything:
The text was updated successfully, but these errors were encountered: