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

Setup Netlify site for yard docs #3019

Merged
merged 6 commits into from
Jan 12, 2019
Merged

Conversation

tvdeyen
Copy link
Member

@tvdeyen tvdeyen commented Jan 3, 2019

Preparations for deploying the yard docs on Netlify.

We want to deploy several sites from the same repo (guides and docs) and
therefore need to use the admin UI to configure them.
We do not need to install all three database adapters at once.
As we already set the `DB` env var during CI builds and the local
sandbox runs with sqlite anyway, we can safely only install these gems
on demand.
@kennyadsl
Copy link
Member

@tvdeyen is the Netlify failure normal here?

@tvdeyen
Copy link
Member Author

tvdeyen commented Jan 3, 2019

@kennyadsl No. I need to make some more adjustments. Stay tuned

Although there is the `--yardopts` file option and we only build docs
for the `/core` (yet), I think it is best to share the options for all
subfolders.

Also does not require the gem on boot as we only run yard via command
line anyway.
@tvdeyen tvdeyen changed the title Remove netlify config file Setup Netlify site for yard docs Jan 3, 2019
@tvdeyen
Copy link
Member Author

tvdeyen commented Jan 3, 2019

@kennyadsl ready ✅

@tvdeyen tvdeyen requested a review from kennyadsl January 3, 2019 09:43
@tvdeyen
Copy link
Member Author

tvdeyen commented Jan 3, 2019

Ideally we would only install gems that are necessary to build the docs (namely yard), but this would make it necessary to alter the install command on Netlify. Anyhow the gems are cached and this is working for now. We can make this change later if we want to safe some resources 🌳

Copy link
Member

@kennyadsl kennyadsl left a comment

Choose a reason for hiding this comment

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

Thanks @tvdeyen !!!!

@tvdeyen
Copy link
Member Author

tvdeyen commented Jan 3, 2019

@kennyadsl thanks.

I was able to disable all gem groups we don't need with setting the ENV var

BUNDLE_WITHOUT=core api frontend backend utils ci

in the Netlify admin.

This should safe some resources 🐳

The local Gemfile (only used for CI and tooling) was grouped for
frontend and backend only yet. In order to be able to install only a
subset of gems (for generating docs for example) we should group all
gems.
@tvdeyen
Copy link
Member Author

tvdeyen commented Jan 3, 2019

By grouping all gems I was able to reduce the gems needed to install to just yard \o/

https://app.netlify.com/sites/solidus-docs/deploys/5c2de220b7945d0008107d6c

@tvdeyen
Copy link
Member Author

tvdeyen commented Jan 3, 2019

With that gem grouping change we should be able to only install the gems needed to build the current sub project. Currently we are always installing all gems for each subproject. I will prepare another PR to make the changes.

Copy link
Member

@kennyadsl kennyadsl left a comment

Choose a reason for hiding this comment

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

Thanks @tvdeyen !!!

Copy link
Contributor

@jacobherrington jacobherrington left a comment

Choose a reason for hiding this comment

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

🎉

@tvdeyen tvdeyen merged commit 520c331 into solidusio:master Jan 12, 2019
@tvdeyen tvdeyen deleted the add-docs-site branch January 12, 2019 14:15
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.

None yet

3 participants