Takayoshi Tanaka

Takayoshi Tanaka is the Software Maintenance Engineer of Red Hat. He is mainly in charge of OpenShift, .NET Core on Red Hat Enterprise Linux and Red Hat solutions on Microsoft Azure. He is a Microsoft MVP for Visual Studio and Development Technologies. He writes many articles in his personal blog and web sites, and also he gives many technical session in community events.

Recent Posts

Remote debug your ASP.NET Core container on OpenShift with Visual Studio Code

Visual Studio provides a graphical remote debugging ASP.NET Core app with Docker Tools for Windows. Since Visual Studio supports SSH protocol, you can remote debug ASP.NET Core process running on the Linux host. It used to be if you install and setup SSH server on docker container, you can remote debug with Visual Studio. However, it’s strongly not recommended due to security reasons. Now I’ll explain to you how to remote debug your ASP.NET Core on OpenShift with Visual Studio Code by using oc exec command instead of installing SSH server on docker container. You can use Microsoft proprietary debugger engine vsdbg with Visual Studio Code (or other Visual Studio products). Visual Studio Code can integrate other commands than SSH for debugger transport protocol.

Continue reading “Remote debug your ASP.NET Core container on OpenShift with Visual Studio Code”

Share

Running a NuGet server on OpenShift

When you build your .NET Core project, NuGet packages are retrieved from nuget.org by default. Sometimes, however, you might want to use a local NuGet repository. For example, you may want to:

  • use private NuGet packages, but you don’t want anyone except your associates to see them.
  • cache a NuGet repository at a server near your build servers
  • leave your build server disconnected from the Internet.

I’ll explain how to set up a private NuGet server on OpenShift and how you can use this NuGet server when building your .NET Core project in OpenShift using s2i-dotnetcore.

Continue reading “Running a NuGet server on OpenShift”

Share

Welcome to Red Hat Enterprise Linux, MSBuild, a build tool for .NET Core CLI!

Microsoft announced the first “alpha” release of the new MSBuild-based .NET Core tools. .NET Core SDK which can be downloaded from the Red Hat Developer Program site consists of .NET Core Runtime and .NET Core command line tools (.NET Core CLI). (Reminder – you must have a Red Hat Enterprise Linux subscription first.  If you don’t, you can go here for a no-cost subscription.) The MSBuild tool is included in .NET Core 1.0 preview 3 (not in the latest release .NET Core 1.1). The version number is something complicated because .NET CLI is not GA but still under preview. The MSBuild tool can be used with both .NET Core 1.0 and .NET Core 1.1 runtimes. RHEL is not listed in the .NET Core SDK 1.0 Preview 3 download list. But you can try MSBuild with the .NET Core CLI daily build.

NOTE: Red Hat has just released .NET Core 1.1. However, .NET Core 1.1 doesn’t include the MSBuild tool, you can try MSBuild following this blog.

Continue reading “Welcome to Red Hat Enterprise Linux, MSBuild, a build tool for .NET Core CLI!”

Share

Getting Started with Microsoft SQL Server on Red Hat Enterprise Linux

Microsoft announced SQL Server on Linux public preview, so now you can try SQL Server on your Red Hat Enterprise Linux server. I’ll describe how to start SQL Server on RHEL.

Install and connect with CLI on RHEL

Microsoft publishes a step-by-step document how to Install SQL Server on Red Hat Enterprise Linux. It’s only 7 steps to install and run.

# systemctl status mssql-server
● mssql-server.service - Microsoft(R) SQL Server(R) Database Engine
   Loaded: loaded (/usr/lib/systemd/system/mssql-server.service; enabled; vendor preset: disabled)
   Active: active (running) since Wed 2016-11-16 20:59:33 EST; 1 weeks 1 days ago
 Main PID: 77982 (sqlservr)
   Memory: 753.6M
   CGroup: /system.slice/mssql-server.service
           ├─77982 /opt/mssql/bin/sqlservr
           └─77997 /opt/mssql/bin/sqlservr

Now you can connect to SQL Server on RHEL. At first, let’s connect with sqlcmd. You should have to install SQL Server tools even if you run sqlcmd on the same host as you installed mssql-server package with following the document. First connect to local SQL Server instance.

Continue reading “Getting Started with Microsoft SQL Server on Red Hat Enterprise Linux”

Share

Working with OpenShift secrets for ASP.NET Core

If you want to use secret configuration which you don’t want to store the code repository during developing ASP.NET Core app, what will you do? ASP.NET Core provides Secret Manager tool. Then how about developing on OpenShift? I’d like to talk about Secret Manager tool and working OpenShift secrets for ASP.NET Core in this blog.

Continue reading “Working with OpenShift secrets for ASP.NET Core”

Share

P/Invoke in .NET Core on Red Hat Enterprise Linux

P/Invoke(Platform Invocation Service) is one of the features of CLI (Common Language Interface) on .NET Framework. P/Invoke enables managed code to call a native function in DLL (Dynamic Link Library). It’s a powerful tool for .NET Framework to execute existing C-style functions easily. .NET Core also has a P/Invoke feature and it means we can call a native function in .so file (Linux) and . file (Max OSX). I will show you the short example P/Invoke in .NET Core on Red Hat Enterprise Linux (RHEL).

Here is the simple P/Invoke sample using read function in libc. It is the same way as .NET Framework on Windows to import native function.

Continue reading “P/Invoke in .NET Core on Red Hat Enterprise Linux”

Share