jfrog / jfrog/jfrog-cli

Use environment variables as substitution for passing in --url and --access-token

Open
#3,490 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

feature request
Dominant language
Go
Stars
595
Forks
307
Avg merge
4d 17h
Merged PRs (30d)
17

Description

Problem Description
We use jfrog-cli in our Jenkins pipeline. However, it appears that now we can bypass adding the ~/jfrog/*.conf configuration by adding the parameters --url <artifactory> and --access-token <token> to a large subset of jfrog-cli commands.

Solution
We'd like to be able to use jfrog-cli without using the extra command line parameters (since not every command needs them) via the environment. For example, it would be very handy if we can use them via

Here, it would be helpful that the jfrog-cli command itself understand that the URL is https://artifactory.failsafe.com and appends "artifactory" where necessary (e.g. https://artifactory.failsafe.com/artifactory.

This would be particularly helpful in a docker environment where passing in credentials can't be done via stdin, and using the command line argument is "insecure" if not done right

Alternatives
We've been able to use it via the command line, but I can't pass it a fixed set of parameters that works for every command.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by tracing how jfrog-cli commands currently consume --url and --access-token, and how command-line values interact with configuration. Define the environment-variable precedence and the requested Artifactory URL normalization, then verify representative commands work without those flags while existing flag and configuration behavior remains unchanged.

Written by the indexing model from the issue text.

Assessment

Tech stack
go
Domain
authentication, cli
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.