-
Notifications
You must be signed in to change notification settings - Fork 48
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
Upload with checksum not working #62
Comments
You can actually provide the expected checksums as part of the normal upload requests, give this a go: path_to_file = File.expand_path('../Testdata/BAMS/TestFileForBams')
artifact = Artifactory::Resource::Artifact.new(
local_path: path_to_file,
client: client,
checksums: {
'md5' => Digest::MD5.file(path_to_file).hexdigest,
'sha1' => Digest::SHA1.file(path_to_file).hexdigest,
}
)
artifact.upload(
LOCAL_REPOSITORY_KEY,
repository_path+"#{file_name}",
) |
Hi thanks for the prompt reply. I will try that and let you know.One other question,i see there are newer versions of artifactory out there. But when i try to upgrade to 2.x.x and run the test above i now get another error saying 'Local destination folder is missing' . The issue i think is that the old version takes in a local destination parameter and when i upgrade to the new version im guessing that parameter isnt part of the upload signature? |
@AbezarBaker Not sure, we use a 3.9.x version of Artifactory here at Chef. The newest version is 4.7.3 is the newest version. |
Hi @schisamo is there a typo in your comment above?When i copied it to it says missing argument artifact.upload( |
No luck @schisamo .Still get the same error C:\Ruby21-x64\bin\ruby.exe -e $stdout.sync=true;$stderr.sync=true;load($0=ARGV.shift) C:/ruby_workspace/samigit/PA/Utilities/bin/test_upload_artifactory2.rb Process finished with exit code 1 |
Hi
I am trying to use the method "upload_with_checksum" but i get this error
-------------The code is below------------
Any idea what i am doing wrong here???
The text was updated successfully, but these errors were encountered: