That is is basically a "fork" of blog article i'm constantly returning to. It seems that the blog is down:
Dave Bass proposed this which I picked up for my implementation (here for an 8-chars token):
| require "active_record" | |
| ActiveRecord::Base.establish_connection(adapter: "sqlite3", database: ":memory:") | |
| ActiveRecord::Migration.class_eval do | |
| create_table(:records) do |t| | |
| t.string :column | |
| end | |
| end | |
| data = 50_000.times.map { |i| Hash[column: "Column #{i}"] } |
That is is basically a "fork" of blog article i'm constantly returning to. It seems that the blog is down:
Dave Bass proposed this which I picked up for my implementation (here for an 8-chars token):
| import React from 'react'; | |
| import { shallow } from 'enzyme'; | |
| import MyComponent from '../src/my-component'; | |
| const wrapper = shallow(<MyComponent/>); | |
| describe('(Component) MyComponent', () => { | |
| it('renders without exploding', () => { | |
| expect(wrapper).to.have.length(1); | |
| }); |
| ---/usr/share/source-highlight/lang.map.old | |
| +++/usr/share/source-highlight/lang.map | |
| @@ -169,3 +169,5 @@ | |
| groovy = groovy.lang | |
| json = json.lang | |
| feature = feature.lang | |
| +yaml = yaml.lang | |
| +yml = yaml.lang |
| # Keep delayed job workers running using systemd on ubuntu | |
| # Usage | |
| # Start "sudo systemctl start delayed_job@{0..3}" to start 4 worker instances | |
| # Enable "sudo systemctl enable delayed_job@{0..3}" to enable 4 worker instances | |
| # Restart "sudo systemctl restart delayed_job@{0..3}" to restart 4 worker instances | |
| # Disable "sudo systemctl disable delayed_job@{0..3}" to disable 4 worker instances | |
| # Stop "sudo systemctl stop delayed_job@{0..3}" to stop 4 worker instances | |
| [Unit] | |
| Description=Delayed Job Worker %i |
The proposal you’re about to read is not just a proposal. We have a working implementation of almost everything we discussed here. We encourage you to checkout and build our branch: our fork, with the relevant branch selected. Building and using the implementation will give you a better understanding of what using it as a developer is like.
Our implementation ended up differing from the proposal on some minor points. As our last action item before making a PR, we’re writing documentation on what we did. While I loathe pointing to tests in lieu of documentation, they will be helpful until we complete writing docs: the unit tests.
This repo also contains a bundled version of npm that has a new command, asset. You can read the documentation for and goals of that comma
| # | |
| # A: | |
| # pubsub = PgPubSub.new('channelname') | |
| # pubsub.subscribe do |data| | |
| # puts "data: #{data} is coming!" | |
| # end | |
| # | |
| # B: | |
| # pubsub = PgPubSub.new('channelname') | |
| # pubsub.publish("hello world") |
| # Use this validator like this | |
| # | |
| # class User < ApplicationRecord | |
| # validates :profile_link, url: true | |
| # end | |
| class UrlValidator < ActiveModel::EachValidator | |
| def validate_each(record, attribute, value) | |
| unless valid_url?(value) | |
| record.errors.add(attribute, :invalid_url) |
| # frozen_string_literal: true | |
| module Fingerprinting | |
| def full_fingerprint | |
| generate_fingerprint( | |
| ip_fingerprint, | |
| browser_fingerprint | |
| ) | |
| end |
This guide is for homelab admins who understand IPv4s well but find setting up IPv6 hard or annoying because things work differently. In some ways, managing an IPv6 network can be simpler than IPv4, one just needs to learn some new concepts and discard some old ones.
Let’s begin.
First of all, there are some concepts that one must unlearn from ipv4:
Concept 1