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

DOP-3996: Chatbot server url #880

Merged
merged 5 commits into from
Sep 6, 2023
Merged

DOP-3996: Chatbot server url #880

merged 5 commits into from
Sep 6, 2023

Conversation

mmeigs
Copy link
Collaborator

@mmeigs mmeigs commented Sep 5, 2023

Stories/Links:

DOP-3996

Notes:

The chatbot team would like our non-prod environments to point the Chatbot towards their staging link. This uses the SNOOTY_ENV to determine this.

Would love a second pair of eyes and confirmations on the fact that SNOOTY_ENV's values could all be 'production' and 'dotcomprd'

src/components/ChatbotUi.js Outdated Show resolved Hide resolved
@@ -5,6 +5,11 @@ import { css } from '@emotion/react';
import { theme } from '../theme/docsTheme';
import 'react-loading-skeleton/dist/skeleton.css';

const CHATBOT_SERVER_BASE_URL =
process.env.SNOOTY_ENV === 'production' || process.env.SNOOTY_ENV === 'dotcomprd'
Copy link
Collaborator

Choose a reason for hiding this comment

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

Would love a second pair of eyes and confirmations on the fact that SNOOTY_ENV's values could all be 'production' and 'dotcomprd'

Double-checked our current task definitions and it seems like these are the only 2 prod-based values we'd expect

@mmeigs mmeigs merged commit bc88792 into master Sep 6, 2023
2 checks passed
@mmeigs mmeigs deleted the DOP-3996-chatbot-url branch September 6, 2023 17:48
@@ -5,6 +5,11 @@ import { css } from '@emotion/react';
import { theme } from '../theme/docsTheme';
import 'react-loading-skeleton/dist/skeleton.css';

const CHATBOT_SERVER_BASE_URL =
process.env.SNOOTY_ENV === 'production' || process.env.SNOOTY_ENV === 'dotcomprd'
Copy link
Collaborator

Choose a reason for hiding this comment

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

I know this PR is already approved and merged, but I just remembered that I should have asked this:

Does the chatbot team want us to use the staging API for GitHub staging jobs and the production API for only production deployments? If so, we might need to update this logic to exclude process.env.SNOOTY_ENV === 'production'. @caesarbell might have some insight.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

oo @rayangler just getting fully caught up on my email and saw this! I think I might be confused at what SNOOTY_ENV === 'production' would mean in this case? Is writers staging using the value "production"?

Copy link
Collaborator

Choose a reason for hiding this comment

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

Is writers staging using the value "production"?

Yes, I believe so, based on its value in this task definition. SNOOTY_ENV can be seen as representative of the overall environment that Snooty is being ran within the context of the Autobuilder, with "production" being "prd" and "dotcomprd" being "dotcomprd".

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Ok, great catch. Thank you! I'll open up a PR!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants