Alef platform's module for teachers, principles and school leaders
Please install node manager
from https://github.com/tj/n
Set up the specific node version by running n auto
.
We will need some env variables that allow us to fetch internal deps.
We can set it up in two ways
- We can make it local
export NPM_TOKEN=ask-team-member-to-get-that
export GITHUB_NPM_TOKEN=ask-team-member-to-get-that
export NEXUS_REPO_USERTOKEN=ask-team-member-to-get-that
- We can make it global
https://unix.stackexchange.com/questions/117467/how-to-permanently-set-environmental-variables
To check if variables are saved please run
printenv
Firstly we will need authorization middleware running in the background
Please clone it from https://github.com/AlefEducation/alef-journey-router
.
Your project structure should look like
projects/
alef-teacher-frontend/
alef-journey-router/
Please be sure your env variables are accessible ( look in "Env setup" )
Install dependencies by running npm i
then npm run generate:all
in alef-teacher-frontend
and npm i
in alef-journey-router
directories.
Run apps by npm run serve:{env}
for example npm run serve:e2e
also in both directories.
You should use 2 tabs in your terminal.
After all those step you can open on https://localhost:8081/teacher/
- Create
k8DashToken.js
file in the project root- This file will contain the bearer token and looks like ...
module.exports.token = 'Bearer ey...
- Get the token value in http://skooner.nprd.alefed.com/
- Open browser console, and run below code. This will save the content of the file on your clipboard. then paste it in
k8DashToken.js
copy(`module.exports.token = 'Bearer ${localStorage.getItem('authToken')}'`)
- Open browser console, and run below code. This will save the content of the file on your clipboard. then paste it in
- This file will contain the bearer token and looks like ...
- Run command
npm run download-schema:${env}
Please install Docker
Please be sure your env variables are accessible ( look in "Env setup" )
Run script sh ./build-docker-current.sh {prefix_tag}
for example sh ./build-docker-current.sh turtles
Follow the steps from the terminal