Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Staging and Production setup for Users Service #2053

Closed
humphd opened this issue Mar 30, 2021 · 0 comments
Closed

Staging and Production setup for Users Service #2053

humphd opened this issue Mar 30, 2021 · 0 comments
Labels
area: microservices area: redis Redis Database related type: enhancement New feature or request type: security Security concerns

Comments

@humphd
Copy link
Contributor

humphd commented Mar 30, 2021

Discussions today led us to the conclusion that we need a list of steps for everything we have to do in order to fully ship the Users service:

  1. Land Closes Issue #1932: Added environment variables to prod's Docker file #2027 for docker configs (@chrispinkney)
  2. Modify Firebase schema to use email vs. id as the User identifier, in order to match Seneca's nameID. This will involve changes to unit tests, Celebrate validation, and Users schema (@humphd Use hashed email as id for Users in Firestore #2060)
  3. Paginate data for Users / route Fixes issue-1929: Paginated get route #2022 (@chrispinkney)
  4. Modify https://github.com/Seneca-CDOT/telescope/blob/master/src/api/auth/src/authorization.js#L19-L27 to use nameID and have JWT token match what Users service expects, as well as include roles in JWTs (i.e., convert isAdmin to ["admin", ...]) when we create the token (@humphd, Add proper roles and User service to JWT authorization #2058).
  5. Add createServiceToken to Satellite for inter-service communication, to allow for role["service"] @humphd in Add support for generating a service token DevelopingSpace/satellite#10, Expose JWT_ISSUER, JWT_AUDIENCE, and SECRET env vars to all services #2055 to deal with missing env vars to make that possible.
  6. Add auth middleware to all routes of Users service based on JWT id (i.e., email) and/or role (e.g., admin or service account) (@humphd Add auth middleware to Users service #2116)
  7. Create production and staging Firebase projects (@humphd, @manekenpix) Firebase setup for Staging and Production #1932
  8. Share account access to Firebase projects with anyone who is involved with staging/production (@humphd)
  9. Redis caching for Users service Put Redis between Users Service and Firestore #2030 (@humphd, @chrispinkney, @Metropass, @manekenpix)
  10. Connect Users service to front-end
    i. on login, we need to get user info from User service to populate the user object. Instead of using the JWT payload for user info (see https://github.com/Seneca-CDOT/telescope/blob/master/src/web/src/components/AuthProvider.tsx#L81-L93), we need to do a GET request to the Users service, passing our JWT token, and get back the full user object (Rework User to use proper JWT payload data #2088 @humphd)
    ii. signup flow in front-end SignUp Page #2148 (@PedroFonsecaDEV, @DukeManh, @Meneguini)
  11. Migrate legacy accounts away from wiki (automate something to import this into Firebase from data we have in Wiki now) to Firebase (@humphd, @chrispinkney, @manekenpix) Migrate legacy accounts away from wiki #2083
  12. Connect Parser service to Users (@c3ho, @chrispinkney) - Blocked by Parser service currently being disabled
  13. Cache Controls for Users routes (@Metropass)
  14. nginx cache for User routes (@Metropass)
  15. Investigate healthcheck API for Firebase to connect to Satellite (@chrispinkney) - Doesn't look like Firestore supports this
  16. Update Users e2e tests to work via public API Fix users MS e2e tests #2054 (@manekenpix, @chrispinkney) PR Closes #2054: Fix users MS e2e tests #2173
  17. Figure out how users become an admin Limit how a user becomes an admin #2153 (@chrispinkney)
  18. Signup flow fails with feed-discovery Signup flow fails with feed-discovery #2186
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: microservices area: redis Redis Database related type: enhancement New feature or request type: security Security concerns
Projects
None yet
Development

No branches or pull requests

5 participants