Skip to content

Instantly share code, notes, and snippets.

View Jehops's full-sized avatar

Joseph Mingrone Jehops

View GitHub Profile
@Jehops
Jehops / cloud-init-devel-bootstrap.sh
Created December 5, 2022 14:36
cloud-init-devel-bootstrap
#!/bin/sh
mkdir -p /var/lib/cloud/seed/nocloud
cd /var/lib/cloud/seed/nocloud
fetch https://gist.githubusercontent.com/Jehops/ca920552f1a00cc0d0dbe78746020f46/raw/590d532d5ea92ea5259ea0cf5205fbc2405b4c9a/meta-data
fetch https://gist.githubusercontent.com/Jehops/29a61b51fef2977bf5248362742faa06/raw/553dedfe24dde1b489b66809a162f6790849c735/user-data
echo "cloudinit_enable=YES" >> /etc/rc.conf
service cloudinitlocal start
service cloudinit start
service cloudconfig start
service cloudfinal start
@Jehops
Jehops / meta-data
Created December 5, 2022 14:32
cloud-init-devel-metadata
instance-id: iid-local01
local-hostname: fbsd14-amd64-cloudinit-test
@Jehops
Jehops / user-data
Created December 5, 2022 14:27
cloud-init-devel-user-data
#cloud-config
hostname: fbsd14-amd64-cloudinit-test
prefer_fqdn_over_hostname: false
manage_etc_hosts: localhost
password: passw0rd
chpasswd:
expire: False
ssh_pwauth: True
@Jehops
Jehops / gist:ed3d60b103df439ecea782bd9ed37fec
Created November 30, 2018 18:23
grepping 'User-Agent:' from FreeBSD Developers' Mail
601 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:52.0) Gecko/20100101
274 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.11; rv:45.0)
242 User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.3 (berkeley-unix)
229 User-Agent: Mutt/1.7.1 (2016-10-04)
227 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:45.0) Gecko/20100101
216 User-Agent: NeoMutt/20180716
209 User-Agent: Mutt/1.10.1 (2018-07-13)
198 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.11; rv:52.0)
188 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:52.0) Gecko/20100101
183 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:60.0) Gecko/20100101
@Jehops
Jehops / ipfw.sh
Last active October 12, 2022 19:06
ipfw config
#!/bin/sh
# This is an attempt at an ipfw config for a cluster with a master node and many
# compute nodes. The master node is acting as a gateway for the compute nodes
# in the LAN (192.168.0.0/24).
#
# A jail running on one of the compute nodes with address 192.168.0.118 is to be
# accessible from the outside (using redirect_addr 192.168.0.118
# 129.173.118.118). The address 129.173.118.118 is an alias for the WAN
# interface that will only be used to direct traffic to this jail.
@Jehops
Jehops / package.json
Created August 4, 2017 14:11
Mastodon's yarn.lock and (patched) package.json
{
"name": "mastodon",
"license": "AGPL-3.0",
"scripts": {
"postversion": "git push --tags",
"build:development": "cross-env RAILS_ENV=development ./bin/webpack",
"build:production": "cross-env RAILS_ENV=production ./bin/webpack",
"manage:translations": "node ./config/webpack/translationRunner.js",
"start": "node ./streaming/index.js",
"test": "yarn run test:lint && yarn run test:mocha",
@Jehops
Jehops / gist:dc66442e7f5327a46e52
Created February 10, 2016 04:42
Dead hop at Bell/Dal
% traceroute dal.ca
traceroute to dal.ca (129.173.31.187), 64 hops max, 40 byte packets
1 192.168.2.1 (192.168.2.1) 1.409 ms 1.579 ms 1.329 ms
2 loop0.6cw.ba17.hlfx.ns.aliant.net (142.176.50.10) 2.338 ms 5.680 ms 4.566 ms
3 ae15-182.cr02.hlfx.ns.aliant.net (142.166.181.141) 4.817 ms
BE14-181.cr01.hlfx.ns.aliant.net (142.166.181.125) 7.527 ms 6.200 ms
4 xe-1-0-0.gw01.hlfx.ns.aliant.net (142.176.53.115) 4.421 ms
xe-0-0-0.gw01.hlfx.ns.aliant.net (142.176.53.99) 2.337 ms
xe-1-0-0.gw01.hlfx.ns.aliant.net (142.176.53.115) 3.849 ms
5 142.177.149.186 (142.177.149.186) 4.422 ms 4.257 ms 4.113 ms
@Jehops
Jehops / gnus-html-article-overrides.el
Last active August 28, 2015 18:17
Modified versions of the Gnus functions gnus-article-browse-html-article and gnus-article-browse-html-parts
;; These modifications are potentially dangerous. Read the description below carefully!
;;
;; Opening an HTML message in an external browser with
;; gnus-article-browse-html-article creates temporary files (by default in /tmp)
;; and points your browser to the URL file:///tmp/mm-blah.html. If you're
;; running Emacs over an ssh tunnel, Conkeror/Firefox will send that URL to the
;; client browser. Of course, the files in /tmp aren't accessible on the
;; client. The modifications here cause the files to be placed in a web
;; accessible location defined in the variable gnus-tmp-www-dir, changes file
;; permissions, and updates the URL for the HTML message to be