File tree 8 files changed +30
-4
lines changed
test/asp-net-hello-world-envvar
test/asp-net-hello-world-envvar
8 files changed +30
-4
lines changed Original file line number Diff line number Diff line change @@ -107,6 +107,11 @@ a `.s2i/environment` file inside your source code repository.
107
107
- the application sources to be in subfolder `DOTNET_ASSEMBLY_NAME` in the deployed
108
108
container.
109
109
110
+ * **DOTNET_RESTORE_SOURCES**
111
+
112
+ Used to specify the list of NuGet package sources used during the restore operation. This overrides
113
+ all of the sources specified in the NuGet.config file.
114
+
110
115
* **DOTNET_NPM_TOOLS**
111
116
112
117
Used to specify a list of npm packages to install before building the app.
Original file line number Diff line number Diff line change 33
33
APP_DLL_NAME=" $( basename " $( realpath " ${DOTNET_STARTUP_PROJECT} " ) " ) .dll"
34
34
fi
35
35
36
+ # Build nuget sources list for when doing the restore
37
+ RESTORE_OPTIONS=" "
38
+ for SOURCE in $DOTNET_RESTORE_SOURCES ; do
39
+ RESTORE_OPTIONS=" $RESTORE_OPTIONS --source $SOURCE "
40
+ done
41
+
36
42
echo " ---> Installing dependencies ..."
37
- dotnet restore
43
+ dotnet restore $RESTORE_OPTIONS
38
44
39
45
# The publish operation fails when .NET framework targets are included in project.json
40
46
# See https://github.com/dotnet/cli/issues/3636
Original file line number Diff line number Diff line change 1
1
DOTNET_STARTUP_PROJECT=src/app
2
2
DOTNET_CONFIGURATION=Debug
3
3
DOTNET_TEST_PROJECTS=test/test1 test/test2
4
- DOTNET_ASSEMBLY_NAME=SampleApp
4
+ DOTNET_ASSEMBLY_NAME=SampleApp
5
+ DOTNET_RESTORE_SOURCES=https://api.nuget.org/v3/index.json https://www.myget.org/F/s2i-dotnetcore
Original file line number Diff line number Diff line change 5
5
"Microsoft.AspNetCore.Server.Kestrel" : " 1.0.0" ,
6
6
"Microsoft.Extensions.Logging.Console" : " 1.0.0" ,
7
7
"Microsoft.AspNetCore.StaticFiles" : " 1.0.0" ,
8
+ "S2iDotNetCoreDummy" : " 1.0.1" ,
8
9
"lib" : " 1.0.0-*"
9
10
},
10
11
"buildOptions" : {
Original file line number Diff line number Diff line change @@ -107,6 +107,11 @@ a `.s2i/environment` file inside your source code repository.
107
107
- the application sources to be in subfolder `DOTNET_ASSEMBLY_NAME` in the deployed
108
108
container.
109
109
110
+ * **DOTNET_RESTORE_SOURCES**
111
+
112
+ Used to specify the list of NuGet package sources used during the restore operation. This overrides
113
+ all of the sources specified in the NuGet.config file.
114
+
110
115
* **DOTNET_NPM_TOOLS**
111
116
112
117
Used to specify a list of npm packages to install before building the app.
Original file line number Diff line number Diff line change 33
33
APP_DLL_NAME=" $( basename " $( realpath " ${DOTNET_STARTUP_PROJECT} " ) " ) .dll"
34
34
fi
35
35
36
+ # Build nuget sources list for when doing the restore
37
+ RESTORE_OPTIONS=" "
38
+ for SOURCE in $DOTNET_RESTORE_SOURCES ; do
39
+ RESTORE_OPTIONS=" $RESTORE_OPTIONS --source $SOURCE "
40
+ done
41
+
36
42
echo " ---> Installing dependencies ..."
37
- dotnet restore
43
+ dotnet restore $RESTORE_OPTIONS
38
44
39
45
# The publish operation fails when .NET framework targets are included in project.json
40
46
# See https://github.com/dotnet/cli/issues/3636
Original file line number Diff line number Diff line change 1
1
DOTNET_STARTUP_PROJECT=src/app
2
2
DOTNET_CONFIGURATION=Debug
3
3
DOTNET_TEST_PROJECTS=test/test1 test/test2
4
- DOTNET_ASSEMBLY_NAME=SampleApp
4
+ DOTNET_ASSEMBLY_NAME=SampleApp
5
+ DOTNET_RESTORE_SOURCES=https://api.nuget.org/v3/index.json https://www.myget.org/F/s2i-dotnetcore
Original file line number Diff line number Diff line change 5
5
"Microsoft.AspNetCore.Server.Kestrel" : " 1.1.0" ,
6
6
"Microsoft.Extensions.Logging.Console" : " 1.1.0" ,
7
7
"Microsoft.AspNetCore.StaticFiles" : " 1.1.0" ,
8
+ "S2iDotNetCoreDummy" : " 1.0.1" ,
8
9
"lib" : " 1.0.0-*"
9
10
},
10
11
"buildOptions" : {
You can’t perform that action at this time.
0 commit comments