Skip to content

Arquisoft/viade_es2a

Repository files navigation

Build Status codecov Codacy Badge

VIADE ES2A

This repository contains a skeleton of the VIADE project.

This project is an assignment for the Software Architecture course following these requirements.

The app is deployed at https://arquisoft.github.io/viade_es2a/ which also contains a technical documentation.

More information about how this project has been setup is available in the wiki.

Launching Unitary Tests

You need to install the dependencies needed for the project by executing the following command

npm install
# or "yarn install"

Now you can run all the tests:

npm test a

Launching Acceptance Tests

First of all, you need to install puppeteer. It'll automatically download the chromium browser in which the tests will take place.

npm install puppeteer
# or "yarn add puppeteer"

Now you can run the tests:

npm run test:e2e

Docker Deployment Instructions

In order to deploy our Viade application using docker engine we have to clone this repository in your local machine and you will need to have installed Docker too. In this case we are using Docker Toolbox in a Windows machine

To start over we start the docker machine by opening a docker quickstart terminal, which shows us the IP of our docker machine.

Assuming that we have our repository cloned, we move to the folder with

cd "path to repository source folder"

First of all, to be able to deploy our app using a SOLID POD server, we need to download the official image nodesolidserver from DockerHub https://hub.docker.com/r/nodesolidserver/node-solid-server

docker pull nodesolidserver/node-solid-server

The next step will be to run the container for the server that will use this image.

docker run -p 8443:8443 --name solid nodesolidserver/node-solid-server

Once executed, it is available via navegator on docker machine´s IP and the port for the container where it is required to log in and access the solid server protoype implementation.

The next step would be to create the container for Viade node app, using a Dockerfile

FROM node:12.14.1
EXPOSE 3000:3000
COPY . /app
WORKDIR /app
RUN npm installed
CMD ["node", "--max_old_space_size=4112", "scripts/start.js"]

Next, execute the command to build this container:

docker build -t node .

Lastly, running the container using:

docker run -p 3000:3000 --name viade_es2a node

Now, accessing to this URL of the docker engine IP and port 3000 is possible to use Viade_es2a deployed using Docker.

Authors

  • Marcos Álvarez Vidal
  • Sergio Corral Cristo
  • Jesús Pérez Noriega
  • Alejandro León Pereira
  • Nerea Valdés Egocheaga
  • Álvaro Tango Fernández
  • Luis Fuertes Camporro