diff options
author | Stefan Kreutz <mail@skreutz.com> | 2020-07-15 15:47:23 +0200 |
---|---|---|
committer | Stefan Kreutz <mail@skreutz.com> | 2020-07-15 15:47:23 +0200 |
commit | 949f69dbaee82001ea683548a24102af4f545487 (patch) | |
tree | eb5ee7aeaff2253aa46bd640eb9231abe45596d2 | |
parent | 9452bef415d61cceff15a6f3cc88cc624e9cb0c7 (diff) | |
download | blog-949f69dbaee82001ea683548a24102af4f545487.tar |
Submit sitemap to search engines after deployment
-rwxr-xr-x | deploy | 14 |
1 files changed, 14 insertions, 0 deletions
@@ -4,6 +4,8 @@ # # Re-generates the static website from source and asserts a clean working tree # before uploading the website to the server. +# +# Submits the live sitemap to Google and Bing. set -o errexit set -o nounset @@ -39,3 +41,15 @@ scp "${archive}" engine.skreutz.com:www-archive/ rsync --rsync-path=openrsync --archive --delete --verbose \ "${src}" "engine.skreutz.com:/var/www/htdocs/www.skreutz.com" + +curl \ + --silent \ + --output /dev/null \ + http://www.google.com/ping?sitemap=https://www.skreutz.com/sitemap.xml \ + || ( >&2 printf "error: failed to submit live sitemap to google.com\\n" ) + +curl \ + --silent \ + --output /dev/null \ + http://www.bing.com/ping?sitemap=https%3A%2F%2Fwww.skreutz.com/sitemap.xml \ + || ( >&2 printf "error: failed to submit live sitemap to bing.com\\n" ) |