-
-
Notifications
You must be signed in to change notification settings - Fork 5.7k
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
Chore: Clean up server implementation and update test docs #2316
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks like the deployments are not working now (I'm guessing the index.html change) and needs an update so that we can verify it works.
This is nice though! Nice to consolidate some duplication!
Thanks for the quick review and approval, @trusktr!
Correct.
Ahh, yes. Hadn't considered the deployments. I'm not familiar with our Vercel setup nor do I know if I have access to change it (I'm not at my computer right now). @sy-records? This seems like the stuff we always count on you to handle 😊. If I already have access to Vercel I can look into it when I get home. If I don't, would you mind granting access to Vercel when you have a moment? |
Can Vercel serve files using our npm
If Vercel only serves static files, I will need to update the PR to accommodate. This would explain the need for the additional FYI: Currently the PR only supports serving the |
Okay. I got it. Let me try. |
I did a little research and it doesn't look like Vercel will allow us to serve files via our own server / script. We can use serverless functions to serve files with our own server (see here), but the implementation feels like a hack and will force our previews to be served under an Unless there are other suggestions, I think the easiest solution is create a separate I'm open to other suggestions, too. 😄 |
After check the docs, I have a simple redirect config in |
All set! Vercel preview deployments are working again. I've update the summary above to include the new changes. The changes made specifically to address the preview deployments are:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Goog job!
Hi @jhildenbiddle I thought we gonna remove the duplicated About the pages and preview issues, we could enhance CI stuff to do adoptions, thats why I try to config vercel and custom github pages flow. In current changes, we delete the root If we decide use this
If we decide to do those thing in CI part, I could move on in the #2317. WDYT? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Update:
Separate this PR as 2 parts:
- Clean up server implementation. (live-server, remove
/index.html
) - How to adapt the deploy stuff. (preview, github pages)
In order to keep things move on, I think we could approve the changes and left my questions, it could be discussed and do the refinements later.
Hi, @jhildenbiddle , plz go ahead and we can merge it asap.
Apologies for the slow response, @Koooooo-7. I got pulled away on some other projects.
Perfect. This is exactly what I was going to suggest. :) |
# Conflicts: # package-lock.json
d9a7f30
Summary
This PR cleans up our server configuration as discussed in #2104 and #2218. The simplified end result is:
index.html
files to maintain (/index.html
and/docs/index.html
)/index.html
and/themes/
)Details:
server.config.js
)serve
script to serve/docs
in production modeserve:dev
script to serve/docs
in development modebuild:html
script to generate/docs/preview.html
from/docs/index.html
vercel.json
file to handle preview redirect to/docs/preview.html
DocsifyCarbon.create
error./test/README.md
index.html
file in root (no longer needed)/themes
directory in root (no longer needed)Related issue, if any:
#2218
What kind of change does this PR introduce?
Other
For any code change,
Does this PR introduce a breaking change?
No