Skip to content

Instantly share code, notes, and snippets.

@richb-hanover
richb-hanover / Installing_Homenet.md
Last active Jan 6, 2021
Installing Homenet on LEDE/OpenWrt (DRAFT)
View Installing_Homenet.md

Installing Homenet on your Router

This set of instructions configures a fresh LEDE installation to run Homenet. They will likely work on a current build of OpenWrt.

There's lots of good info about Homenet elsewhere. See the External References section (below).

The general strategy is to connect your computer to the router's LAN Ethernet, convert the wireless and WAN interfaces to run Homenet, and test the changes so far. After things are working, configure the LAN Ethernet to Homenet through connect one of the (now Homenet) wireless interfaces.

  1. Install LEDE on your router. See the main Getting Started with LEDE page for details.
View change-astra-header-breakpoint-width.md

In Astra Theme, the default header breakpoint is 921px. That means mobile header will be triggered at 921px screen size.

To change the default header breakpoint, edit the astra_header_break_point in a child theme. In the example below, the mobile header will be triggered at 1120px screen size. Change 1120 to the screen size of your choice.

/**
 * Change the breakpoint of the Astra Header Menus
 * 
 * @return int Screen width when the header should change to the mobile header.
 */
@richb-hanover
richb-hanover / how-to-install-astra-child-theme.md
Created Apr 30, 2018
"How to Install Astra Child Theme" suggestion
View how-to-install-astra-child-theme.md

Child theme makes it easy to customize the theme files without having to worry about any updates breaking the changes you have made in the theme files.

You can generate a child theme for Astra from here.

  1. Enter the name you wish to give your child theme.
  2. If you want to add your own branding, click on advanced options and where you can edit the Theme name, version, author, author URL, description, folder name and screenshot.
  3. Once done, click on Generate. The child theme you just generated gets downloaded on your computer.
  4. You can now install it like any other WordPress theme.
  5. Feel free to copy any necessary Astra theme files in this child theme and customize them as you need.
@richb-hanover
richb-hanover / setup_accounts.yml
Created Apr 7, 2020
Ansible playbook for the *very first* connection to a newly-provisioned VPS
View setup_accounts.yml
---
##############################################################
#
# setup_accounts.yml
#
# This Ansible playbook configures the accounts for an initial
# connection to a newly provisioned VPS. It performs the following tasks:
#
# 1. Log into the target server using the root password (not public key)
@richb-hanover
richb-hanover / conedata.js
Created Jun 22, 2020
Generate a "cone of data" - 24 "hours" of 30-second samples that have increasing variance
View conedata.js
/**
* Generate a "cone of data" centered around a median value
*
* There will be 24 rows of data, each containing 120 samples.
* Each row is centered around a "median" value of 50
* Each row's sample is a random value multiplied by the "hour" so that
* later hours have a larger spread.
*
* This should have an obvious appearance in a plot
*/
View Install-YAMon4-on-OpenWrt.md

Installing YAMon on OpenWrt

The following steps will install the YAMon (Yet Another MONitor) software on your OpenWrt router. This procedure requires use of an SSH connection to your router.

Note: The procedure below has been tested with OpenWrt 19.07.

Prepare a USB drive for the router

You need external storage (for example, a USB memory stick) to hold the data collected by YAMon.