Using DotNet Core comes some responsibilities, one of those is making sure your application is up and running.
Since DotNet Core 2.2 the introductions of health checks have been established.
There are two types of Health Checks
Continue reading Health Checks
- Liveness Health Checks
- Readiness Health Checks
Recently I was playing with docker API on OSX to use with Jenkins and the setup was little complicated so I thought to put all steps together in one place. Just to summarise the default tcp port for docker is 2375 (unencrypted) and 2376(encrypted) communication over tcp(although we can choose any other port).
Continue reading Enabling docker remote API on OSX
Original files from: snyk
Quick and easy way to setup an SMTP mail server using docker
docker run --restart unless-stopped --name mailhog -p 1025:1025 -p 8025:8025 -d mailhog/mailhog
We love Jenkins and we love Docker, so let’s get them working together.
We are assuming you already have Docker installed on your environment.
Continue reading Jenkins in Docker
Here is the terminal command to use:
Many of today’s website is designed around giving a good user experience. This comes at a cost of high-bandwidth. Not everyone in the world will have a good internet connection, how about when you are at sea on a ship or in a developing country such as India or Pakistan.
Continue reading Low-Bandwidth website
Here is a working example of a simple Docker file for a .NET Core 3.1 project
FROM mcr.microsoft.com/dotnet/core/sdk:3.1 AS build-env
COPY project.csproj ./
RUN dotnet restore
COPY . ./
RUN dotnet publish -c Release -o out
COPY --from=build-env /app/out .
ENTRYPOINT ["dotnet", "project.dll"]
Build an image from the Dockerfile in the current directory and tag the image
docker build -t myimage -f Dockerfile .
List all images that are locally stored with the Docker Engine
docker ps -a
Delete an image from the local image store
docker image rm CONTAINER_NAME
You may want to remove all orphaned images, you can do this with dandling field
Continue reading Docker cribsheet
docker rmi $(docker images -f dangling=true -q)
What Are Containers?
Containers are a form of operating system virtualization. A single container might be used to run anything from a small microservice or software process to a larger application. Inside a container are all the necessary executables, binary code, libraries, and configuration files. Compared to server or machine virtualization approaches, however, containers do not contain operating system images. This makes them more lightweight and portable, with significantly less overhead. In larger application deployments, multiple containers may be deployed as one or more container clusters. Such clusters might be managed by a container orchestrator such as Kubernetes.
Continue reading Benefits of Containers
Working with a good technical architecture you’ll soon need to work with an API Gateway. There are many industrial solutions for large scale system giving full control and logging, such as Apigee or Software AG, but these, of course, cost a business
In this article, I’ll look at possible homegrown API’s within ASP.NET Core, which give you a lot of features without the need to pay third parties.
Continue reading API Gateway in ASP.NET Core