Skip to content

Commit 0d71edf

Browse files
committed
Merge from Dev
2 parents dbe277c + e5217c1 commit 0d71edf

163 files changed

Lines changed: 2541 additions & 1463 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
*.user
77
*.userosscache
88
*.sln.docstates
9+
.vscode/
910

1011
# User-specific files (MonoDevelop/Xamarin Studio)
1112
*.userprefs

README.md

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,14 @@
1-
# eShopOnContainers - Microservices Architecture and Containers based Reference Application (**ALPHA state** - VS 2017 and CLI environments compatible)
1+
# eShopOnContainers - Microservices Architecture and Containers based Reference Application (**BETA state** - Visual Studio 2017 and CLI environments compatible)
22
Sample .NET Core reference application, powered by Microsoft, based on a simplified microservices architecture and Docker containers. <p>
3+
**Note for Pull Requests**: We accept pull request from the community. When doing it, please do it onto the DEV branch which is the consolidated work-in-progress branch. Do not request it onto Master, if possible.
34

45
> ### DISCLAIMER
5-
> **IMPORTANT:** The current state of this sample application is **ALPHA**, consider it version a 0.1 foundational version, therefore, many areas could be improved and change significantly while refactoring current code and implementing new features. **Feedback with improvements and pull requests from the community will be highly appreciated and accepted.**
6+
> **IMPORTANT:** The current state of this sample application is **BETA**, consider it version a 0.1 foundational version, therefore, many areas could be improved and change significantly while refactoring current code and implementing new features. **Feedback with improvements and pull requests from the community will be highly appreciated and accepted.**
67
>
7-
> This reference application proposes a simplified microservice oriented architecture implementation to introduce technologies like .NET Core with Docker containers through a comprehensive application. However, this reference application it is not trying to solve all the problems in a large and mission-critical distributed system, it is just a bootstrap for developers to easily get started in the world of Docker containers and microservices with .NET Core.
8+
> This reference application proposes a simplified microservice oriented architecture implementation to introduce technologies like .NET Core with Docker containers through a comprehensive application. The chosen domain is an eShop/eCommerce but simply because it is a well-know domain by most people/developers.
9+
However, this sample application should not be considered as an "eCommerce reference model", at all. The implemented business domain might not be ideal from an eCommerce business point of view. It is neither trying to solve all the problems in a large, scalable and mission-critical distributed system. It is just a bootstrap for developers to easily get started in the world of Docker containers and microservices with .NET Core.
810
> <p>For example, the next step (still not covered in eShopOnContainers) after understanding Docker containers and microservices development with .NET Core, is to select a microservice cluster/orchestrator like Docker Swarm, Kubernetes or DC/OS (in Azure Container Service) or Azure Service Fabric which in most of the cases will require additional partial changes to your application's configuration (although the present architecture should work on most orchestrators with small changes).
9-
> Or moving your databases to HA cloud services, or implementing your EventBus with Azure Service Bus or any other production ready Service Bus in the market.
11+
> Additional steps would be to move your databases to HA cloud services, or to implement your EventBus with Azure Service Bus or any other production ready Service Bus in the market.
1012
> <p> In the future we might fork this project and make multiple versions targeting specific microservice cluster/orchestrators plus using additional cloud infrastructure. <p>
1113
> <img src="img/exploring-to-production-ready.png">
1214
> Read the planned <a href='https://github.com/dotnet/eShopOnContainers/wiki/01.-Roadmap-and-Milestones-for-future-releases'>Roadmap and Milestones for future releases of eShopOnContainers</a> within the Wiki for further info about possible new implementations and provide feedback at the <a href='https://github.com/dotnet/eShopOnContainers/issues'>ISSUES section</a> if you'd like to see any specific scenario implemented or improved. Also, feel free to discuss on any current issue.
@@ -32,7 +34,7 @@ Additional miroservice styles with other frameworks and No-SQL databases will be
3234
> <p> However, in a real production environment it is recommended to have your databases (SQL Server and Redis, in this case) in HA (High Available) services like Azure SQL Database, Redis as a service or any other clustering system. If you want to change to a production configuration, you'll just need to change the connection strings once you have set up the servers in a HA cloud or on-premises.
3335
3436
## Related documentation and guidance
35-
While developing this reference application, we are creating a reference Guide/eBook named <b>"Architecting and Developing Containerized and Microservice based .NET Applications"</b> which explains in detail how to develop this kind of architectural style (microservices, Docker containers, Domain-Driven Design for certain microservices) plus other simpler architectural styles, like monolithic apps that can also live as Docker containers.
37+
While developing this reference application, we've been creating a reference <b>Guide/eBook</b> focusing on <b>architecting and developing containerized and microservice based .NET Applications</b> (download link available below) which explains in detail how to develop this kind of architectural style (microservices, Docker containers, Domain-Driven Design for certain microservices) plus other simpler architectural styles, like monolithic apps that can also live as Docker containers.
3638
<p>
3739
There are also additional eBooks focusing on Containers/Docker lifecycle (DevOps, CI/CD, etc.) with Microsoft Tools, already published plus an additional eBook focusing on Enterprise Apps Patterns with Xamarin.Forms.
3840
You can download them and start reviewing these Guides/eBooks here:
@@ -41,9 +43,9 @@ You can download them and start reviewing these Guides/eBooks here:
4143
| Architecting & Developing | Containers Lifecycle & CI/CD | App patterns with Xamarin.Forms |
4244
| ------------ | ------------| ------------|
4345
| <a href='https://aka.ms/microservicesebook'><img src="img/ebook_arch_dev_microservices_containers_cover.png"> </a> | <a href='https://aka.ms/dockerlifecycleebook'> <img src="img/ebook_containers_lifecycle.png"> </a> | <a href='https://aka.ms/xamarinpatternsebook'> <img src="img/xamarin-enterprise-patterns-ebook-cover-small.png"> </a> |
44-
| <sup> <a href='https://aka.ms/microservicesebook'>**Download** (Early DRAFT, still work in progress)</a> </sup> | <sup> <a href='https://aka.ms/dockerlifecycleebook'>**Download** (First Edition from late 2016) </a> </sup> | <sup> <a href='https://aka.ms/xamarinpatternsebook'>**Download** (Early DRAFT, still work in progress) </a> </sup> |
46+
| <sup> <a href='https://aka.ms/microservicesebook'>**Download** (Early DRAFT, still work in progress)</a> </sup> | <sup> <a href='https://aka.ms/dockerlifecycleebook'>**Download** (First Edition from late 2016) </a> </sup> | <sup> <a href='https://aka.ms/xamarinpatternsebook'>**Download** (Preview Edition) </a> </sup> |
4547

