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

Some images are being loaded from github #1815

Closed
pdpinch opened this issue Aug 11, 2023 · 12 comments
Closed

Some images are being loaded from github #1815

pdpinch opened this issue Aug 11, 2023 · 12 comments

Comments

@pdpinch
Copy link
Member

pdpinch commented Aug 11, 2023

Steps to Reproduce

  1. Visit a page on production open edx, like https://courses.mitxonline.mit.edu/learn/course/course-v1:MITxT+14.310x+3T2022/home

Expected Behavior

All MIT-specific resources should be loaded from mitxonline.mit.edu or the CDN.

Actual Behavior

logo.png and favicon.ico are loading from githubusercontent.com!

Screenshot or Screencast

image
@pdpinch
Copy link
Member Author

pdpinch commented Aug 11, 2023

Once we figure out how this is happening, we should take a look at xPRO and Residential as well.

@asadali145 asadali145 self-assigned this Sep 8, 2023
@asadali145
Copy link
Contributor

These images are kept in our code base as static assets https://github.com/mitodl/mitxpro-theme/tree/master/lms/static/images. Actually, we have just overridden it. This is how edX does https://github.com/mitodl/edx-platform/tree/master/lms/static/images and we cannot do anything about this. If we still want to do something about it please let me know.

CC: @pdpinch

@pdpinch
Copy link
Member Author

pdpinch commented Sep 11, 2023

I understand these are the correct images, but the URLs are wrong. End-users shouldn't be getting these images via github.com URLs. They should be coming from courses.mitxonline.mit.edu, or maybe the CDN.

@mitodl/devops is there something wrong with our configuration, or the deployment of this theme?

I did a quick search of the theme repo and didn't see any hard-coded links to raw.githubusercontent

@asadali145
Copy link
Contributor

This happens for the learning MFE only. For all the other tabs like progress, the URL is https://courses.mitxonline.mit.edu/static/mitxonline/images/logo.0a44f80f6467.png. Not really sure what's wrong with the learning MFE. Digging a bit more into the Learning MFE.

@asadali145
Copy link
Contributor

logo.png and favicon.ico are set in .env and are coming from https://github.com/mitodl/ol-infrastructure/blob/c30a498638c6f2cfda797724f579e91687e76c33/src/ol_concourse/pipelines/open_edx/mfe/values.py#L10. @mitodl/devops | @blarghmatey Could we change this?

@asadali145 asadali145 removed their assignment Sep 13, 2023
@shaidar
Copy link
Contributor

shaidar commented Sep 15, 2023

This can be changed and will require us to update the pipeline to push those images to S3 and then load them through Fastly instead of GitHub.

@pdpinch
Copy link
Member Author

pdpinch commented Mar 15, 2024

update the pipeline to push those images to S3 and then load them through Fastly instead of GitHub.

@blarghmatey how big of an effort is this?

We're updating the logos now in mitodl/ol-infrastructure#2270 and it just seems wrong to me to serve them from raw.githubusercontent.com!

@asadali145
Copy link
Contributor

We're updating the logos now in mitodl/ol-infrastructure#2270 and it just seems wrong to me to serve them from raw.githubusercontent.com!

@pdpinch Tobias was suggesting the use of raw.githubusercontent.com in https://github.com/mitodl/hq/discussions/3778#discussioncomment-8801934. I think he missed your above comment. Should I use GitHub for MITx or should I wait?

@blarghmatey FYI

@blarghmatey
Copy link
Member

Are we able to close this now?

@pdpinch pdpinch self-assigned this Mar 29, 2024
@blarghmatey
Copy link
Member

@pdpinch is this ready to be closed now?

@pdpinch
Copy link
Member Author

pdpinch commented Apr 16, 2024

I'm still seeing the logo and two (?) requests for the favicon going to raw.githubusercontent.com from the page at https://courses.mitxonline.mit.edu/learn/course/course-v1:MITxT+14.310x+3T2022/home

https://raw.githubusercontent.com/mitodl/mitxonline-theme/main/lms/static/images/logo.png
https://raw.githubusercontent.com/mitodl/mitxonline-theme/main/lms/static/images/favicon.ico

image

On the Studio side, everything seems to come from courses.mitxonline.mit.edu, which is better. I tested an MFE page and a legacy theme page.

@pdpinch pdpinch assigned blarghmatey and unassigned pdpinch Apr 26, 2024
@blarghmatey
Copy link
Member

The corresponding logos in QA are loading from the theme rather than GitHub, so I am going to close this as all of the necessary configuration changes have been made. We are just waiting on a production deploy of edX and MFEs for MITx Online.

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

No branches or pull requests

4 participants