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

Fixes #3794: SSO broken #3795

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Conversation

sfrunza13
Copy link
Contributor

@sfrunza13 sfrunza13 commented Jan 26, 2023

Issue This PR Addresses

fixes #3794

Type of Change

  • Bugfix: Change which fixes an issue
  • New Feature: Change which adds functionality
  • Documentation Update: Change which improves documentation
  • UI: Change which improves UI

Description

Steps to test the PR

Checklist

  • Quality: This PR builds and passes our npm test and works locally
  • Tests: This PR includes thorough tests or an explanation of why it does not
  • Screenshots: This PR includes screenshots or GIFs of the changes made or an explanation of why it does not (if applicable)
  • Documentation: This PR includes updated/added documentation to user exposed functionality or configuration variables are added/changed or an explanation of why it does not(if applicable)

@humphd
Copy link
Contributor

humphd commented Jan 26, 2023

@sfrunza13 this branch has a whole bunch of stuff in it (commits) not related to your fix. Can you squash/rebase on latest master?

…ecause this is what I have seen in examples and docs
Copy link
Contributor

@humphd humphd left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great job getting the commits fixed, I know that wasn't fun.

@@ -8,6 +8,7 @@ const routes = require('./routes');
require('./authentication');

const service = new Satellite({
cors: { origin: 'https://telescope.cdot.systems', credentials: true },
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The trouble we'll have here is that the origin is different depending on how you run the app: dev, staging, production.

We store this value in an environment variable named WEB_URL. It's different on every deployment. So here you should use process.env.WEB_URL.

However, we don't seem to expose this to our SSO container, see https://github.com/Seneca-CDOT/telescope/blob/master/docker/docker-compose.yml#L74-L96. You need to add it there.

And in our local dev env file https://github.com/Seneca-CDOT/telescope/blob/master/src/api/sso/env.local, which should mimic what we have in https://github.com/Seneca-CDOT/telescope/blob/master/config/env.development#L31.

There might be other things we need to make this work, but that's a start.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I will try this soon, is it ok if this takes a day or two? I am backed up a bit on other school work.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, leave this for a while, it's not important in the next week or so.

@manekenpix manekenpix changed the title #3794 Fixes #3794: SSO broken Jan 28, 2023
@manekenpix manekenpix added the area: sso Authentication label Jan 28, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: sso Authentication
Projects
None yet
Development

Successfully merging this pull request may close these issues.

SSO broken
3 participants