46-
Send feedback to [cesardl@microsoft.com](cesardl@microsoft.com)
48+
Send feedback to [dotnet-architecture-ebooks-feedback@service.microsoft.com](dotnet-architecture-ebooks-feedback@service.microsoft.com)
4749
<p>
4850
However, we encourage to download and review the "Architecting & Developing eBook" because the architectural styles and architectural patterns and technologies explained in the guidance are using this reference application when explaining many pattern implementations, so you'll understand much better the context, design and decisions taken in the current architecture and internal designs.
4951

cli-linux/build-bits-linux.sh

100644100755
Lines changed: 18 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,17 @@
1-
2-
projectList=(
3-
"/src/Services/Catalog/Catalog.API"
4-
"/src/Services/Basket/Basket.API"
5-
"/src/Services/Ordering/Ordering.API"
6-
"/src/Services/Identity/Identity.API"
7-
"/src/Web/WebMVC"
8-
"/src/Web/WebSPA"
9-
"/src/Web/WebStatus
1+
#!/bin/bash
2+
declare -a projectList=(
3+
'../src/Services/Catalog/Catalog.API'
4+
'../src/Services/Basket/Basket.API'
5+
'../src/Services/Ordering/Ordering.API'
6+
'../src/Services/Identity/Identity.API'
7+
'../src/Web/WebMVC'
8+
'../src/Web/WebSPA'
9+
'../src/Web/WebStatus'
1010
)
1111

1212
# Build SPA app
13-
pushd $(pwd)/src/Web/WebSPA
14-
npm rebuild node-sass
15-
npm run build:prod
13+
# pushd $(pwd)../src/Web/WebSPA
14+
# npm run build:prod
1615

1716
for project in "${projectList[@]}"
1817
do
@@ -28,13 +27,13 @@ do
2827
done
2928

3029
# remove old docker images:
31-
#images=$(docker images --filter=reference="eshop/*" -q)
32-
#if [ -n "$images" ]; then
33-
# docker rm $(docker ps -a -q) -f
34-
# echo "Deleting eShop images in local Docker repo"
35-
# echo $images
36-
# docker rmi $(docker images --filter=reference="eshop/*" -q) -f
37-
#fi
30+
images=$(docker images --filter=reference="eshop/*" -q)
31+
if [ -n "$images" ]; then
32+
docker rm $(docker ps -a -q) -f
33+
echo "Deleting eShop images in local Docker repo"
34+
echo $images
35+
docker rmi $(docker images --filter=reference="eshop/*" -q) -f
36+
fi
3837

3938
# No need to build the images, docker build or docker compose will
4039
# do that using the images and containers defined in the docker-compose.yml file.

docker-compose-windows.yml

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ version: '2.1'
22

33
services:
44
basket.api:
5-
image: eshop/basket.api
5+
image: eshop/basket.api-win
66
build:
77
context: ./src/Services/Basket/Basket.API
88
dockerfile: Dockerfile.nanowin
@@ -11,31 +11,31 @@ services:
1111
- identity.api
1212

1313
catalog.api:
14-
image: eshop/catalog.api
14+
image: eshop/catalog.api-win
1515
build:
1616
context: ./src/Services/Catalog/Catalog.API
1717
dockerfile: Dockerfile.nanowin
1818
depends_on:
1919
- sql.data
2020

2121
identity.api:
22-
image: eshop/identity.api
22+
image: eshop/identity.api-win
2323
build:
2424
context: ./src/Services/Identity/Identity.API
2525
dockerfile: Dockerfile.nanowin
2626
depends_on:
2727
- sql.data
2828

2929
ordering.api:
30-
image: eshop/ordering.api
30+
image: eshop/ordering.api-win
3131
build:
3232
context: ./src/Services/Ordering/Ordering.API
3333
dockerfile: Dockerfile.nanowin
3434
depends_on:
3535
- sql.data
3636

3737
webspa:
38-
image: eshop/webspa
38+
image: eshop/webspa-win
3939
build:
4040
context: ./src/Web/WebSPA
4141
dockerfile: Dockerfile.nanowin
@@ -44,7 +44,7 @@ services:
4444
- basket.api
4545

4646
webmvc:
47-
image: eshop/webmvc
47+
image: eshop/webmvc-win
4848
build:
4949
context: ./src/Web/WebMVC
5050
dockerfile: Dockerfile.nanowin
@@ -58,18 +58,18 @@ services:
5858
image: microsoft/mssql-server-windows
5959

6060
basket.data:
61-
image: redis
62-
build:
63-
context: ./_docker/redis
64-
dockerfile: Dockerfile.nanowin
61+
image: eshop/redis-win
62+
# build:
63+
# context: ./_docker/redis
64+
# dockerfile: Dockerfile.nanowin
6565
ports:
6666
- "6379:6379"
6767

6868
rabbitmq:
69-
image: rabbitmq
70-
build:
71-
context: ./_docker/rabbitmq
72-
dockerfile: Dockerfile.nanowin
69+
image: eshop/rabbitmq-win
70+
# build:
71+
# context: ./_docker/rabbitmq
72+
# dockerfile: Dockerfile.nanowin
7373
ports:
7474
- "5672:5672"
7575

docker-compose.ci.build.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,5 +6,5 @@ services:
66
volumes:
77
- .:/src
88
working_dir: /src
9-
command: /bin/bash -c "pushd ./src/Web/WebSPA && npm rebuild node-sass && pushd ./../../.. && dotnet restore ./eShopOnContainers-ServicesAndWebApps.sln && dotnet publish ./eShopOnContainers-ServicesAndWebApps.sln -c Release -o ./obj/Docker/publish"
9+
command: /bin/bash -c "dotnet restore ./eShopOnContainers-ServicesAndWebApps.sln && dotnet publish ./eShopOnContainers-ServicesAndWebApps.sln -c Release -o ./obj/Docker/publish"
1010

docker-compose.override.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,6 @@ services:
4545
- ASPNETCORE_URLS=http://0.0.0.0:5102
4646
- ConnectionString=Server=sql.data;Database=Microsoft.eShopOnContainers.Services.OrderingDb;User Id=sa;Password=Pass@word
4747
- identityUrl=http://identity.api:5105 #Local: You need to open your local dev-machine firewall at range 5100-5105. at range 5100-5105.
48-
- BasketUrl=http://basket.api:5103
4948
- EventBusConnection=rabbitmq
5049
ports:
5150
- "5102:5102"

docker-compose.prod.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,6 @@ services:
5050
- ASPNETCORE_URLS=http://0.0.0.0:5102
5151
- ConnectionString=Server=sql.data;Database=Microsoft.eShopOnContainers.Services.OrderingDb;User Id=sa;Password=Pass@word
5252
- identityUrl=http://identity.api:5105 #Local: You need to open your host's firewall at range 5100-5105. at range 5100-5105.
53-
- BasketUrl=http://basket.api:5103
5453
- EventBusConnection=rabbitmq
5554
ports:
5655
- "5102:5102"
947 KB
Binary file not shown.

0 commit comments

Comments
 (0)