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

Hosting the new website #30

Closed
dashohoxha opened this issue Jul 18, 2019 · 17 comments
Closed

Hosting the new website #30

dashohoxha opened this issue Jul 18, 2019 · 17 comments

Comments

@dashohoxha
Copy link

Deployment

There is no need for running a server, and doing so is in our experience a significant drain on the time of maintainers.

  1. Netlify. Using netlify is free until 100GB of bandwidth is used. Additional bandwidth costs $20/100GB. They support a global CDN system, which will keep load times quick for users in other regions. Netlify also has Github integration, which will allow for easy deployment. When a pull request is merged, Netlify will automatically deploy the changes. DNS is simple, and HTTPS is also supported.

  2. Github Pages. Github Pages also has a 100GB bandwidth limit, and is unclear if additional bandwidth can be purchased. It is also unclear where sites are deployed, and should be assumed sites aren't deployed globally. Github Pages has an easy to use CI & DNS, similar to to Netlify. HTTPS is supported.

  3. Cloudflare. An excellent option, additional CI is likely needed for the same ease of deployment.

All of the above options are appropriate for the NumPy site based on current traffic. Updating to a new deployment strategy, if needed, should take several hours at most and is inconsequential. If a provider such as Cloudflare is chosen, additional CI may be required, such as CircleCI, to have a similar deployment to GitHub Pages or Netlify.

@dashohoxha
Copy link
Author

If moving from GitHub pages is an option, then I would prefer GitLab Pages. They support Hugo out of the box (and many other site generators as well):

This means that as soon as a commit is made (or a merge request accepted), the website will be updated automatically. This simplifies and improves the workflow for making changes to the website, because everyone can contribute, even small changes/correction, straight from the web interface of GitLab.

This would also simplify the workflow for translations, in case we decide to support them. The translators can work directly on the web interface of GitLab, and finally submit a merge request, which can be accepted by language admins.

@rgommers
Copy link
Member

If moving from GitHub pages is an option

I think you mean moving the repo away from GitHub? That's not really an option. Moving the deployment is, whatever works.

@dashohoxha
Copy link
Author

I mean moving numpy/numpy.org to GitLab, not numpy/numpy etc. I know that it is not convenient to have repositories hosted in different places, so I am almost sure that nobody will accept this.

@joelachance
Copy link
Collaborator

@dashohoxha I'm pretty sure Github has the same functionality you're mentioning. See below:

https://pages.github.com/
https://github.com/features/integrations

Netlify gives us a little more visibility into bandwidth, but both should be very similar for deployment.

@rgommers
Copy link
Member

rgommers commented Aug 7, 2019

One thing I liked about Cloudflare is that you get good statistics, e.g. unique visitors per month. Stefan just moved numpy.org under the NumFOCUS Cloudflare account. Not sure if GitHub Pages offers that. For scipy.org (not admin'ed by NumFOCUS) we just have raw server logs, which is much more painful.

@joelachance
Copy link
Collaborator

I doubt Github Pages or Netlify offers any native analytics. One (free) option is Google Analytics, which would give us unique visitors and locations. This might be nice to know what translations we might want to tackle. This is just a script tag we add to the page, so we could use this with any deployment method.

Do you happen to have more info on either Cloudflare analytics or how it was deployed? I might be able to dig something up.

@rgommers
Copy link
Member

rgommers commented Aug 7, 2019

Google Analytics should give us enough info. Some Cloudflare data, also useful as a reference so we can see how much more traffic a new site gets :)

image

image

image

@joelachance
Copy link
Collaborator

Looks like either would work great!

@stefanv
Copy link
Contributor

stefanv commented Aug 8, 2019

GitHub does not do Hugo page builds, so for that we'd currently use Travis-CI—as we currently do to build the NEPs and devdocs. I think there's nothing stopping us, in principle, from using GitLab or Netlify for deployment. As mentioned by others, we already have Cloudflare set up to handle the bandwidth issue.

@rgommers
Copy link
Member

rgommers commented Aug 8, 2019

@stefanv for staying with GitHub Pages there's now GitHub Actions, which since today has CI/CD in beta. That saves messing around with permissions and API tokens to run a simple website build and deploy.

@InessaPawson InessaPawson added this to Backlog in NumPy.org Redesign Aug 30, 2019
@Shekharrajak
Copy link
Member

Relevent discussion: Shekharrajak/poc-hugo#3 (comment)

@InessaPawson
Copy link
Member

One (free) option is Google Analytics, which would give us unique visitors and locations. This might be nice to know what translations we might want to tackle. This is just a script tag we add to the page, so we could use this with any deployment method.

@joelachance @rgommers Now, that we are so close to the launch, let's set up an account with Google Analytics.

@InessaPawson InessaPawson moved this from Backlog to In progress in NumPy.org Redesign Mar 22, 2020
@rgommers
Copy link
Member

We already have Cloudflare set up, which gives the analytics I put a screenshot for above. I think we're good here for now, I don't see an issue staying with GitHub Pages + Cloudflare.

@joelachance
Copy link
Collaborator

I mostly haven't been apart of any work in this ticket, but is there still work to be done here or can we close this ticket? @rgommers

@rgommers
Copy link
Member

Let's close it - we'll do the first deploy manually I think, and deal with auto-deploy to GH Pages once we have some more safeguards in place.

NumPy.org Redesign automation moved this from In progress to Done Mar 22, 2020
@InessaPawson
Copy link
Member

@stefanv for staying with GitHub Pages there's now GitHub Actions, which since today has CI/CD in beta. That saves messing around with permissions and API tokens to run a simple website build and deploy.

@rgommers I thought we were leaning towards GitHub Actions.

If Cloudflare is preferred, frankly I'd still set up with Google Analytics to get insight on keywords/phrases that are driving traffic to the website. That would give us a better understanding of what content is missing or needs to be expanded, as well as optimize the footer by including the links to the most visited pages. I’m sure we will uncover some interesting data that I’m not even thinking of right now.

@rgommers
Copy link
Member

@rgommers I thought we were leaning towards GitHub Actions.

It's just a "can't keep postponing the launch forever" - it's not a hard requirement to do via CI, so can do after first launch (if we want it to be in the next 5-10 days ...).

If Cloudflare is preferred, frankly I'd still set up with Google Analytics to get insight on keywords/phrases that are driving traffic to the website. That would give us a better understanding of what content is missing or needs to be expanded, as well as optimize the footer by including the links to the most visited pages. I’m sure we will uncover some interesting data that I’m not even thinking of right now.

That sounds good, if Hugo support (https://gohugo.io/templates/internal/#google-analytics) works it should not be too much work. I'd also keep it for later though - we're really stretching to get the must-haves done.

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

No branches or pull requests

6 participants