openfaas / templates

OpenFaaS Classic templates
https://www.openfaas.com
MIT License
276 stars 228 forks source link

Dotnet template naming and dotnet core 2.2 and 3.0 templates #176

Closed csakshaug closed 3 years ago

csakshaug commented 4 years ago

We need the option to select 2.2 and 3.0 dotnet core template. We also need to address the naming for these templates. I think using "csharp" as template name is misleading.

burtonr commented 4 years ago

Hi @csakshaug Thanks for the suggestion, and the 2 PRs.

I disagree with the naming being misleading. "csharp" is the language, and the templates are for a language. "dotnet" is the framework the language uses. Changing the template to "dotnet" would be misleading in users thinking that they would also be able to use VB.NET, F#, and other .NET languages without any changes which is not true.

I think that .NET Core is implied where .NET Framework would be the exception. So the csharp template names need not explicitly declare that they are "dotnet core".

I would agree to adding the version of dotnet core to the end of the template name similar to the Java and Node templates.

csakshaug commented 4 years ago

Hi @csakshaug Thanks for the suggestion, and the 2 PRs.

I disagree with the naming being misleading. "csharp" is the language, and the templates are for a language. "dotnet" is the framework the language uses. Changing the template to "dotnet" would be misleading in users thinking that they would also be able to use VB.NET, F#, and other .NET languages without any changes which is not true.

I think that .NET Core is implied where .NET Framework would be the exception. So the csharp template names need not explicitly declare that they are "dotnet core".

If we continue to use "csharp" and not dotnet/netcore we could perhaps do it something like this: csharp30 / csharp22 / csharp22-http / csharp-netcore30 / csharpnetcore22 / csharp-netstandard20 / csharpnetstandard20 / csharp-netstandard20-http.

About the current csharp I think it has multiple problems. It combines both dotnet standard and dotnet core. The dockerfile right now is not building, and it looks like it stops step 13 (see bottom)


 ---> Running in 7091887398fa
chmod: changing permissions of '/usr/bin/fwatchdog': Operation not permitted
The command '/bin/sh -c chmod +x /usr/bin/fwatchdog' returned a non-zero code: 1```