Native Mode
Enable Native Mode to run build tools with your own configuration and JFrog CLI build-info.
JFrog CLI provides two execution modes for package managers: Wrapped Mode (default) and Native Mode (opt-in). This page explains the difference, which tools support Native Mode, and how to configure each one.
This topic covers the following tasks:
- Maven Native Mode
- Gradle Native Mode
- npm Native Mode
- Poetry Native Mode
- Docker Native Mode
- NuGet Native Mode
- .NET Native Mode
Package Alias is not Native Mode
Package Alias (Ghost Frog) lets you run native commands such as
mvn installornpm installwithout thejfprefix while JFrog CLI still intercepts and routes them. Native Mode still requiresjf mvnorjf npm— it only changes how the underlying tool executes inside JFrog CLI. Use Package Alias when you cannot change existing scripts. Use Native Mode when you want full control of tool configuration files.
Prerequisites
Before using any build-tool command, ensure the following are in place:
| Requirement | Details |
|---|---|
| JFrog CLI configured | Run jf config add at least once. Verify with jf config show. |
| Tool installed | Install the package manager you intend to use (Maven, Gradle, npm, Poetry, Docker, NuGet, or the .NET SDK). |
| Tool-specific runtime | Maven and Gradle require Java in PATH. Verify with java -version. |
| Docker daemon running | Docker Native Mode requires the Docker daemon to be active. Verify with docker info. |
| Artifactory access | For Native Mode: a repository must exist and credentials must be configured via Artifactory Set Me Up. For Wrapped Mode: run jf <tool>-config first. |
Tip
If you have multiple JFrog servers configured, identify your default server with
jf config show. Alljf rt build-publishandjf rt bpcommands use the default server unless you pass--server-id=<your-server-id>explicitly.
Build-Info Flags in Native Mode
The following flags are available on every build-tool command that supports build-info collection. They work in both Wrapped Mode and Native Mode.
| Flag | Default | Description |
|---|---|---|
--build-name | — | A name for this build (for example, my-web-app). Required with --build-number. |
--build-number | — | A number or identifier for this build run (for example, 42, $BUILD_NUMBER). Required with --build-name. |
--project | — | JFrog Artifactory project key. Associates the build-info with a specific project. |
--module | — | Optional module name within the build-info. Use when a single build produces artifacts from multiple modules. Requires --build-name and --build-number. |
Note
--build-nameand--build-numbermust always be provided together. If you supply one without the other, the CLI returns an error.
--module Flag
--module FlagThe --module flag is used when a single build produces multiple logical components:
jf mvn clean install --build-name=my-app --build-number=1 --module=backend
jf mvn clean install --build-name=my-app --build-number=1 --module=frontend
jf rt build-publish my-app 1 --server-id=<your-server-id>The resulting build-info for build my-app #1 contains two modules (backend and frontend), each with their own dependency trees.
Note
jf rt build-publishuses your default configured server. If the build tool was configured with a different server, pass--server-id=<your-server-id>to target the correct server.
Note
The
--moduleflag is functional for all build-tool commands. For some commands (Maven, Gradle), it does not appear injf <tool> --helpoutput but still works when passed on the command line.
Known CLI limitation
jf npm install --helpdoes not display build-info flags (--build-name,--build-number,--module,--project). These flags are supported and work correctly — checkjf npm publish --helpto see them listed, or refer to this page.
--project Flag
--project FlagThe --project flag associates the build-info with a JFrog Project — an organizational unit in the JFrog Platform that groups repositories, builds, and security policies.
jf npm install --build-name=my-app --build-number=1 --project=my-team
jf rt build-publish my-app 1 --project=my-team --server-id=<your-server-id>Note
The JFrog Project (
--project) must already exist in Artifactory before publishing. Create projects in the JFrog Platform UI under Projects.
Wrapped Mode vs Native Mode
| Aspect | Wrapped Mode (Default) | Native Mode |
|---|---|---|
| Repository configuration | Injected by JFrog CLI from .jfrog/projects/*.yaml | You must configure manually |
| Project file modifications | CLI may modify files such as settings.xml, pyproject.toml, or .npmrc | No project files are modified |
| Build-info collection | Automatic when --build-name and --build-number are provided | Supported for Maven, Gradle, npm, Poetry, Docker, Yarn, NuGet, .NET, uv, Helm, Conan, Cargo, Nix, and Ruby when --build-name and --build-number are provided via jf <tool> |
| Lock file changes | Possible (for example, poetry.lock may be updated) | Never modified |
Requires *-config command | Yes — run jf <tool>-config first | No — config is ignored |
| Requires Artifactory Set Me Up | Optional | Required |
Which Tools Support Native Mode?
| Package Manager | How to Enable | Build-Info in Native? | Notes |
|---|---|---|---|
| Maven | export JFROG_RUN_NATIVE=true | Yes | Bypasses mvn-config and .jfrog/ YAML. No settings.xml injection. Configure Maven manually. Multi-module projects are supported in JFrog CLI 2.125.0 or later. See Maven Native Mode. |
| Gradle | export JFROG_RUN_NATIVE=true | Yes | Bypasses gradle-config and .jfrog/ YAML. No Artifactory plugin injection. Pass --server-id for server resolution. |
| npm | export JFROG_RUN_NATIVE=true (or deprecated --run-native flag) | Yes | Bypasses npm-config. Uses your .npmrc. Build-info still works. |
| Poetry | export JFROG_RUN_NATIVE=true | Yes | Bypasses poetry-config and .jfrog/ YAML. No pyproject.toml source injection. No poetry.lock changes. Build-info works via jf poetry. |
| Docker | export JFROG_RUN_NATIVE=true | Yes | For jf docker build: runs native Docker build directly. Build-info is still collected when --build-name and --build-number are provided. |
| Yarn | export JFROG_RUN_NATIVE=true (requires Yarn 4.0.0+) | Yes | Bypasses yarn-config. Uses the project's own .yarnrc.yml authentication. With Yarn 2.x or 3.x installed, the CLI logs a warning and falls back to configured-registry mode instead. |
| NuGet | export JFROG_RUN_NATIVE=true. JFrog CLI 2.123.0 or later. | Yes | Skips nuget-config when .jfrog/projects/nuget.yaml is absent. Pass --repo-resolve for restore and --repo for push. For more information, see NuGet Native Mode. |
| .NET | export JFROG_RUN_NATIVE=true. JFrog CLI 2.123.0 or later. | Yes | Skips dotnet-config when .jfrog/projects/dotnet.yaml is absent. Pass --repo-resolve for restore and --repo for nuget push. For more information, see .NET Native Mode. |
Native-only tools (build execution always runs native. The table's "Wrapped" concept doesn't apply to how jf <tool> itself runs):
| Package Manager | Build-Info in Native? | Notes |
|---|---|---|
| Helm | Yes | Always runs native Helm. Configure via helm registry login or native Helm commands. |
| Conan | Yes | Always runs native Conan. Configure via manual conan remote add, or optionally via jf conan-config (see Configuration: jf conan-config). |
| uv | Yes | Always runs native uv. Configure via [[tool.uv.index]] in pyproject.toml and jf config. No jf uv-config. |
| Ruby | Yes | jf ruby always runs the native gem or bundle executable. Configure with jf setup ruby, --repo, or native RubyGems/Bundler sources. |
| Cargo | Yes | Always runs native Cargo. Configure with jf setup cargo. You don't need JFROG_RUN_NATIVE. |
| Nix | Yes | Always runs native Nix. There's no jf nix-config. You don't need JFROG_RUN_NATIVE. |
Wrapped-only tools (no Native Mode support):
pip, Pipenv, Twine, Go, and Terraform operate only in Wrapped Mode.
Maven Native Mode
When JFROG_RUN_NATIVE=true is set, jf mvn runs Maven without injecting a generated settings.xml or applying .jfrog/projects/maven.yaml. You must configure Maven to resolve from Artifactory yourself using the Artifactory Set Me Up instructions for your Maven repository. The Set Me Up page generates a <server> entry with your Artifactory URL and credentials that you add to your ~/.m2/settings.xml.
Multi-module Maven projects
Maven Native Mode supports multi-module projects (a parent POM with
<modules>) in JFrog CLI 2.125.0 or later. Build-info includes each module and that module's dependencies. If build-info collection cannot read the Maven dependency tree, build-info includes only the rootpom.xml.
Important — existing
mvn-configusersIf you have previously run
jf mvn-config, a.jfrog/projects/maven.yamlfile exists in your project. When this file is present,JFROG_RUN_NATIVE=trueis currently ignored and the CLI falls back to Wrapped Mode silently.
To switch Maven to Native Mode when .jfrog/projects/maven.yaml exists:
-
Remove the wrapped-mode project file:
rm .jfrog/projects/maven.yaml -
Enable Native Mode for the shell session:
export JFROG_RUN_NATIVE=true
Usage
To run a Maven build in Native Mode:
-
Run:
export JFROG_RUN_NATIVE=true jf mvn clean install --build-name=my-app --build-number=1 --server-id=<your-server-id>Where:
- <your-server-id>: The JFrog CLI server ID from
jf config add
For example:
export JFROG_RUN_NATIVE=true jf mvn clean install --build-name=my-app --build-number=1 --server-id=my-serverTo run the project's Maven Wrapper instead of
mvnfromPATH:export JFROG_RUN_NATIVE=true jf mvnw clean install --build-name=my-app --build-number=1 --server-id=my-serverjf mvnwrequiresmvnwormvnw.cmdin the current directory or a parent directory. See Use Maven with JFrog CLI. - <your-server-id>: The JFrog CLI server ID from
Expected output
When Native Mode is active (no .jfrog/projects/maven.yaml present), Maven runs directly and build-info is collected after the build completes:
[INFO] BUILD SUCCESS
[Info] Collecting build info for executed command...
[Info] Build info saved locally. Use 'jf rt bp my-app 1' to publish it to Artifactory.
Note
After Maven finishes, the CLI collects build-info from the build output. This post-build step can take several seconds. The
[Info] Build info saved locallymessage confirms it is complete — the command is not hung.
What changes
- No
settings.xmlinjection - No
.jfrog/projects/maven.yamlis read (requires the file to be absent — see the Important callout in this section) - Build-info is collected after the build completes (post-execution, not via extractor injection)
- All Maven configuration comes from your own
settings.xml - Maven Wrapper: Native Mode
jf mvnalways usesmvnfromPATH. It does not detect or runmvnwormvnw.cmd. To use the project's Maven Wrapper, runjf mvnwinstead.jf mvnwrequires the wrapper script in the current directory or a parent directory and does not fall back toPATH. If.jfrog/projects/maven.yamlexists,jf mvnwbehaves likejf mvnand followsjf mvn-config --use-wrapper. Requires JFrog CLI 2.117.0 or later.
Gradle Native Mode
When JFROG_RUN_NATIVE=true is set, jf gradle runs Gradle without injecting the Artifactory Gradle plugin or applying .jfrog/projects/gradle.yaml. You must configure Gradle to resolve from Artifactory yourself using the Artifactory Set Me Up instructions, which generate the repository URL and credential configuration you add to your build.gradle or gradle.properties.
Important — existing
gradle-configusersIf you have previously run
jf gradle-config, a.jfrog/projects/gradle.yamlfile exists in your project. When this file is present, you must remove it for Native Mode to take effect.
To switch Gradle to Native Mode when .jfrog/projects/gradle.yaml exists:
-
Remove the wrapped-mode project file:
rm .jfrog/projects/gradle.yaml -
Enable Native Mode for the shell session:
export JFROG_RUN_NATIVE=true
Usage
To run a Gradle build in Native Mode:
-
Run:
export JFROG_RUN_NATIVE=true jf gradle clean build --server-id=<your-server-id>Where:
- <your-server-id>: The JFrog CLI server ID to use for build-info (required in Native Mode)
For example:
export JFROG_RUN_NATIVE=true jf gradle clean build --server-id=my-server
Note
In Gradle Native Mode, pass
--server-idto specify which configured JFrog server to use for build-info publishing. Without it, the CLI uses the default server.
What changes
- No Artifactory Gradle plugin injection
- No
.jfrog/projects/gradle.yamlis read (requires the file to be absent — see the Important callout in this section) - Build-info is still collected when
--build-nameand--build-numberare provided - All Gradle configuration comes from your own build scripts
npm Native Mode
When JFROG_RUN_NATIVE=true is set (or the deprecated --run-native flag is used), jf npm delegates entirely to the native npm client and uses your .npmrc for all configuration. You must configure your .npmrc with the Artifactory registry URL and authentication token using the Artifactory Set Me Up instructions for your npm repository.
Usage
To run npm commands in Native Mode:
-
Enable Native Mode for the shell session:
export JFROG_RUN_NATIVE=true -
Run install or publish (examples):
jf npm install --build-name=my-app --build-number=1 jf npm publish --build-name=my-app --build-number=1 --server-id=<your-server-id>Where:
- <your-server-id>: The JFrog CLI server ID for publish operations when you have multiple servers configured
For example:
export JFROG_RUN_NATIVE=true jf npm install --build-name=my-app --build-number=1 jf npm publish --build-name=my-app --build-number=1 --server-id=my-server
When Native Mode is active, the CLI confirms it at the start of execution:
[Info] Running npm in native mode (JFROG_RUN_NATIVE=true)
What changes
- No temporary
.npmrcis created by the CLI - Your own
.npmrcis used for all configuration - Build-info collection still works (as with other tools in Native Mode)
- Publishing uses the native npm publish lifecycle (
prepublish,publish,postpublishscripts run normally — no renaming needed)
Deprecation notice
The
--run-nativeflag is deprecated. Useexport JFROG_RUN_NATIVE=trueinstead. On npm 11.x, passing--run-nativemay also producenpm warn Unknown cli config "--run-native"from the npm client itself — this is harmless and does not affect behaviour.
npm 11.x compatibility
In Wrapped Mode, the JFrog CLI injects
always-authand.npmrc. npm 11.x treats these as deprecated configuration keys and emitsnpm warn Unknown project config "always-auth"on every install. These warnings are harmless. To eliminate them, use Native Mode (JFROG_RUN_NATIVE=true) with a manually configured.npmrc.
Known CLI limitation
jf npm install --helpdoes not display build-info flags. These flags are functional — usejf npm publish --helpto see them listed, or refer to the Build-Info Flags section.
Poetry Native Mode
When JFROG_RUN_NATIVE=true is set, jf poetry delegates to the native Poetry client without injecting Artifactory configuration or modifying project files. You can run Poetry commands through jf poetry (to benefit from build-info collection) or directly via poetry (without build-info). You must configure Poetry to use the Artifactory repository using the Artifactory Set Me Up instructions for your PyPI repository. The Set Me Up page generates the poetry source add command and credential configuration you add to your project.
Usage
To run Poetry with build-info in Native Mode:
-
Enable Native Mode:
export JFROG_RUN_NATIVE=true -
Run installs and publishes through
jf poetrywhen you need build-info, or use nativepoetrywhen you do not:-
With build-info:
jf poetry install --build-name=my-app --build-number=1 jf poetry publish --build-name=my-app --build-number=1 -
Without build-info:
poetry install poetry build poetry publish -r artifactory
-
Note
In Native Mode, you can use either
jf poetry install(which delegates to native Poetry and collects build-info when--build-name/--build-numberare provided) orpoetry installdirectly (no build-info). Poetry must be configured via Artifactory's Set Me Up instructions for both approaches.
What changes
- No
tool.poetry.sourceentries are injected intopyproject.toml - No
poetry updateis called implicitly - No
poetry.lockmodifications - No
.jfrog/projects/poetry.yamlis read - Build-info is still collected when using
jf poetrywith--build-nameand--build-number - All configuration comes from Poetry's own
configand Artifactory Set Me Up
Docker Native Mode
When JFROG_RUN_NATIVE=true is set, jf docker build runs the native Docker build directly instead of the legacy JFrog build flow. Build-info is still collected when --build-name and --build-number are provided. Prerequisites: the Docker daemon must be running (docker info), a JFrog server must be configured with jf config add, and you must be logged in to the Docker registry with docker login <registry> before running these commands. For details, see jf docker.
Usage
To build and push a Docker image in Native Mode:
-
Enable Native Mode, confirm the Docker daemon is running (
docker info), and log in to the registry (docker login <registry>). -
Run build, push, and publish build-info:
export JFROG_RUN_NATIVE=true jf docker build -t <registry>/<image>:<tag> . --build-name=my-app --build-number=1 jf docker push <registry>/<image>:<tag> --build-name=my-app --build-number=1 jf rt bp my-app 1 --server-id=<your-server-id>Where:
- <registry>: Your Artifactory Docker registry host (for example,
acme.jfrog.io) - <image>: Image name (for example,
docker-local/my-app) - <tag>: Image tag (for example,
1.0.0) - <your-server-id>: The JFrog CLI server ID for
jf rt bp
For example:
export JFROG_RUN_NATIVE=true jf docker build -t acme.jfrog.io/docker-local/my-app:1.0.0 . --build-name=my-app --build-number=1 jf docker push acme.jfrog.io/docker-local/my-app:1.0.0 --build-name=my-app --build-number=1 jf rt bp my-app 1 --server-id=my-server - <registry>: Your Artifactory Docker registry host (for example,
What changes
- Docker build runs via the native Docker client (no legacy JFrog build wrapper)
- Build-info is still collected when
--build-nameand--build-numberare provided - Push, pull, and scan behave the same in both modes
NuGet Native Mode
When you set JFROG_RUN_NATIVE=true, jf nuget runs the NuGet CLI you already installed and can collect build-info without jf nuget-config. Native Mode is available in JFrog CLI 2.123.0 or later. Point the command at your Artifactory NuGet repository, or keep using a NuGet configuration file you already manage.
Note
If you already ran
jf nuget-config, delete.jfrog/projects/nuget.yamlbefore you setJFROG_RUN_NATIVE=true. If that file is still in the project, or you created a global configuration withjf nuget-config --global, JFrog CLI keeps using Wrapped Mode.
To switch NuGet to Native Mode when .jfrog/projects/nuget.yaml exists:
-
Remove the wrapped-mode project file:
rm .jfrog/projects/nuget.yamlIf you configured NuGet globally, remove the
nuget.yamlfile from the JFrog CLI home directory as well. -
Enable Native Mode for the shell session:
export JFROG_RUN_NATIVE=true
Usage
To restore, pack, and push in Native Mode:
-
Run:
export JFROG_RUN_NATIVE=true jf nuget restore --repo-resolve=<resolve-repo> --build-name=my-app --build-number=1 --server-id=<your-server-id> jf nuget pack --build-name=my-app --build-number=1 jf nuget push <package>.nupkg --repo=<deploy-repo> --build-name=my-app --build-number=1 --server-id=<your-server-id> jf rt bp my-app 1Where:
- <resolve-repo>: Artifactory NuGet repository used to restore packages, for example
nuget-virtual. - <deploy-repo>: Artifactory NuGet repository used for push, for example
nuget-local. - <your-server-id>: The JFrog CLI server ID from
jf config add. Omit it to use the default server.
For example:
export JFROG_RUN_NATIVE=true jf nuget restore MyApp.sln --repo-resolve=nuget-virtual --build-name=my-app --build-number=1 --server-id=my-server jf nuget push MyLib.1.0.0.nupkg --repo=nuget-local --build-name=my-app --build-number=1 --server-id=my-server jf rt bp my-app 1 - <resolve-repo>: Artifactory NuGet repository used to restore packages, for example
If the project already lists the Artifactory source in its own NuGet configuration, omit --repo-resolve and --repo. JFrog CLI then leaves that configuration unchanged and still collects build-info when you pass --build-name and --build-number.
Warning
nugetdoesn't open.slnxsolution files. Restore those projects withjf dotnet.
What Changes
- You can skip
jf nuget-config. - JFrog CLI doesn't rewrite your project NuGet configuration.
--repo-resolveand--repoadd the Artifactory source for that command only. --repo-resolveand--server-idapply in Native Mode. In Wrapped Mode, configure the repository withjf nuget-config.- Build-info is collected when you provide
--build-nameand--build-number:- The
restore,install, andupdatecommands record dependencies. - The
pushandpackcommands record.nupkgand.snupkgartifacts. - Other NuGet commands run unchanged and don't collect build-info.
- The
- Add
--nuget-v2when the Artifactory repository uses the NuGet V2 protocol.
After a restore that collects build-info, the CLI prints:
[Info] NuGet build info collected. Use 'jf rt bp my-app 1' to publish it.
.NET Native Mode
When you set JFROG_RUN_NATIVE=true, jf dotnet runs the .NET CLI you already installed and can collect build-info without jf dotnet-config. Native Mode is available in JFrog CLI 2.123.0 or later. You can use it for SDK-style projects, including .slnx solutions.
Note
If you already ran
jf dotnet-config, delete.jfrog/projects/dotnet.yamlbefore you setJFROG_RUN_NATIVE=true. If that file is still in the project, or you created a global configuration withjf dotnet-config --global, JFrog CLI keeps using Wrapped Mode.
To switch .NET to Native Mode when .jfrog/projects/dotnet.yaml exists:
-
Remove the wrapped-mode project file:
rm .jfrog/projects/dotnet.yamlIf you configured .NET globally, remove the
dotnet.yamlfile from the JFrog CLI home directory as well. -
Enable Native Mode for the shell session:
export JFROG_RUN_NATIVE=true
Usage
To restore, build, pack, and push in Native Mode:
-
Run:
export JFROG_RUN_NATIVE=true jf dotnet restore --repo-resolve=<resolve-repo> --build-name=my-app --build-number=1 --server-id=<your-server-id> jf dotnet build --build-name=my-app --build-number=1 jf dotnet pack --build-name=my-app --build-number=1 jf dotnet nuget push <package>.nupkg --repo=<deploy-repo> --build-name=my-app --build-number=1 --server-id=<your-server-id> jf rt bp my-app 1Where:
- <resolve-repo>: Artifactory NuGet repository used to restore packages
- <deploy-repo>: Artifactory NuGet repository used by
dotnet nuget push - <your-server-id>: The JFrog CLI server ID from
jf config add. Omit it to use the default server.
For example:
export JFROG_RUN_NATIVE=true jf dotnet restore MyApp.sln --repo-resolve=nuget-virtual --build-name=my-app --build-number=1 --server-id=my-server jf dotnet nuget push MyLib.1.0.0.nupkg --repo=nuget-local --build-name=my-app --build-number=1 --server-id=my-server jf rt bp my-app 1
jf dotnet build, jf dotnet pack, and jf dotnet publish restore packages unless you pass --no-restore. Pass --repo-resolve on those commands when the restore should use Artifactory. publish doesn't record build-info. dotnet add package also restores, but that subcommand can't take a NuGet configuration file. JFrog CLI doesn't apply --repo-resolve there. Run jf dotnet restore --repo-resolve=<resolve-repo> first.
What Changes
- You can skip
jf dotnet-config. - JFrog CLI doesn't rewrite your project NuGet configuration.
- Build-info is collected when you provide
--build-nameand--build-number:- The
restore,build, andaddcommands record dependencies. - The
packandnuget pushcommands record package artifacts. - The
test,run, andpublishcommands run unchanged and don't collect build-info.
- The
- Publish with
jf dotnet nuget push.jf dotnet pushisn't a command.
Supported Client Versions
Recent JFrog CLI versions are forward-compatible with modern package manager clients. The "Max Client" column represents the highest version certified for build-info collection and Native execution without schema errors.
| Package Manager | Min Client | Max Client (Certified) | Build-Info | Mode |
|---|---|---|---|---|
| Maven | 3.1.0 | 3.9.12+ (Rec: 3.9.x) | Full | Wrapped and Native |
| Gradle | 5.0 | 9.0 | Full | Wrapped and Native |
| npm | 6.x | 11.x | Full | Wrapped and Native |
| Docker | 17.07.0 | 29.x (CLI 2.94.0+) | Full | Wrapped and Native |
| Poetry | 1.2.0 | 2.0 | Full | Wrapped and Native |
| Conan V2 | 2.0 | 2.11+ | Full | Native only |
| Helm (OCI) | 3.8.0 | 3.17 | Full | Native only |
| NuGet / .NET | Core 2.0 | .NET 9.0 | Full | Wrapped and Native |
| Go | 1.14 | 1.24 | Full | Wrapped only |
| pip | 20.x | 25.x | Full | Wrapped only |
| uv | 0.8.15 | Latest stable | Full | Native only |
| Terraform | 1.0 | 1.11 | Full | Wrapped only |
| Yarn | 2.4.0 | 4.x | Full | Wrapped and Native |
Notes
- Yarn: see Which Tools Support Native Mode? for the version gate.
- NuGet and .NET: Native Mode is available in JFrog CLI 2.123.0 or later. For more information, see NuGet Native Mode and .NET Native Mode.
- Docker: Minimum client is Docker Engine 17.07.0. Latest certified client is Docker Engine 29.x with JFrog CLI 2.94.0 or later. Use Docker BuildX with
jf docker buildx buildfor multi-platform images.- Go
--no-fallbackdefault istrue(VCS fallback disabled by default).
When to Use Which Mode
Use Wrapped Mode when you want:
- Integrated Artifactory resolution with zero manual configuration
- Automatic build-info capture
- Managed repository configuration via JFrog CLI
- Consistent, unified behaviour across machines and CI
Use Native Mode when you need:
- Strict lockfile fidelity (no modifications to lockfiles such as
poetry.lockorpackage-lock.json) - Zero modification to project metadata files such as
pom.xml,pyproject.toml, orsettings.xml - Full compatibility with the upstream package manager's behaviour
- Builds that must be fully deterministic across environments
- Custom or advanced workflows configured directly in the package manager
Environment Variable Reference
| Variable | Purpose | Default |
|---|---|---|
JFROG_RUN_NATIVE | Enables Native Mode for all supported tools | false (not set) |
When this variable is set to true, it applies to all commands in the current shell session. Unset it or start a new session to return to Wrapped Mode.
Frequently Asked Questions
This section provides answers to frequently asked questions.
FAQs
Q: How do I enable Native Mode?
A: Set the environment variable JFROG_RUN_NATIVE=true before running any jf <tool> command. This applies to all supported tools in the current shell session. Unset it or open a new terminal to return to Wrapped Mode.
Q: Does Native Mode still collect build-info?
A: Yes. When you run commands through jf <tool> with --build-name and --build-number, build-info is collected in both Wrapped and Native Mode. If you run the native tool directly (for example, npm install without the jf prefix), no build-info is collected.
Q: Does Maven Native Mode support multi-module projects?
A: Yes. In JFrog CLI 2.125.0 or later, Maven Native Mode collects build-info for each module in a multi-module project. If .jfrog/projects/maven.yaml exists, remove it, set JFROG_RUN_NATIVE=true, and run jf mvn or jf mvnw.
Q: Which tools support Native Mode vs. Wrapped Mode only?
A: Support varies by tool: some support both modes, some are native-only, and others are wrapped-only (with a special version gate for Yarn). See Which Tools Support Native Mode? for the full breakdown.
Q: Will Native Mode modify my lockfiles or project files?
A: No. Native Mode never modifies poetry.lock, package-lock.json, pyproject.toml, settings.xml, or any other project file. This is the primary reason to choose Native Mode over Wrapped Mode.
Q: Can I use Native Mode for some tools and Wrapped Mode for others?
A: Yes. JFROG_RUN_NATIVE=true applies to all supported tools in the session. Set the variable only before the commands that should run natively, then unset it before wrapped commands.
Q: How do I migrate an existing project from Wrapped Mode to Native Mode?
A: Delete the tool's .jfrog/projects/<tool>.yaml file, configure the package manager to resolve from Artifactory manually (Artifactory Set Me Up), then set JFROG_RUN_NATIVE=true. See Maven Native Mode for the exact commands and the CLI output that confirms the switch.
Q: How can I tell that Native Mode is active?
A: For npm, the CLI prints [Info] Running npm in native mode (JFROG_RUN_NATIVE=true) at the start of each command. For Maven, check that the build output contains [Info] Collecting build info for executed command... instead of Initializing Artifactory Build-Info Recording. For NuGet and .NET, a restore that collects build-info prints [Info] NuGet build info collected. For Gradle and Poetry, refer to the absence of injected configuration in the build output.
Q: How do I run the Maven Wrapper in Native Mode?
A: Run jf mvnw with your Maven goals after you set JFROG_RUN_NATIVE=true and remove .jfrog/projects/maven.yaml if it exists. jf mvn always uses mvn from PATH. See Maven Native Mode and Use Maven with JFrog CLI.
Note
JFROG_RUN_NATIVEis not shown injf mvn --helporjf gradle --help. This page and the FAQ are the primary discovery path for this environment variable.
Related Topics
Updated 15 days ago
