Skip to content

Instantly share code, notes, and snippets.

@dpastoor
Created December 3, 2022 19:53
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save dpastoor/7d22d429d50811717bc1ef4e5f9c603c to your computer and use it in GitHub Desktop.
Save dpastoor/7d22d429d50811717bc1ef4e5f9c603c to your computer and use it in GitHub Desktop.
update-workbench-daily
#!/bin/bash
set -ex
DEBIAN_FRONTEND=noninteractive
rstudio-server stop
rstudio-launcher stop
JSON=$(curl -s https://dailies.rstudio.com/rstudio/latest/index.json)
DIST_JSON=$(echo "${JSON}" | jq .products.workbench.platforms['"'"bionic-amd64"'"'])
LATEST_URL=$(echo "${DIST_JSON}" | jq -r '.link')
FILENAME=$(echo "${DIST_JSON}" | jq -r '.filename')
# its bionic for both ubuntu 18 and 20
curl -o /tmp/${FILENAME} ${LATEST_URL}
gdebi --non-interactive /tmp/${FILENAME}
rm /tmp/${FILENAME}
systemctl start rstudio-launcher
systemctl start rstudio-server
systemctl enable rstudio-launcher
systemctl enable rstudio-server
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment