Skip to content
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

jf rt upload --spec does not work for a pattern with * #2712

Open
yogch opened this issue Oct 2, 2024 · 0 comments
Open

jf rt upload --spec does not work for a pattern with * #2712

yogch opened this issue Oct 2, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@yogch
Copy link

yogch commented Oct 2, 2024

Describe the bug

The pattern of a jfrog spec file does not work correctly with *.
It does work if I specific the full path of that file.

Current behavior

I have a jfrog.spec file:

{
  "files": [
    {
      "pattern": "/home/me/bamboo-agent-home/xml-data/build-dir/MY-PL-CHEC/output/my-artifact-*.tar.gz",
      "target": "official/my-artifact/1.2.3-official.1/",
      "targetProps": "build.name=me-official;build.number=1;version=1.2.3"
    }
  ]
}

For some reason the jfrog cli fails to understand I want to upload the file:

/home/me/bamboo-agent-home/xml-data/build-dir/MY-PL-CHEC/output/my-artifact-1.2.3.tar.gz

Instead, he's trying to go to another file:

/home/me/bamboo-agent-home/xml-data/build-dir/MY-PL-CHEC/output/dir2/data/usr-empty/provisioning

If I use the exact file's name, upload does work.

Here's the command I'm using and the log:

$ JFROG_CLI_LOG_LEVEL=DEBUG CI=TRUE jf rt upload --insecure-tls --url https://1.2.3.4:443/artifactory --access-token XXX --spec ./jfrog.spec

08:02:40 [Debug] JFrog CLI version: 2.70.0
08:02:40 [Debug] OS/Arch: linux/amd64
08:02:40 [Debug] Trace ID for JFrog Platform logs: 02fcdb4dccee85f1
08:02:40 [Debug] Usage Report: Sending info...
08:02:40 [Debug] Sending HTTP GET request to: https://1.2.3.4:443/artifactory/api/system/version
08:02:40 [🚨Error] stat /home/me/bamboo-agent-home/xml-data/build-dir/MY-PL-CHEC/output/dir2/data/usr-empty/provisioning: no such file or directory
08:02:40 [🚨Error] stat /home/me/bamboo-agent-home/xml-data/build-dir/MY-PL-CHEC/output/dir2/data/usr-empty/provisioning: no such file or directory
08:02:40 [Debug] Uploaded 0 artifacts.
08:02:40 [🚨Error] stat /home/me/bamboo-agent-home/xml-data/build-dir/MY-PL-CHEC/output/dir2/data/usr-empty/provisioning: no such file or directory
08:02:40 [Debug] Artifactory response: 200 
08:02:40 [Debug] JFrog Artifactory version is: 7.84.15
08:02:40 [Debug] Sending HTTP POST request to: https://1.2.3.4:443/artifactory/api/system/usage
{
  "status": "failure",
  "totals": {
    "success": 0,
    "failure": 0
  }
}
08:02:40 [🔵Info] Trace ID for JFrog Platform logs: 02fcdb4dccee85f1
08:02:40 [🚨Error] upload finished with errors. Review the logs for more information

Reproduction steps

No response

Expected behavior

No response

JFrog CLI version

2.70.0

Operating system type and version

Ubuntu 24.04 LTS

JFrog Artifactory version

7.84.15

JFrog Xray version

No response

@yogch yogch added the bug Something isn't working label Oct 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant