Using a Custom Landing Page#
Overview#
It is possible to specify a custom landing page that your anonymous/logged-out users see when they visit RStudio Connect.
Configuration#
Use the Server.LandingDir
setting to
specify a path to a directory containing a custom landing page. The directory
cannot be inside RStudio Connect's installation directory (typically
/opt/rstudio-connect
).
Custom Landing Page Assets#
Include all assets (JavaScript, CSS, images, etc.) for your custom landing page
in the directory you specified in the Server.LandingDir
setting.
Be sure to include an index.html
, which will be served by default.
Example#
RStudio Connect includes an example landing page in the
/opt/rstudio-connect/examples/landing-page
directory.
To begin customizing your landing page, copy the example landing directory to a location of your choice outside of the RStudio Connect installation directory. For example:
cp -r /opt/rstudio-connect/examples/landing-page /usr/local/share/rstudio-connect-customizations/landing-page
Then set Server.LandingDir
to the location of your copy:
; /etc/rstudio-connect/rstudio-connect.gcfg
[Server]
LandingDir = /usr/local/share/rstudio-connect-customizations/landing-page
Note
Your custom landing page directory must be located outside of RStudio
Connect's installation directory (typically /opt/rstudio-connect
).
RStudio Connect will not start if Server.LandingDir
points to a location
under this directory, because these files may be overwritten when RStudio
Connect is updated.