EPiServer Foundation

EPiServer Foundation

As part of the EPiServer Ascend event, EPiServer showcased EPiServer Foundation. In this post I am going to explain what it is, what can you use it for, what are some of the pros and cons, and how to install it.

epi_server_logo_detail

So, lets begin !!!!

What it is?

EPiServer Foundation is an accelerator created by EPiServer in house developers using a well structured and modular design. It tries to establish the best practices other developers should follow. It is open source and it will be modified by the community with EPiServer governance. It includes the CMS, Commerce, Personalization, Find and Social products

What can you use it for?

The main purpose of the EPiServer Foundation is to showcase a variety of products all integrated in one place. Before this you had independent reference example codes for some of their products such as: Alloy for the CMS product and QuickSilver for the Commerce one. There were no reference examples for Find, Social or Personalization. With this project you can have everything in one place and use it as a demo that can be shown to potential clients or you can use it as a starting point for a new project. However, you should keep in mind that if you don’t need some of the functionality that is already in place you will have to remove some projects and files. EPiServer is planning to solve this issue in the future by providing each feature as a NuGet package so you can start as an empty EPiServer project and add only what you need using the packages.

Pros

Open Source – Other developers can improve upon the project without depending directly from EPiServer

Modular – Each product is contained inside their own set of Visual studio projects so you can remove them if they are not needed

One project to rule them all – All main products of EPiServer are showcased here; it is by far the fasted way to implement a demo and use it to showcase EPiServer full potential

Code Best practices – The project shows the code best practices that EPiServer suggests, which at the same time will help novice and more experienced developers to see how some of their products work or how something should be implemented

Cons

Open Source – Without correct governance from EPiServer these can cause real headaches to developers who want to use it

Not that modular – Even though each product is separated in a set of Visual studio projects, for the moment there is not a way to start from scratch and add the functionality you need. You must start with the full solution and remove the things you do not need.

Other proprietary accelerators – During the years, partners around the world have been creating their own accelerators. This project will conflict with several of their implemented functionality and it is quite possible that the adoption rate of this project falls because of it.

No unit testing – Even though the code in the project is modular and uses the best practices EPiServer suggests, there are not unit tests to be found. EPiServer should have considered these tests because in my opinion it sends the wrong messages to developers who are yet to implement unit testing in their own projects.

How to install it?

To install the project, we must install the following pre-requirements first:

  • Visual Studio 2017 or higher
  • Sql Server Express or Developer or Sql Azure Server (If using Sql Azure download sqlcmd)
  • Nodejs
  • IIS

Now, we clone the repository using the git clone command using this url

After the repository is downloaded go to the folder and execute the Build.cmd file, provide the requested parameters as follows:

Note: Build.cmd is now being used for a different purpose, You can use the setup.cmd command instead

ParameterDescription
Application nameName of the application
Public domain nameDomain for the application, ex. foundation.com
Public domain name for commerceDomain for the commerce application, ex. commerce.foundation.com
License pathWhere is the EPiServer license located in your computer
SQL Server nameSQL Server instance name, for local use dot(.) or localhost
SQL CommandSQL command to execute, by default -S -E

After providing all parameters. The wizard will execute several commands to create the new project and set it live.

When it finishes it will open a browser window using the domain you specified in the one of the parameters above.

Unfortunately, it seems like there is a mistake in the script, as the windows host file was modified with different host names as the one, we specified in the parameter

We write down the domains we specified in the parameters inside the hosts file and we try to reload the page in the browser

This will open a content migration page where we specify from which site do, we want to migrate the CMS and the Commerce Catalog content. It can take several tries to make this page appear. Refresh the page if you find something weird or if a 500 error suddenly appears.

In the first option choose remote site, and select Mosey from the list, there is only one option anyway

In the second option choose remote catalog site and select one of the three available options. I had some issues when I imported the Foundation_Tools catalog so I will recommend using the Foundation_Fashion which is the one worked for me

Press the button submit query and wait a couple of minutes. It will show the home page after the process finishes. There is no loader in the UI after you press the button, so be patient

You can access the edit UI interface by adding /episerver at the end of the home url. The default username is admin@example.com with password: store

And that is all. You have now a live EPiServer site with CMS, Commerce, Personalization, Find and Social products already implemented. You can modify it as you wish after it. If you have any issues with any of the steps please review the latest installing instructions here https://github.com/episerver/foundation.

Written by:

Jorge Cardenas

Developer with several years of experience who is passionate about technology and how to solve problems through it.

View All Posts

2 COMMENTS

comments user
Visitor

Would have added a link to the github repo also like this: https://github.com/episerver/foundation where everyone can see the up to date install instructions.

The build.cmd has been replaced with setup.cmd (build.cmd has different purpose nowadays)

    comments user
    Jorge Cardenas

    Thanks for the comment. Fixing it right away

Leave a Reply