• Stars
    star
    167
  • Rank 226,635 (Top 5 %)
  • Language
    C#
  • Created almost 7 years ago
  • Updated almost 7 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Sample project for getting off the ground with ASP.NET Core, Docker and Microservices based on the tutorial: https://fullstackmark.com/post/12/get-started-building-microservices-with-asp.net-core-and-docker-in-visual-studio-code

ASPNETCoreDockerMicroservices

Sample project for getting off the ground with ASP.NET Core, Docker and Microservices based on the tutorial: https://fullstackmark.com/post/12/get-started-building-microservices-with-asp.net-core-and-docker-in-visual-studio-code

This repo contains the demo project used as the subject for a blog post I did on getting started with ASP.NET Core-based microservices and Docker. If you just want to run the project please follow instructions below. If you'd like to learn more on how it was built please check out this detailed guide on my blog.

Environment

It should be fairly cross-platform friendly to get up and running but was developed on my windows 10 machine along with the following:

  • Windows 10 and PowerShell
  • Visual Studio Code - v1.19.0
    • C# for Visual Studio Code extension
    • Docker extension
  • SQL Server Management Studio 17.4
  • .NET Core SDK v2.0.0
  • Docker Community Edition 17.09.1-ce-win42 using Linux containers

Setup

  1. Download/clone repo.

  2. From the root folder (where docker-compose.yml resides) use the Docker CLI to build and start the containers for the solution: PS> docker-compose up -d. This step will take a few minutes or more as all the base images must be downloaded. When it completes you can check that all 7 containers for the solution have been built and started successfully by running PS> docker ps. Alt Additionally, you can connect to the Sql Server on Linux instance in the container using SQL Server Management Studio to ensure the databases dotnetgigs.applicants and dotnetgigs.jobs were created. The server name is: localhost,5433 with username sa and password Pass@word.

  3. At this point, you can run and debug the solution from Visual Studio Code. Simply open the root folder in VSCode and start all projects in the solution simultaneously using the All Projects configuration or start them individually. The order they're started does not matter. Alt

  4. With all services running in the debugger you can hit the web app in your browser at localhost:8080 and set breakpoints in any of the projects to debug directly.

Known Issues

When running on windows ensure the line ending type for the Database/SqlCmdStartup.sh remains as LF. When opening/saving this file in VSCode it can get switched to CRLF in which case the script won't run and the required databases never get created. If the databases aren't created check PS> docker logs mssql-linux and the presence of an error at the top such as sleep: invalid time interval '25\r'.

I have also noticed, on first run of newly created containers that when starting services that use Rabbit a connection exception will be thrown when starting the project in the debugger for the first time. Start it again and things seem to work fine from then on.

More Repositories

1

devfolio

A simple, responsive, single-page portfolio and resume for developers built with Bulma, Sass, Font Awesome and Flickity.
JavaScript
505
star
2

CleanAspNetCoreWebApi

Starter project for creating APIs built on ASP.NET Core using clean architecture.
C#
475
star
3

AngularASPNETCore2WebApiAuth

Sample project demonstrating jwt-based authentication with an Angular (v5.2.1) frontend and ASP.NET Core 2 WebApi. Includes both local user registration with .NET Core Identity membership and facebook login scenarios.
C#
472
star
4

AngularASPNETCoreOAuth

Sample project demonstrating user authentication and identity with Angular, Asp.Net Core and IdentityServer4
C#
354
star
5

AspNetCoreApiStarter

An ASP.NET Core (v2.1) Web API project to quickly bootstrap new projects. Includes Identity, JWT authentication w/ refresh tokens.
C#
354
star
6

ASPNetCoreGraphQL

Sample project demonstrating a GraphQL service built with ASP.NET Core 2.2, Entity Framework Core and graphql-dotnet.
C#
267
star
7

CleanArchitecture

Example from a post exploring CleanArchitecture: https://fullstackmark.com/post/11/better-software-design-with-clean-architecture
C#
135
star
8

VueASPNETCore2WebApiAuth

Sample project demonstrating jwt-based authentication with an Vue.js (v2.5.13) frontend and ASP.NET Core 2 WebApi. Includes both local user registration with .NET Core Identity membership and facebook login scenarios.
C#
111
star
9

fullstack-jobs

Real(ish) demo using Angular with ASP.NET Core GraphQL and IdentityServer.
C#
88
star
10

AngularASPNETCoreAuthentication

Complete user authentication example with Angular 4 and ASP.NET Core 1.0. There is a new version of this repo based on ASP.NET Core 2.0. Please see https://fullstackmark.com/post/13/jwt-authentication-with-aspnet-core-2-web-api-angular-5-net-core-identity-and-facebook-login for more information.
JavaScript
85
star
11

ApiIntegrationTestSamples

Demo project containing end-to-end, in-memory integration tests in ASP.NET Core 2.1
C#
65
star
12

open-standup-mobile

C#
16
star
13

XamFormsReactiveUI

A simple vocabulary app made with Xamarin Forms and ReactiveUI
C#
11
star
14

ASPNetCoreDIAndUnitTesting

C#
10
star
15

XamFormsWebSockets

C#
9
star
16

GetStartedAngularASPNetCore

JavaScript
7
star
17

dotnetCoreTDD

C#
5
star
18

web-api-scraper

C#
1
star
19

dotnet-git-hooks

This repo contains a sample project as part of a tutorial explaining how to set up Git hooks with Husky.Net. The tutorial shows you how to use Husky to add a couple of hooks in a .NET project to run the dotnet format and dotnet test commands during the Git workflow.
C#
1
star