Skip to content
This repository has been archived by the owner on Mar 8, 2021. It is now read-only.
/ ICT-120_151 Public archive

Epsic ICT-120 & 151 Exam projects (front-end & back-end)

Notifications You must be signed in to change notification settings

laurentksh/ICT-120_151

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

91 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ICT-120_151

.NET Back-End: Build - Test - Deploy Angular Front-End: Build - Deploy

Epsic ICT-120 & 151 Exam projects (front-end & back-end) written in C# and TS, using ASP.NET Core and Angular.

Installation & Testing

A "production" application instance hosted on Azure is available here:

UPDATE: The Azure instances have been removed to save money.

However, if you still want to run a local instance, there are quite a few steps required beforehand.

Running the back-end server first is recommended.

Back-End

Dependencies

To run this project you will need to install the .NET 5 SDK from Microsoft.

If you want to use medias (publication images, profile pictures, etc), you will need to install Azurite, a server clone of Azure.

(Optional) Installing Azurite

To install Azurite, you will need NPM (i.e >= Node.JS 8.0). (For more information see section Front-End > Dependencies)

Run the following command to install Azurite:

npm install -g azurite

This command will install Azurite globally.

(Optional) Running Azurite

To start Azurite, open a command prompt/PowerShell, go to the root folder of the repository and use the following command:

azurite --silent --location Azurite --debug Azurite/debug.log

or run the azurite.bat script present at the root foolder.

You can freely change the location as it will contain the files uploaded using the application.

Migrating the database

As the application uses a database, you will need to apply the migrations first. To do so, run the following command in /src/back/ICT-151/ICT-151/ :

dotnet ef database update

This command should create (if it doesn't exist) a AppDb.db file, which will be our database.

Running

Go to /src/back/ICT-151/ICT-151/ and use:

dotnet run --configuration=Release

Testing

To run tests, go to /src/back/ICT-151/ and use:

dotnet test

Front-End

Dependencies

The Front-End application requires NPM (and thus Node.JS) to be installed.

Download: https://nodejs.org/en/download/

Installation

After installing Node.JS, go to /src/front/ICT120/ and run:

npm install

Running

Open a terminal and run the front-end part with NPM:

npm start

or:

ng serve

You can also add the --prod attribute to use the public back-end API.

Testing

There are no front-end tests.

Usage

Open your favorite browser (must not be IE, non-Chromium Edge, or any similarly outdated browser), and go to localhost:4200

The Back-End Swagger is available at localhost:5001/swagger

The public instances hosted on Azure are also available:

Contributing

Contributions are not welcome as this is a school project.

License

None (i.e Copyright)