From 58842d03a95af014cb44c3495d109e3bb6731fde Mon Sep 17 00:00:00 2001 From: bnewbold Date: Sat, 13 Apr 2024 12:20:06 -0700 Subject: rebased embedr (#3511) * skeleton of embedr service, based on bskyweb * embedr container setup * builds on this branch * actual routes * fix embedr go:embed * tweak embedr dockerfile * progress on embedr * fix path params * tweaks to build process * try to get embedr dockerfile to install embed deps * build this branch * updates to match sam's output HTML * try to unbreak embedr dockerfile * small embedr tweak * docker hack * get embed.js copied over to embedr * don't x-frame-options for embed.bsky.app * bskyembed: remove a console.log * use html/template for golang snippet generation * simplify embedr API fetches * missing file * Rm console.log fully --------- Co-authored-by: Dan Abramov --- bskyweb/embedr-static/.well-known/security.txt | 4 ++++ bskyweb/embedr-static/embed.js | 1 + bskyweb/embedr-static/favicon-16x16.png | Bin 0 -> 1731 bytes bskyweb/embedr-static/favicon-32x32.png | Bin 0 -> 2240 bytes bskyweb/embedr-static/favicon.png | Bin 0 -> 1412 bytes bskyweb/embedr-static/iframe-resize.js | 1 + bskyweb/embedr-static/ips-v4 | 30 +++++++++++++++++++++++++ bskyweb/embedr-static/ips-v6 | 0 bskyweb/embedr-static/robots.txt | 9 ++++++++ 9 files changed, 45 insertions(+) create mode 100644 bskyweb/embedr-static/.well-known/security.txt create mode 100644 bskyweb/embedr-static/embed.js create mode 100644 bskyweb/embedr-static/favicon-16x16.png create mode 100644 bskyweb/embedr-static/favicon-32x32.png create mode 100644 bskyweb/embedr-static/favicon.png create mode 100644 bskyweb/embedr-static/iframe-resize.js create mode 100644 bskyweb/embedr-static/ips-v4 create mode 100644 bskyweb/embedr-static/ips-v6 create mode 100644 bskyweb/embedr-static/robots.txt (limited to 'bskyweb/embedr-static') diff --git a/bskyweb/embedr-static/.well-known/security.txt b/bskyweb/embedr-static/.well-known/security.txt new file mode 100644 index 000000000..8173cb72d --- /dev/null +++ b/bskyweb/embedr-static/.well-known/security.txt @@ -0,0 +1,4 @@ +Contact: mailto:security@bsky.app +Preferred-Languages: en +Canonical: https://bsky.app/.well-known/security.txt +Acknowledgements: https://github.com/bluesky-social/atproto/blob/main/CONTRIBUTORS.md diff --git a/bskyweb/embedr-static/embed.js b/bskyweb/embedr-static/embed.js new file mode 100644 index 000000000..15964a76c --- /dev/null +++ b/bskyweb/embedr-static/embed.js @@ -0,0 +1 @@ +/* embed javascript widget will go here */ diff --git a/bskyweb/embedr-static/favicon-16x16.png b/bskyweb/embedr-static/favicon-16x16.png new file mode 100644 index 000000000..ea256e056 Binary files /dev/null and b/bskyweb/embedr-static/favicon-16x16.png differ diff --git a/bskyweb/embedr-static/favicon-32x32.png b/bskyweb/embedr-static/favicon-32x32.png new file mode 100644 index 000000000..a5ca7eed1 Binary files /dev/null and b/bskyweb/embedr-static/favicon-32x32.png differ diff --git a/bskyweb/embedr-static/favicon.png b/bskyweb/embedr-static/favicon.png new file mode 100644 index 000000000..ddf55f4c8 Binary files /dev/null and b/bskyweb/embedr-static/favicon.png differ diff --git a/bskyweb/embedr-static/iframe-resize.js b/bskyweb/embedr-static/iframe-resize.js new file mode 100644 index 000000000..6bf2793df --- /dev/null +++ b/bskyweb/embedr-static/iframe-resize.js @@ -0,0 +1 @@ +/* script to resize embed ifame would go here? */ diff --git a/bskyweb/embedr-static/ips-v4 b/bskyweb/embedr-static/ips-v4 new file mode 100644 index 000000000..087996ef9 --- /dev/null +++ b/bskyweb/embedr-static/ips-v4 @@ -0,0 +1,30 @@ +13.59.225.103/32 +3.18.47.21/32 +18.191.104.94/32 +3.129.134.255/32 +3.129.237.113/32 +3.138.56.230/32 +44.218.10.163/32 +54.89.116.251/32 +44.217.166.202/32 +54.208.221.149/32 +54.166.110.54/32 +54.208.146.65/32 +3.129.234.15/32 +3.138.168.48/32 +3.23.53.192/32 +52.14.89.53/32 +3.18.126.246/32 +3.136.69.4/32 +3.22.137.152/32 +3.132.247.113/32 +3.141.186.104/32 +18.222.43.214/32 +3.14.35.197/32 +3.23.182.70/32 +18.224.144.69/32 +3.129.98.29/32 +3.130.134.20/32 +3.17.197.213/32 +18.223.234.21/32 +3.20.248.177/32 diff --git a/bskyweb/embedr-static/ips-v6 b/bskyweb/embedr-static/ips-v6 new file mode 100644 index 000000000..e69de29bb diff --git a/bskyweb/embedr-static/robots.txt b/bskyweb/embedr-static/robots.txt new file mode 100644 index 000000000..4f8510d18 --- /dev/null +++ b/bskyweb/embedr-static/robots.txt @@ -0,0 +1,9 @@ +# Hello Friends! +# If you are considering bulk or automated crawling, you may want to look in +# to our protocol (API), including a firehose of updates. See: https://atproto.com/ + +# By default, may crawl anything on this domain. HTTP 429 ("backoff") status +# codes are used for rate-limiting. Up to a handful concurrent requests should +# be ok. +User-Agent: * +Allow: / -- cgit 1.4.1