Skip to content
This repository has been archived by the owner on Jun 17, 2024. It is now read-only.

Getting started

jayrenn edited this page Mar 30, 2017 · 15 revisions

Table of contents

Architecture

The Enterprise Mode Site List Portal is a web-based application built on the MVC framework, with AngularJS, and SQL Server as the back-end database.

Required hardware

The Enterprise Mode Site List Portal requires the following hardware or hardware features for successful completion:

Hardware Description
Minimum physical memory 16 GB RAM recommended
Available disk space The PC must have at least 8 GB of free space. Disk must be formatted by NTFS file system for better security.

Required software

The tool requires the following software or software features for successful completion:

Software Minimum version
Client operating system Windows 7 or higher
Active Directory Domain joined
Additional server infrastructure Internet Information Service (IIS) 6.0 or later
SQL Server Microsoft SQL Server Enterprise Edition 2012 or later

Step 1: Create the Application Pool and Website in IIS

Copying the deployment folder to the web server

  1. Download the source code from the repository.
  2. Install npm.
  3. Open the EMIEWebPortal/ folder in File Explorer.
  4. Press and hold Shift, right-click the window, then click Open command window here.
  5. Type npm i into the command prompt, then press Enter.
  6. Go back up a directory, and open the solution file EMIEWebPortal.sln in Visual Studio and build the entire solution.
  7. Copy the contents of the EMIEWebPortal/ folder to the deployment directory of your Website.

Create a new Application Pool

  1. In IIS Manager, expand the local computer, right-click Application Pools, then click Add Application Pool.
  2. In the Application Pool Name field, type the name of the new application pool, e.g. EMIEWebAppPool.
  3. Select a .NET CLR version of v4.0 or higher, and select Managed pipeline mode as Integrated.
  4. Click OK.
  5. Select the Application Pool you just created from the list and click on the Advanced Settings option from the Actions pane.
  6. Confirm that the Identity value is set to ApplicationPoolIdentity.
  7. Click OK and close the dialogue.
  8. Navigate to your deployment directory in File Explorer, e.g. D:\EMIEWebApp.
  9. Right-click on the directory, go to Properties, and select the Security tab.
  10. Add the newly created Application Pool to the list, e.g. IIS AppPool\EMIEWebAppPool, with Full control permissions. Make sure the location is set to search the local computer.
  11. Add Everyone to the list with Read & execute permissions.

Create the Website

  1. In IIS Manager, expand the local computer, then right-click the Sites folder.
  2. Select Add Website.
  3. In the Site name field, enter a name for the Website, e.g. EMIEWebApp.
  4. Click the Select button and select the Application Pool you created earlier, e.g. EMIEWebAppPool.
  5. In the Physical path field, enter the name of the folder that contains the deployment directory, e.g. D:\EMIEWebApp.
  6. Configure the Binding Type, IP address, and Port as appropriate. Seek help from your network administrator if you have any questions.
  7. Un-check the checkbox Start Website immediately.
  8. Click OK.
  9. In IIS Manager, expand the local computer, then select the newly created Website, e.g. EMIEWebApp.
  10. From the Features View, double-click on the Authentication icon in the IIS section.
  11. Enable Windows Authentication. Anonymous Authentication should be enabled by default.
  12. Return to the Features View, then double-click on the Connection Strings icon in the ASP.NET section.
  13. Open the LOBMergedEntities Connection String for editing.
  14. Enter the name of your local computer where it says data source=.
  15. Enter the name of your database where it says initial catalog=. The next section will describe how to create the database.

Step 2: Create and prepare the database

  1. Launch SQL Server Management Studio.
  2. In Object Explorer, connect to an instance of the SQL Server Database Engine, e.g. ..
  3. Expand the instance, right-click on Databases, then select New Database.
  4. Enter a database name, e.g. EMIEDatabase.
  5. Accept all the default values and click OK.
  6. Open the 1_CreateEMIETables.sql query located in the DatabaseScripts/Create DB Tables/ folder.
  7. Replace the database name placeholder with the name you entered in step 4.
  8. Execute the query.

Step 3: Map the ApplicationPoolIdentity to a SQL Server Login

  1. Open SQL Server Management Studio and connect to your instance.
  2. Expand the instance and open the *Security folder at the server level, not the security folder for the database.
  3. Right-click on Logins and select New Login.
  4. Do not click Search. In the Login name field, if you have a local SQL Server instance, where IIS and SQL Server are on the same server, enter the name of your Application Pool, e.g. IIS AppPool\EMIEWebAppPool. If you have a remote SQL Server instance, where IIS and SQL Server are on the same server, enter Domain\ServerName$.
    (If a search is executed, it will resolve to an account with ServerName\AppPool Name and Management Studio will be unable to resolve the account's SID, as it is virtual)
  5. Open the User Mapping page and check the database you created earlier, e.g. EMIEDatabase. Select db_owner in the list of roles.
  6. Click OK.

Step 4: Restart the Application Pool and Website

  1. In IIS Manager, expand the local computer, then select the Website you created. Click Restart in the Manage Website pane.
  2. In IIS Manager, expand the local computer, then select the Application Pool you created. Click Recycle in the Application Pool Tasks pane.

Step 5: Registering the first user

  1. Open your browser and enter the URL for your Website, e.g. http://emieportal:8085.
  2. Click Register now.
  3. In the Email field, type your name or alias and a drop down will be displayed with the corresponding matches.
  4. Select your name from the drop down.
  5. Select Role as Administrator.
  6. Click Save.
  7. Navigate to the administrator console page by entering /#/EMIEAdminConsole in your address bar, e.g. http://emieportal:8085/#/EMIEAdminConsole.
  8. A dialog will prompt for the master username and password. The default username is EMIEAdmin and the default password is Admin123. It is recommended that you change the password using the Change password link after your first use.
  9. Select your name from the list and click Activate.
  10. Navigate to the home page and you should be able to sign in to the portal.

Step 6: Configure the SMTP server and port for email notification

  1. Open web.config from your deployment directory in Visual Studio or a text editor.
  2. Update the SMTP server and port shown below. The email account and password can be set from the Settings page in the tool.
<add key="host" value="SMTPHOST.corp.microsoft.com"/>
<add key="port" value="2500"/>

Step 7: Register the scheduler service

The scheduler service is used for production site list changes.

  1. Copy the folders App_Data, bin, and Logs from EMIEWebPortal.SchedulerService\EMIEWebPortal.SchedulerService to a separate folder, e.g. C:\EMIEService\.
  2. Run the Developer Command Prompt for Visual Studio as an administrator.
  3. Change the directory to the path of InstallUtil.exe, e.g. C:\Windows\Microsoft.NET\Framework\v4.0.30319.
  4. Run the command InstallUtil "<path/to/service/exe>", e.g. InstallUtil "C:\EMIEService\bin\Debug\EMIEWebPortal.SchedulerService.exe".
  5. Enter the credentials required to run the service.
  6. Open the services console using Services.msc, then start the service with the name EMIEScheduler.