Connect VS Code to the JFrog Platform

If you don't have a JFrog Platform instance, create a free instance in the cloud by running one of the following commands in your terminal.

MacOS and Linux using cUrl

curl -fL "https://getcli.jfrog.io?setup" | sh

Windows using PowerShell

powershell "Start-Process -Wait -Verb RunAs powershell '-NoProfile iwr https://releases.jfrog.io/artifactory/jfrog-cli/v2-jf/[RELEASE]/jfrog-cli-windows-amd64/jf.exe -OutFile $env:SYSTEMROOT\system32\jf.exe'" ; jf setup

The commands will do the following:

  1. Install JFrog CLI on your machine.

  2. Create a FREE JFrog environment in the cloud for you.

  3. Configure VS Code to connect to your new environment.

\

Once the JFrog Extension is installed in VS Code, click on the JFrog tab:

This will open the Sign in page:

Fill in your connection details and click on the Sign In button to start using the extension

Note: If you would like to use custom URLs for Artifactory or Xray, click on Advanced.

You can also choose other option to authenticate with your JFrog Platform instance:

Connect Using SSO

To sign in using SSO, follow these steps:

  1. On the sign-in page, click the Continue with SSO button:

  1. After entering your JFrog platform URL, click on Sign in With SSO.

  2. It will take a few seconds for the browser to redirect you to the SSO sign in page.

  3. You should now be signed in in at vscode.

Connect Using JFrog CLI Connection Details

If JFrog CLI is installed on your machine and is configured with your JFrog Platform connection details, then you should see the message popup in the Sigh in page:

Connect Using Environment Variables

You may set the connection details using the following environment variables. VS Code will read them after it is launched.

  • JFROG_IDE_URL - JFrog URL

  • JFROG_IDE_USERNAME - JFrog username

  • JFROG_IDE_PASSWORD - JFrog password

  • JFROG_IDE_ACCESS_TOKEN - JFrog access token

  • JFROG_IDE_STORE_CONNECTION - Set the value of this environment variable to true, if you'd like VS Code to store the connection details after reading them from the environment variables.

Once the above environment variables are configured, you can expect to see a message popup in the Sigh in page:

Note: For security reasons, it is recommended to unset the environment variables after launching VS Code.

Last updated

© 2024 JFrog Ltd All Rights Reserved