Install Node.js (https://nodejs.org/
) version 18.3 or higher.
To install all the packages and dependencies needed, you will need to execute:
npm install
Before running the frontend, you will need to modify some backend configuration values to point to your INESData connector environment. Those are stored in .env
file, and
by default contain the following:
VITE_APP_BACKEND_API_URL='http://localhost:19193/management'
VITE_APP_KEYCLOAK_ROOT='http://keycloak:8080'
VITE_APP_KEYCLOAK_CLIENTID='dataspace-users'
VITE_APP_KEYCLOAK_REALM='dataspace'
VITE_APP_I18N_LOCALE='EN'
To start the FE on your development machine, you will need to execute:
npm run serve:ui
The UI will be available at http://localhost:8090
To build the FE, you will need to execute:
npm run build
Then, you can create a Docker image:
docker build --tag inesdata-fe-app .
Or just run the application locally with:
docker compose up
In this case, the UI will be available at http://localhost:8090/dataspace/
.
You can change the port on which the application is running, in the docker-compose.yml
file.
In case you want to have 2 UI instances running in your local environment, pointing to 2 different connectors, you will need to follow these steps:
- Modify the
.env
file to configure the Connector 1 backend API URL:
VITE_APP_BACKEND_API_URL='http://localhost:19193/management'
- Build the FE:
npm run build
- Create a Docker image for the Connector 1
docker build --tag inesdata-fe-app-con1 .
- Run the Docker image inside a container
docker run -p 8090:80 -d inesdata-fe-app-con1
At this point, the UI for the Connector 1 will be available at http://localhost:8090/dataspace/
.
- Modify again the
.env
file to configure the Connector 2 backend API URL:
VITE_APP_BACKEND_API_URL='http://localhost:29193/management'
- Build again the FE:
npm run build
- Create a Docker image for the Connector 2:
docker build --tag inesdata-fe-app-con2 .
- Run the Docker image inside a container:
docker run -p 18090:80 -d inesdata-fe-app-con2
At this point, the UI for the Connector 2 will be available at http://localhost:18090/dataspace/
.