Skip to content

Commit

Permalink
CR
Browse files Browse the repository at this point in the history
  • Loading branch information
yahavi committed Feb 2, 2024
1 parent 34b5977 commit 8885109
Showing 1 changed file with 11 additions and 7 deletions.
18 changes: 11 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@

- [Overview](#overview)
- [Usage](#usage)
- [General](#general)
- [Authorization](#authorization)
- [Setting the build name and build number when publishing build-info to Artifactory](#setting-the-build-name-and-build-number-when-publishing-build-info-to-artifactory)
- [Setting JFrog CLI version](#setting-jfrog-cli-version)
Expand All @@ -25,7 +24,7 @@

## Overview

This GitHub Action downloads, installs and configures JFrog CLI, so that it can be used as part of the workflow.
This GitHub Action downloads, installs and configures [JFrog CLI](https://docs.jfrog-applications.jfrog.io/jfrog-applications/jfrog-cli), so that it can be used as part of the workflow.

Additionally, the Action incorporates the following features when utilizing JFrog CLI to interact with the JFrog Platform:

Expand All @@ -35,8 +34,6 @@ Additionally, the Action incorporates the following features when utilizing JFro

## Usage

### General

```yml
- uses: jfrog/setup-jfrog-cli@v3
- run: jf --version
Expand All @@ -48,8 +45,14 @@ JFrog CLI operates in conjunction with the JFrog Platform. In order to facilitat
There exist two methods to provide these details, and you only need to choose **one** method:
<details>
<summary>Storing JFrog connection details as secrets</summary>
<summary>Connecting to JFrog using secrets</summary>
### General
You can choose one of the following two methods to set the connection details to the JFrog Platform as secrets:
* [Storing the connection details using separate environment variables](#storing-the-connection-details-using-separate-environment-variables)
* [Storing the connection details using single Config Token](#storing-the-connection-details-using-single-config-token)
### Storing the connection details using separate environment variables
The connection details of the JFrog platform used by JFrog CLI can be stored as secrets.
Expand Down Expand Up @@ -113,7 +116,7 @@ If you have multiple Config Tokens as secrets, you can use all of them in the wo
JF_ENV_1: ${{ secrets.JF_SECRET_ENV_1 }}
JF_ENV_2: ${{ secrets.JF_SECRET_ENV_2 }}
- run: |
# Set the JFrog configuration to use by providing the server ID (configured by the 'jf c add' command).
# Set the utilized JFrog configuration by providing the server ID (configured by the 'jf c add' command).
jf c use local-1
# Ping local-1 Artifactory server
jf rt ping
Expand All @@ -129,8 +132,9 @@ If you have multiple Config Tokens as secrets, you can use all of them in the wo
</details>

<details>
<summary>Connect using OpenID Connect</summary>
<summary>Connecting to JFrog using OIDC (OpenID Connect)</summary>

### General
The sensitive connection details, such as the access token used by JFrog CLI on the JFrog platform, can be automatically generated by the action instead of storing it as a secret in GitHub.
This is made possible by leveraging the OpenID-Connect (OIDC) protocol. This protocol can authenticate the workflow issuer and supply a valid access token, requiring only the JF_URL environment variable.
To utilize the OIDC protocol, follow these steps:
Expand Down

0 comments on commit 8885109

Please sign in to comment.