-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
- Loading branch information
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,87 @@ | ||
# Multiple Shared Framework Installations in Arcade | ||
|
||
## Proposal | ||
|
||
- define frameworks in global.json | ||
- no generated props file or use of a `DotNetCoreRuntimeVersions` item group | ||
- if runtimes section is present, assume we can't fulfill the specs globally and force use of `.dotnet` folder | ||
|
||
Notes: This will require updating darc to support the format change - https://github.com/dotnet/arcade-services/commit/9a486718cdb33c82f9bb24cf25d1207e364f71c7 | ||
|
||
## Scenario 1 - Fixed set of shared frameworks for testing | ||
|
||
global.json | ||
|
||
```json | ||
{ | ||
"tools": { | ||
"dotnet": { | ||
"sdk": "2.2.202", | ||
"runtimes": { | ||
"dotnet": [ "2.1.1" ], | ||
"aspnetcore": [ "2.2.3" ] | ||
} | ||
} | ||
}, | ||
This comment has been minimized.
Sorry, something went wrong.
This comment has been minimized.
Sorry, something went wrong.
chcosta
Author
Owner
|
||
"msbuild-sdks": { | ||
"Microsoft.DotNet.Arcade.Sdk": "1.0.0-beta.19207.1", | ||
"Microsoft.DotNet.Helix.Sdk": "2.0.0-beta.19207.1" | ||
} | ||
} | ||
``` | ||
|
||
Define frameworks (runtimes) in global.json. | ||
|
||
Applies to: | ||
|
||
- repos with a fixed set of shared frameworks used for testing | ||
|
||
Behavior: | ||
|
||
- SDK is installed locally (into `.dotnet` folder) | ||
This comment has been minimized.
Sorry, something went wrong.
natemcmaster
|
||
- Frameworks are installed locally (into `.dotnet` folder) | ||
- We print a message during install indicating that location of the installed sdk / frameworks | ||
|
||
## Scenario 2 - Dependency flow defined versions of shared frameworks for testing | ||
|
||
global.json | ||
|
||
```json | ||
{ | ||
"tools": { | ||
"dotnet": { | ||
"sdk": "2.2.202", | ||
"runtimes": { | ||
"dotnet": [ "2.1.1", "MicrosoftNetCoreAppVersion" ], | ||
This comment has been minimized.
Sorry, something went wrong.
natemcmaster
|
||
"aspnetcore": [ "2.2.3", "MicrosoftAspNetCoreAppVersion" ] | ||
} | ||
}, | ||
"msbuild-sdks": { | ||
"Microsoft.DotNet.Arcade.Sdk": "1.0.0-beta.19207.1", | ||
"Microsoft.DotNet.Helix.Sdk": "2.0.0-beta.19207.1" | ||
} | ||
} | ||
``` | ||
|
||
eng/Versions.props | ||
|
||
```XML | ||
<Project> | ||
<PropertyGroup> | ||
<MicrosoftNetCoreAppVersion>3.0.0-preview4-19207.1</MicrosoftNetCoreAppVersion> | ||
<MicrosoftAspNetCoreAppVersion>3.0.0-preview4-19207.1</MicrosoftAspNetCoreAppVersion> | ||
... | ||
</PropertyGroup> | ||
</Project> | ||
``` | ||
|
||
Applies to: | ||
|
||
- repos which rely on dependency flow for defining framework versions | ||
|
||
Behavior: | ||
|
||
- SDK is installed locally (into `.dotnet` folder) | ||
- Frameworks are installed locally (into `.dotnet` folder) | ||
- For non-explicit framework versions, we read in eng/Version.props and translate identified property group values into versions | ||
- We print a message during install indicating that location of the installed sdk / frameworks |
@natemcmaster
I think the parsing here may get a little tricky. The reason, today, that we have
"dotnet": "[version]"
is because we have to be able to reasonably parse this ineng/common/tools.sh
If we change the format and have a "typical" Arcade repo global.json...
... then we can reasonably parse
sdk
and get the version.If there's a repo that defines both a standard "sdk.version" and / or a "dotnet sdk" version, then I can imagine that our parsing logic could be easily tripped up.
Perhaps, in some ways that scenario is busted and we should let things fall apart or maybe we can catch the bad condition and ignore it so that we continue parsing. That may get overly complicated.
Practically speaking, we can either try to get cuter with the sdk version parsing, or change the format to something like
... which is basically what we have today but with "runtimes" added. It's not as ideal, but simplifies a bit (less changes here and no changes to darc are required).