sadetutka

package module
v0.0.0-...-c813b1a Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 2, 2022 License: Apache-2.0 Imports: 1 Imported by: 0

README

⬆️ For table of contents, click the above icon

Build status

What?

I wanted to display local weather + animated rain map in my home automation dashboard. There was no clean integration via data layer, so I had to resort to browser-based scraping (because I didn't want to use an iframe either)

This runs on AWS Lambda.

It basically produces these images:

IMPORTANT! If you're planning on linking to these files, do not copy GitHub's camo URL directly! It'll prevent caching and cost me unnecessary bandwidth! The raw URLs are:

https://function61.com/files/sadetutka/meteogram.png?utm_source=gh

https://function61.com/files/sadetutka/latest.gif?utm_source=gh

Source data for images

From data in https://www.foreca.fi/Finland/Tampere

How?

Internally, this uses chrome-server microservice (also runs on Lambda, but it's behind a standard HTTP API).

Why is this public?

I shared this not because it's ready-to-use for anybody else, but in the hopes if the techniques help anybody else.

Debug

If the script has broken, run $ bob dev and it'll give you pro-tips for debugging.

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ScraperScript embed.FS

Functions

This section is empty.

Types

This section is empty.

Directories

Path Synopsis
cmd

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL