Skip to content

Instantly share code, notes, and snippets.

@kathampy
Created November 15, 2018 23:09
Show Gist options
  • Save kathampy/bd23710b194b8924c3b7b08b5375b6b6 to your computer and use it in GitHub Desktop.
Save kathampy/bd23710b194b8924c3b7b08b5375b6b6 to your computer and use it in GitHub Desktop.
Reinstalls cloudflared on EdgeOS after firmware upgrade
[ -e /etc/cloudflared ] || {
curl --fail https://raw.githubusercontent.com/yon2004/ubnt_cloudflared/master/cloudflared --output /usr/local/bin/cloudflared || die
chmod +x /usr/local/bin/cloudflared || die
ln -s /config/cloudflared /etc/cloudflared || die
[ -e /etc/cloudflared/config.yml ] || {
curl --fail https://raw.githubusercontent.com/yon2004/ubnt_cloudflared/master/config.yml --output /etc/cloudflared/config.yml || die
}
/usr/local/bin/cloudflared service install || die
/etc/init.d/cloudflared start || die
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment