Creating a user/password login for Distill and/or Quarto website in R

439 Views Asked by At

I am currently creating a distill website through R (hopefully to transition to Quarto, but still using distill). Currently, the R code is connected with GitHub to publish the website, and this will mainly be for internal use within my department. There is concern with the public availability if the website's link gets out.

I was wondering if there was a way to build into the R code a way to assign usernames and passwords for our personnel, which will force a login portal when someone accesses the link.

I am fairly new to allow of this website development through R, so an example would be very helpful! Thanks!

1

There are 1 best solutions below

1
On

To manage credentials, you need server-side code. GitHub Pages is static, so there's no server for you to run it on.

You have a couple of options:

  1. Host the site on a server and manage access using something like a htaccess file
  2. Change the GitHub page to be private. Note that you'd then need to give anyone who needs access read access to the repo, which would mean that they would need to have a GitHub login.