From b62fdf89e668ff9faaaddffebb365b196fe7fe5c Mon Sep 17 00:00:00 2001 From: Cesar De la Torre Date: Wed, 25 Oct 2017 14:26:49 -0700 Subject: [PATCH] Updated 04. Setting eShopOnContainer solution up in a Mac, VS for Mac or with CLI environment (dotnet CLI, Docker CLI and VS Code) (markdown) --- ...t--(dotnet-CLI,-Docker-CLI-and-VS-Code).md | 19 +++++++++---------- 1 file changed, 9 insertions(+), 10 deletions(-) diff --git a/04.-Setting-eShopOnContainer-solution-up-in-a-Mac,-VS-for-Mac-or-with-CLI-environment--(dotnet-CLI,-Docker-CLI-and-VS-Code).md b/04.-Setting-eShopOnContainer-solution-up-in-a-Mac,-VS-for-Mac-or-with-CLI-environment--(dotnet-CLI,-Docker-CLI-and-VS-Code).md index ca261d6..0ea95b2 100644 --- a/04.-Setting-eShopOnContainer-solution-up-in-a-Mac,-VS-for-Mac-or-with-CLI-environment--(dotnet-CLI,-Docker-CLI-and-VS-Code).md +++ b/04.-Setting-eShopOnContainer-solution-up-in-a-Mac,-VS-for-Mac-or-with-CLI-environment--(dotnet-CLI,-Docker-CLI-and-VS-Code).md @@ -106,7 +106,7 @@ And by typing `docker ps` you can see the containers running in Docker. The infr ## B.1 - Building the application from a Docker Linux "build container" -This is the simples way to do it from the CLI, but until a [bug is solved in .NET CLI]() please, follow the OPTION B.2 explained below (building .NET bits in the local Mac) +This is the simples way to do it from the CLI, but until a [bug is solved in .NET CLI when running "dotnet publish" within a container](https://github.com/Microsoft/msbuild/issues/2153#issuecomment-305375162), please, follow the OPTION B.2 explained below (building .NET bits in the local Mac) Open a bash shell and run the following four commands: @@ -149,7 +149,6 @@ The credentials for a demo user are: - User: **demouser@microsoft.com** - Password: **Pass@word1** --------------------------------------------------------------------- -------------------------------------------------------------------- ## B.1.1 - Detailed procedure - Setting eShopOnContainers up using the Docker Linux build-container @@ -180,28 +179,27 @@ list of prerequisites and tools needed to build locally on your machine. ## B.2 - Building the application binaries on the local Mac (local .NET Core in Mac) -You can build the application using your machine, if you prefer. You'll need the following +You can build the application using your local Mac machine. You'll need the following prerequisites installed, in addition to those listed above for building using the CI container. - *[.NET Core and SDK](http://dot.net)* - *[Node and NPM](http://nodejs.org)* + - *Bower* ($ npm install -g bower) needed by the MVC web app. Install the following software versions: - - .NET Core 1.1 (1.1.2 with SDK 1.0.4 (Promoted to LTS)) https://github.com/dotnet/core/blob/master/release-notes/download-archives/1.1.2-download.md - - NodeJS 6.11.1 + - [.NET Core 2.0 SDK or later, for Mac](https://www.microsoft.com/net/core#macos) + - [NodeJS 6.11.5 or latest Long Term version](https://nodejs.org/en/) - Ensure you are using the lastest version of node packages such us angular-cli 1.3.0 or you will receive some errors when - you run docker-compose -f docker-compose.ci.build.yml up because the command npm run build:prod will fail. + We've included a bash script that runs all the dotnet build commands on your local Mac. - We've included a bash script that runs all the build commands locally. Navigate to your - eShopOnContainers directory, and cd into the *cli-mac* directory. Then, run the build script: + Using the bash windows, navigate to your eShopOnContainers directory, and cd into the *cli-mac* directory. Then, run the build script: ```bash $ ./build-bits.sh ``` - The script runs a restore, build, and publish for each project using the `dotnet` CLI tool. + This script runs a dotnet restore, build, and publish for each project using the `dotnet` CLI tool. In addition, it runs the client build commands using *npm* to build the SPA application assets. Finally, it will remove old docker containers and images. @@ -224,6 +222,7 @@ from Docker hub. That will take some time. Once the images have been pulled, the application will start and you can test it out using the browser and the addresses shown [above](#running-the-application). + # Configuring the app for Authentication and access from remote client apps ## Setting up the docker-compose file environment variables and settings