Skip to content

Using --jsonfile switch of dotnet-install.sh fails with some roll forward policy #71

Closed
@atifaziz

Description

@atifaziz

I have a project with the following global.json:

{
  "sdk": {
    "version": "3.1.101",
    "rollForward": "latestFeature"
  }
}

Using dotnet-install.sh with the --jsonfile option produces an invalid download URL of the form: https://dotnetcli.azureedge.net/dotnet/Sdk/3.1.101rollForward:latestFeature/dotnet-sdk-3.1.101rollForward:latestFeature-linux-musl-x64.tar.gz

The problem is the 3.1.101rollForward:latestFeature path component of the URL.

Steps to reproduce in a Docker container running Alpine Linux 3.9:

❯ docker run --rm -it alpine:3.9
/ # apk add --no-cache -q bash
/ # wget -q https://dot.net/v1/dotnet-install.sh
/ # chmod +x dotnet-install.sh
/ # cat > global.json <<EOF
> {
>   "sdk": {
>     "version": "3.1.101",
>     "rollForward": "latestFeature"
>   }
> }
> EOF
/ # ./dotnet-install.sh --jsonfile global.json --dry-run
dotnet-install: Payload URLs:
dotnet-install: Primary named payload URL: https://dotnetcli.azureedge.net/dotnet/Sdk/3.1.101rollForward:latestFeature/dotnet-sdk-3.1.101rollForward:latestFeature-linux-musl-x64.tar.gz
dotnet-install: Repeatable invocation: ./dotnet-install.sh --version "3.1.101rollForward:latestFeature" --install-dir "/root/.dotnet" --architecture "x64"

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions