Setup TIS-Admin with Cognito locally (beta)
Prerequisites
You have access to a copy of TIS Stage data.
Start up some TIS core services with dev-handbook
Check out the branch in dev-handbook to configure Nginx, then, go to the "dev-handbook/admins-ui/environment-setup", and do
docker-compose up
to bring docker containers up.Stop the containers: tis-admins-ui and tis-profile, as we are going to run them in local IDE.
Configure MySQL database: If you've already got MySQL db setup locally with data, skip this step and go to the next step.
Get a copy of tis backup db data from S3 bucket (Stage) and unzip it on your local.
After tis-mysql docker container is started up, import data into MySQL . (If you have no idea how to do this, please check with one of other devs).
Start up Profile service with a specific branch
Check out the branch in TIS-PROFILE , and start it up in Idea Intelij
Configure Cognito and start up TIS-ADMINS-UI with a specific branch
Set an account in Cognito user pool:
1. you could either create user in the console or import users via CSV template.
2. if your local data is a copy of Stage, please use a Stage email accout of yours to set up in Cognito users and the email should match theHeeUser.name
in your MySQL profile db.
3. make sure the email address you use here is able to receive emails and mark your email address as verified.Check out the branch in TIS-ADMINS-UI. It’s configured with Amplify 5 to seek authentications with the user pool dingers-test.
Start up TIS-ADMINS-UI by
npm start
, and then in your browser, try typinghttp://local.tis.com/admin
orhttp://localhost/admin
. If you get a 502 http error, check if the node use is above version 16. If it is, add--host 0.0.0.0
to package.json “start“ script.
Then you will see a login page as below:
If you forget your password, it’s possible to click on “Forgot your password?“ link and reset your password with verification code sent to your email address.
Slack: https://hee-nhs-tis.slack.com/
Jira issues: https://hee-tis.atlassian.net/issues/?filter=14213