From 80b8f11d9bffc4f93c65b91c815152abdb1adcc6 Mon Sep 17 00:00:00 2001 From: tomjfrog Date: Wed, 12 Jun 2024 12:26:41 -0500 Subject: [PATCH 01/12] Refactored Rust example to use two different Actions specs. --- .github/workflows/rust-example-app.yaml | 25 ++++++++++++++++ .github/workflows/rust-example-library.yaml | 32 +++++++++++++++++++++ 2 files changed, 57 insertions(+) create mode 100644 .github/workflows/rust-example-app.yaml create mode 100644 .github/workflows/rust-example-library.yaml diff --git a/.github/workflows/rust-example-app.yaml b/.github/workflows/rust-example-app.yaml new file mode 100644 index 0000000..d854f33 --- /dev/null +++ b/.github/workflows/rust-example-app.yaml @@ -0,0 +1,25 @@ +name: Rust & Cargo Quotes Application +on: workflow_dispatch + +env: + CARGO_TERM_COLOR: always + CARGO_REGISTRIES_CRATES_TOKEN: ${{ secrets.RUST_EXAMPLE_AUTHENTICATION_TOKEN }} + CARGO_REGISTRIES_INNERSOURCE_TOKEN: ${{ secrets.RUST_EXAMPLE_AUTHENTICATION_TOKEN }} + CARGO_REGISTRIES_JFROGQUOTES_TOKEN: ${{ secrets.RUST_EXAMPLE_AUTHENTICATION_TOKEN }} + +jobs: + build-and-publish: + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v4 + - name: Validate Cargo installation + run: cargo --version + + - name: Build Application + working-directory: jfrog_app + run: cargo build --release --verbose + + - name: Publish Application To Artifactory + working-directory: jfrog_app + run: cargo publish --token "Bearer ${{ secrets.RUST_EXAMPLE_AUTHENTICATION_TOKEN }}" \ No newline at end of file diff --git a/.github/workflows/rust-example-library.yaml b/.github/workflows/rust-example-library.yaml new file mode 100644 index 0000000..3462188 --- /dev/null +++ b/.github/workflows/rust-example-library.yaml @@ -0,0 +1,32 @@ +name: Rust & Cargo Innersource Library +on: workflow_dispatch + +env: + CARGO_TERM_COLOR: always + CARGO_REGISTRIES_CRATES_TOKEN: ${{ secrets.RUST_EXAMPLE_AUTHENTICATION_TOKEN }} + CARGO_REGISTRIES_INNERSOURCE_TOKEN: ${{ secrets.RUST_EXAMPLE_AUTHENTICATION_TOKEN }} + CARGO_REGISTRIES_JFROGQUOTES_TOKEN: ${{ secrets.RUST_EXAMPLE_AUTHENTICATION_TOKEN }} + +jobs: + build-and-publish: + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v4 + - name: Validate Cargo installation + run: cargo --version + + # This step is helpful to prevent messing with different checksums being produced on the same semver + - name: Preprocess Cargo.toml + working-directory: jfrog_quotes + run: | + build_number=${{ github.run_number }} + sed -i "s/^version = \"0.1.dev\"/version = \"0.1.${build_number}\"/" Cargo.toml + + - name: Build Library + working-directory: jfrog_quotes + run: cargo build --release --verbose + + - name: Publish Library To Artifactory + working-directory: jfrog_quotes + run: cargo publish --allow-dirty --token "Bearer ${{ secrets.RUST_EXAMPLE_AUTHENTICATION_TOKEN }}" \ No newline at end of file From bdfd8dd4edf00a860e68465a7f6383094f668186 Mon Sep 17 00:00:00 2001 From: tomjfrog Date: Wed, 12 Jun 2024 12:27:35 -0500 Subject: [PATCH 02/12] Removed legacy Rust single-spec workflow. --- .github/workflows/rust-example.yaml | 33 ----------------------------- 1 file changed, 33 deletions(-) delete mode 100644 .github/workflows/rust-example.yaml diff --git a/.github/workflows/rust-example.yaml b/.github/workflows/rust-example.yaml deleted file mode 100644 index aea6d8c..0000000 --- a/.github/workflows/rust-example.yaml +++ /dev/null @@ -1,33 +0,0 @@ -name: Rust & Cargo Build and Deploy -on: workflow_dispatch - -env: - CARGO_TERM_COLOR: always - CARGO_REGISTRIES_CRATES_TOKEN: ${{ secrets.RUST_EXAMPLE_AUTHENTICATION_TOKEN }} - CARGO_REGISTRIES_INNERSOURCE_TOKEN: ${{ secrets.RUST_EXAMPLE_AUTHENTICATION_TOKEN }} - CARGO_REGISTRIES_JFROGQUOTES_TOKEN: ${{ secrets.RUST_EXAMPLE_AUTHENTICATION_TOKEN }} - -jobs: - build-and-publish: - runs-on: ubuntu-latest - steps: - - name: Checkout - uses: actions/checkout@v4 - - name: Validate Cargo installation - run: cargo --version - - - name: Build Library - working-directory: ./rust/jfrog_quotes - run: cargo build --release --verbose - - - name: Publish Library To Artifactory - working-directory: ./rust/jfrog_quotes - run: cargo publish --token "Bearer ${{ secrets.RUST_EXAMPLE_AUTHENTICATION_TOKEN }}" - - - name: Build Application - working-directory: ./rust/jfrog_app - run: cargo build --release --verbose - - - name: Publish Application To Artifactory - working-directory: ./rust/jfrog_app - run: cargo publish --token "Bearer ${{ secrets.RUST_EXAMPLE_AUTHENTICATION_TOKEN }}" \ No newline at end of file From fa84e9f3e2ff6ea9a2e0ee5c6ac223639b9fa11e Mon Sep 17 00:00:00 2001 From: tomjfrog Date: Wed, 12 Jun 2024 12:38:53 -0500 Subject: [PATCH 03/12] Attempt 2 --- .github/workflows/rust-example-library.yaml | 4 +++- rust/jfrog_app/Cargo.toml | 2 +- rust/jfrog_quotes/Cargo.toml | 2 +- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/.github/workflows/rust-example-library.yaml b/.github/workflows/rust-example-library.yaml index 3462188..c07aa64 100644 --- a/.github/workflows/rust-example-library.yaml +++ b/.github/workflows/rust-example-library.yaml @@ -16,7 +16,9 @@ jobs: - name: Validate Cargo installation run: cargo --version - # This step is helpful to prevent messing with different checksums being produced on the same semver + # This step is helpful to prevent messing with different file checksums being produced on the same semver of the library + # The Cargo file checksum considers some build information along with the file contents, which causes the _same application code_ to produce + # different file checksums, which cascades down to Cargo dependency resolution failures. - name: Preprocess Cargo.toml working-directory: jfrog_quotes run: | diff --git a/rust/jfrog_app/Cargo.toml b/rust/jfrog_app/Cargo.toml index 33fc26b..09f683e 100644 --- a/rust/jfrog_app/Cargo.toml +++ b/rust/jfrog_app/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "jfrog_app" -version = "0.1.0" +version = "0.1.dev" edition = "2021" # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html diff --git a/rust/jfrog_quotes/Cargo.toml b/rust/jfrog_quotes/Cargo.toml index 17dafa1..9154356 100644 --- a/rust/jfrog_quotes/Cargo.toml +++ b/rust/jfrog_quotes/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "jfrog_quotes" -version = "0.1.0" +version = "0.1.dev" edition = "2021" # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html From 8f8e320c57a32f50e1ad5f3129c1edccc9f5a686 Mon Sep 17 00:00:00 2001 From: tomjfrog Date: Wed, 12 Jun 2024 12:40:43 -0500 Subject: [PATCH 04/12] Triage 1 --- .github/workflows/rust-example-library.yaml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/rust-example-library.yaml b/.github/workflows/rust-example-library.yaml index c07aa64..cba36f5 100644 --- a/.github/workflows/rust-example-library.yaml +++ b/.github/workflows/rust-example-library.yaml @@ -22,6 +22,8 @@ jobs: - name: Preprocess Cargo.toml working-directory: jfrog_quotes run: | + pwd + ls build_number=${{ github.run_number }} sed -i "s/^version = \"0.1.dev\"/version = \"0.1.${build_number}\"/" Cargo.toml From 721579d287ff04136de7b72dff0702b058b3ae85 Mon Sep 17 00:00:00 2001 From: tomjfrog Date: Wed, 12 Jun 2024 12:43:30 -0500 Subject: [PATCH 05/12] Triage 2 --- .github/workflows/rust-example-library.yaml | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/.github/workflows/rust-example-library.yaml b/.github/workflows/rust-example-library.yaml index cba36f5..c99d910 100644 --- a/.github/workflows/rust-example-library.yaml +++ b/.github/workflows/rust-example-library.yaml @@ -16,16 +16,12 @@ jobs: - name: Validate Cargo installation run: cargo --version - # This step is helpful to prevent messing with different file checksums being produced on the same semver of the library - # The Cargo file checksum considers some build information along with the file contents, which causes the _same application code_ to produce - # different file checksums, which cascades down to Cargo dependency resolution failures. + # This step is helpful to prevent messing with different checksums being produced on the same semver - name: Preprocess Cargo.toml working-directory: jfrog_quotes run: | - pwd - ls - build_number=${{ github.run_number }} - sed -i "s/^version = \"0.1.dev\"/version = \"0.1.${build_number}\"/" Cargo.toml + build_number=${{ github.run_number }} + sed -i "s/^version = \"0.1.dev\"/version = \"0.1.${build_number}\"/" Cargo.toml - name: Build Library working-directory: jfrog_quotes From e314ab30fd33a3a1f04c0ea3013717a1e909d6f9 Mon Sep 17 00:00:00 2001 From: tomjfrog Date: Wed, 12 Jun 2024 12:46:45 -0500 Subject: [PATCH 06/12] Triage 3 --- .github/workflows/rust-example-library.yaml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/rust-example-library.yaml b/.github/workflows/rust-example-library.yaml index c99d910..64528b1 100644 --- a/.github/workflows/rust-example-library.yaml +++ b/.github/workflows/rust-example-library.yaml @@ -15,6 +15,9 @@ jobs: uses: actions/checkout@v4 - name: Validate Cargo installation run: cargo --version + - name: triage + run: | + pwd # This step is helpful to prevent messing with different checksums being produced on the same semver - name: Preprocess Cargo.toml From ba240e4a6ec5b1bf85e988a768466025af908c88 Mon Sep 17 00:00:00 2001 From: tomjfrog Date: Wed, 12 Jun 2024 12:47:55 -0500 Subject: [PATCH 07/12] Triage 4 --- .github/workflows/rust-example-library.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/rust-example-library.yaml b/.github/workflows/rust-example-library.yaml index 64528b1..193e746 100644 --- a/.github/workflows/rust-example-library.yaml +++ b/.github/workflows/rust-example-library.yaml @@ -21,7 +21,7 @@ jobs: # This step is helpful to prevent messing with different checksums being produced on the same semver - name: Preprocess Cargo.toml - working-directory: jfrog_quotes + working-directory: ./rust/jfrog_quotes run: | build_number=${{ github.run_number }} sed -i "s/^version = \"0.1.dev\"/version = \"0.1.${build_number}\"/" Cargo.toml From 24c175e9a1d6ed46bc57dcf1b8b566923c4b9644 Mon Sep 17 00:00:00 2001 From: tomjfrog Date: Wed, 12 Jun 2024 12:49:15 -0500 Subject: [PATCH 08/12] Set working-directory on entire job --- .github/workflows/rust-example-library.yaml | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/.github/workflows/rust-example-library.yaml b/.github/workflows/rust-example-library.yaml index 193e746..ecb7445 100644 --- a/.github/workflows/rust-example-library.yaml +++ b/.github/workflows/rust-example-library.yaml @@ -10,6 +10,7 @@ env: jobs: build-and-publish: runs-on: ubuntu-latest + working-directory: ./rust/jfrog_quotes steps: - name: Checkout uses: actions/checkout@v4 @@ -21,15 +22,12 @@ jobs: # This step is helpful to prevent messing with different checksums being produced on the same semver - name: Preprocess Cargo.toml - working-directory: ./rust/jfrog_quotes run: | build_number=${{ github.run_number }} sed -i "s/^version = \"0.1.dev\"/version = \"0.1.${build_number}\"/" Cargo.toml - name: Build Library - working-directory: jfrog_quotes run: cargo build --release --verbose - name: Publish Library To Artifactory - working-directory: jfrog_quotes run: cargo publish --allow-dirty --token "Bearer ${{ secrets.RUST_EXAMPLE_AUTHENTICATION_TOKEN }}" \ No newline at end of file From cf3244f4baf4e582e9c56ca45a77d80c0c1df6e5 Mon Sep 17 00:00:00 2001 From: tomjfrog Date: Wed, 12 Jun 2024 12:51:27 -0500 Subject: [PATCH 09/12] Set working-directory on entire job 2 --- .github/workflows/rust-example-library.yaml | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/.github/workflows/rust-example-library.yaml b/.github/workflows/rust-example-library.yaml index ecb7445..b109a55 100644 --- a/.github/workflows/rust-example-library.yaml +++ b/.github/workflows/rust-example-library.yaml @@ -7,10 +7,14 @@ env: CARGO_REGISTRIES_INNERSOURCE_TOKEN: ${{ secrets.RUST_EXAMPLE_AUTHENTICATION_TOKEN }} CARGO_REGISTRIES_JFROGQUOTES_TOKEN: ${{ secrets.RUST_EXAMPLE_AUTHENTICATION_TOKEN }} +defaults: + run: + shell: bash + working-directory: ./rust/jfrog_quotes + jobs: build-and-publish: runs-on: ubuntu-latest - working-directory: ./rust/jfrog_quotes steps: - name: Checkout uses: actions/checkout@v4 From a369fa7858543c4cdcb9dec24c10a9fe7fbd9878 Mon Sep 17 00:00:00 2001 From: tomjfrog Date: Wed, 12 Jun 2024 13:00:05 -0500 Subject: [PATCH 10/12] Small updates to Actions specs & added a few comments. --- .github/workflows/rust-example-app.yaml | 8 ++++++++ .github/workflows/rust-example-library.yaml | 6 ++---- rust/jfrog_app/Cargo.toml | 2 +- 3 files changed, 11 insertions(+), 5 deletions(-) diff --git a/.github/workflows/rust-example-app.yaml b/.github/workflows/rust-example-app.yaml index d854f33..ee80ea0 100644 --- a/.github/workflows/rust-example-app.yaml +++ b/.github/workflows/rust-example-app.yaml @@ -7,6 +7,14 @@ env: CARGO_REGISTRIES_INNERSOURCE_TOKEN: ${{ secrets.RUST_EXAMPLE_AUTHENTICATION_TOKEN }} CARGO_REGISTRIES_JFROGQUOTES_TOKEN: ${{ secrets.RUST_EXAMPLE_AUTHENTICATION_TOKEN }} +# The default working-directory is needed, due to all example Actions specs residing in the same directory, but each +# package example code is in different directories. This `default` config saves us the effort of setting a +# `working-directory` on each step. +defaults: + run: + shell: bash + working-directory: ./rust/jfrog_quotes + jobs: build-and-publish: runs-on: ubuntu-latest diff --git a/.github/workflows/rust-example-library.yaml b/.github/workflows/rust-example-library.yaml index b109a55..440187a 100644 --- a/.github/workflows/rust-example-library.yaml +++ b/.github/workflows/rust-example-library.yaml @@ -20,11 +20,9 @@ jobs: uses: actions/checkout@v4 - name: Validate Cargo installation run: cargo --version - - name: triage - run: | - pwd - # This step is helpful to prevent messing with different checksums being produced on the same semver + # This step is helpful to prevent messing with different library binary checksums being produced on the same semantic version + # Cargo doesn't accommodate dynamic values to be passed in to Cargo.toml, so we have to use `sed` instead. - name: Preprocess Cargo.toml run: | build_number=${{ github.run_number }} diff --git a/rust/jfrog_app/Cargo.toml b/rust/jfrog_app/Cargo.toml index 09f683e..ab99779 100644 --- a/rust/jfrog_app/Cargo.toml +++ b/rust/jfrog_app/Cargo.toml @@ -6,7 +6,7 @@ edition = "2021" # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html [dependencies] -jfrog_quotes = { version = "0.1.0", registry = "innersource" } +jfrog_quotes = { version = "0.1.7", registry = "innersource" } From 93e92847b918debf119b6ac885a4d76b51298181 Mon Sep 17 00:00:00 2001 From: tomjfrog Date: Wed, 12 Jun 2024 13:01:40 -0500 Subject: [PATCH 11/12] Comment on defaults for rust-example-library.yaml --- .github/workflows/rust-example-app.yaml | 4 +--- .github/workflows/rust-example-library.yaml | 3 +++ 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/.github/workflows/rust-example-app.yaml b/.github/workflows/rust-example-app.yaml index ee80ea0..c9e48bf 100644 --- a/.github/workflows/rust-example-app.yaml +++ b/.github/workflows/rust-example-app.yaml @@ -13,7 +13,7 @@ env: defaults: run: shell: bash - working-directory: ./rust/jfrog_quotes + working-directory: ./rust/jfrog_app jobs: build-and-publish: @@ -25,9 +25,7 @@ jobs: run: cargo --version - name: Build Application - working-directory: jfrog_app run: cargo build --release --verbose - name: Publish Application To Artifactory - working-directory: jfrog_app run: cargo publish --token "Bearer ${{ secrets.RUST_EXAMPLE_AUTHENTICATION_TOKEN }}" \ No newline at end of file diff --git a/.github/workflows/rust-example-library.yaml b/.github/workflows/rust-example-library.yaml index 440187a..48f9e91 100644 --- a/.github/workflows/rust-example-library.yaml +++ b/.github/workflows/rust-example-library.yaml @@ -7,6 +7,9 @@ env: CARGO_REGISTRIES_INNERSOURCE_TOKEN: ${{ secrets.RUST_EXAMPLE_AUTHENTICATION_TOKEN }} CARGO_REGISTRIES_JFROGQUOTES_TOKEN: ${{ secrets.RUST_EXAMPLE_AUTHENTICATION_TOKEN }} +# The default working-directory is needed, due to all example Actions specs residing in the same directory, but each +# package example code is in different directories. This `default` config saves us the effort of setting a +# `working-directory` on each step. defaults: run: shell: bash From d5695d7b9954bfd9a12be9a9fbcd4b22893af67f Mon Sep 17 00:00:00 2001 From: tomjfrog Date: Wed, 19 Jun 2024 15:08:34 -0700 Subject: [PATCH 12/12] Working on README.md --- .github/workflows/rust-example-app.yaml | 5 +++ rust/README.md | 55 ++++++++++++++++++++++--- rust/jfrog_quotes/.cargo/config.toml | 4 +- 3 files changed, 56 insertions(+), 8 deletions(-) diff --git a/.github/workflows/rust-example-app.yaml b/.github/workflows/rust-example-app.yaml index c9e48bf..379545b 100644 --- a/.github/workflows/rust-example-app.yaml +++ b/.github/workflows/rust-example-app.yaml @@ -24,6 +24,11 @@ jobs: - name: Validate Cargo installation run: cargo --version + - name: Preprocess Cargo.toml + run: | + base_url=${{ vars.RUST_EXAMPLE_CARGO_BASE_URL }} + sed -i "s/^version = \"0.1.dev\"/version = \"0.1.${base_url}\"/" config.toml + - name: Build Application run: cargo build --release --verbose diff --git a/rust/README.md b/rust/README.md index c847af0..7de52c3 100644 --- a/rust/README.md +++ b/rust/README.md @@ -1,26 +1,52 @@ # Rust and Cargo with Integration With Artifactory # Cargo Package Manager Integration with Artifactory -A repo to demonstrate Rust's package manager, Cargo, and how it integrates with Artifactory. +This is a small repo to demonstrate Rust's package manager, Cargo, and how it integrates with Artifactory. # Project Goal The two Rust projects in this folder will demonstrate the basics of integrating Rust's package manager, Cargo, with Jfrog's Artifactory. # Project Structure -This repo will hold two projects: an [Inner Source](https://en.wikipedia.org/wiki/Inner_source) library, to be built and published with Artifactory's Cargo -integration, and a "Production" application that will incorporate the library. +This repo will hold two projects: an [Inner Source](https://en.wikipedia.org/wiki/Inner_source) library, to be built and published with Artifactory's Cargo integration, and a "Production" application that will incorporate the library. ## Inner Source Library -A simple library that will return a randomly-selected quote about JFrog, The Secure Software Supply Chain experts. +This is a simple library that will return a randomly-selected quote about JFrog, The Secure Software Supply Chain +experts. ## Production Application -A basic Rust application that will incorporate the Inner Source library. +A basic Rust application that will incorporate the Inner Source library. Upon execution, it will print out a +randomly selected quote to the console. ## Pre Reqs (Local Build) 1. Install Cargo 2. Configure Cargo -3. Setup `~/.cargo/credentials`. Note, if you use a credentials file, DO NOT check this into Version Control +3. Create three repositories in an instance of Artifactory: One remote repository that proxies `crates.io`, one + local repository to host the "innersource" library and one local repository to host the actual application binary. +4. Using these repositories edit the two Cargo config files as follows: +`jfrog_app/.cargo/config.toml`: This file will take the "innersource" library local repo and +```toml +[registry] +default = "jfrogquotes" + +[registries.jfrogquotes] +index = "sparse+https://tomjfrog.jfrog.io/artifactory/api/cargo/jfrogquotes-cargo-local/index/" + +[registries.innersource] +index = "sparse+https://tomjfrog.jfrog.io/artifactory/api/cargo/innersource-cargo-local/index/" +``` +`jfrog_quotes/.cargo/config.toml` +```toml +[registry] +default = "innersource" + +[registries.innersource] +index = "sparse+https://BASE_URL/artifactory/api/cargo/innersource-cargo-local/index/" + +[registries.crates-remote] +index = "sparse+https://BASE_URL/artifactory/api/cargo/crates-remote/index/" +``` +5. Setup `~/.cargo/credentials`. Note, if you use a credentials file, DO NOT check this into Version Control ```toml [registries.artifactory] token = "Bearer " @@ -37,7 +63,16 @@ export CARGO_REGISTRIES_FOO_TOKEN="Bearer bar" ## Cargo configuration TODO: Provide details on the library's `Cargo.toml`, esp around where to resolve external dependencies ## Steps to build and publish the innersource library, `jfrog_quotes` + ### Build the Library +To build the library, first run a local build. Enter the root of the `rust` example and execute `cargo build +--release`. + +> Note: The first time this is run, a file called `Cargo.lock` will be generated. It's important to commit this +> to version control. The version of the library in the remote Cargo remote, hosted in Artifactory, will be pinned +> to a specific SHA associated with the version. By checking in the Cargo.lock, it will ensure that the correct SHA +> will always be used. + ```bash cd rust/jfrog_quotes cargo build --release @@ -47,3 +82,11 @@ cargo build --release cargo publish --registry innersource ``` +## Advanced Use-Case: Execute build and deploy in Github Actions +Github Actions, one of the most popular CI tools on the market today, has native support for Cargo in it's hosted +runners. The example here has two Github Actions specs: building the library and building the application. Follow +these steps to get this use-case implemented. + +### Add Repository Variable for JFrog URL + + diff --git a/rust/jfrog_quotes/.cargo/config.toml b/rust/jfrog_quotes/.cargo/config.toml index db4dfe3..5e19a2a 100644 --- a/rust/jfrog_quotes/.cargo/config.toml +++ b/rust/jfrog_quotes/.cargo/config.toml @@ -3,7 +3,7 @@ default = "innersource" [registries.innersource] -index = "sparse+https://tomjfrog.jfrog.io/artifactory/api/cargo/innersource-cargo-local/index/" +index = "sparse+https://BASE_URL/artifactory/api/cargo/innersource-cargo-local/index/" [registries.crates-remote] -index = "sparse+https://tomjfrog.jfrog.io/artifactory/api/cargo/crates-remote/index/" +index = "sparse+https://BASE_URL/artifactory/api/cargo/crates-remote/index/"