Skip to content

Instantly share code, notes, and snippets.

@tylerthebuildor
Last active March 6, 2020 04:45
Show Gist options
  • Save tylerthebuildor/cb74faff2875c4d18383267da8eb1bda to your computer and use it in GitHub Desktop.
Save tylerthebuildor/cb74faff2875c4d18383267da8eb1bda to your computer and use it in GitHub Desktop.
Digital Ocean Ghost Blog Update

I used Digital Ocean's One-Click install for Ghost blog some time ago and then I wanted to update it. It ended up being more work then I'd hoped so hopefully this helps someone.

If you get locked out

# If you get locked out of your droplet:
# 1. upload your ~/.ssh/id_rsa.pub file to Dropbox
# 2. Then reset Digital Ocean root password
# 3. Login through the Digital Ocean web console using new password
# 4. Run:
cd ~/.ssh
wget https://dropbox.co/[your-idrsapub-file
# 5. Then Run:
cat >> authorized_keys
# This will allow you to login from your local computer with:
ssh root@[droplet-ip]

Updating Ghost

# 1. First switch users to the special "ghost-mgr" user created by Digital Ocean's One-Click install:
sudo -i -u ghost-mgr
# 2. Then try:
cd /var/www/ghost
ghost update
# or
ghost update v1
# 3. If you get a node version error:
exit # to get back to root user
curl -sL https://deb.nodesource.com/setup_10.x | sudo -E bash
sudo apt-get install -y nodejs

# repeat step 1-2

Resources

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