Skip to content

Instantly share code, notes, and snippets.

View tas50's full-sized avatar
🌪️
Producting. That's a thing right?

Tim Smith tas50

🌪️
Producting. That's a thing right?
View GitHub Profile
#!/bin/bash
if [ $# -eq 0 ]; then
echo "Box type must be specified (virtualbox, vmware_desktop, parallels)"
exit 1
fi
# Find all boxes which have updates
AVAILABLE_UPDATES=`vagrant box outdated --global 2>/dev/null | grep outdated | tr -d "*'" | cut -d ' ' -f 2`
[2020-03-12T20:05:42+00:00] FATAL: Chef::Exceptions::ResourceNotFound: resource template[/etc/apt/sources.list] is configured to notify resource execute[apt-get update] with action run, but execute[apt-get update] cannot be found in the resource collection. template[/etc/apt/sources.list] is defined in /opt/kitchen/cache/cookbooks/ubuntu/recipes/default.rb:26:in `from_file'
/opt/chef/embedded/lib/ruby/gems/2.7.0/gems/chef-16.0.131/lib/chef/resource_collection/resource_set.rb:60:in `lookup'
/opt/chef/embedded/lib/ruby/gems/2.7.0/gems/chef-16.0.131/lib/chef/resource_collection/resource_set.rb:172:in `find_resource_by_string'
/opt/chef/embedded/lib/ruby/gems/2.7.0/gems/chef-16.0.131/lib/chef/resource_collection/resource_set.rb:98:in `block in find'
/opt/chef/embedded/lib/ruby/gems/2.7.0/gems/chef-16.0.131/lib/chef/resource_collection/resource_set.rb:93:in `each'
/opt/chef/embedded/lib/ruby/gems/2.7.0/gems/chef-16.0.131/lib/chef/resource_collection/resource_set.rb:93:in `find'
/opt/chef/embedded/lib/ruby/gems/2.
❰tsmith❙~/dev/work/vscode-chef/autogeneration(git:master)❱✘≻ rake
** Invoke default (first_time)
** Invoke generate_snippets (first_time)
** Execute generate_snippets
bundle install --no-deployment
Using rake 13.0.1
Using bundler 1.17.3
Using chef-utils 16.0.50 from https://github.com/chef/chef (at master@a0645da)
1 Update docker? to be from 12.11 onwards
Using coderay 1.1.2
bundle exec rake features
/usr/local/Cellar/ruby/2.6.5/bin/ruby -S bundle exec cucumber --strict -f progress -t ~@build -t ~@context features
Deprecated: Found tags option '~@build'. Support for '~@tag' will be removed from the next release of Cucumber. Please use 'not @tag' instead.
Deprecated: Found tags option '~@context'. Support for '~@tag' will be removed from the next release of Cucumber. Please use 'not @tag' instead.
..DEPRECATED: global use of must_include from /Users/tsmith/dev/foodcritic/features/support/command_helpers.rb:247. Use _(obj).must_include instead. This will fail in Minitest 6.
...DEPRECATED: global use of must_include from /Users/tsmith/dev/foodcritic/features/support/command_helpers.rb:247. Use _(obj).must_include instead. This will fail in Minitest 6.
...DEPRECATED: global use of wont_include from /Users/tsmith/dev/foodcritic/features/support/command_helpers.rb:258. Use _(obj).wont_include instead. This will fail in Minitest 6.
...DEPRECATED: global use of wont_include from /Users/t
tourism/motel|Econo Lodge -> tourism/hotel|EconoLodge: 12 at 0.9818181818181818
tourism/motel|Econo Lodge -> tourism/hotel|Econolodge: 19 at 0.9818181818181818
tourism/motel|Econo Lodge -> tourism/motel|EconoLodge: 18 at 0.9818181818181818
tourism/motel|Econo Lodge -> tourism/motel|Econolodge: 24 at 0.9818181818181818
tourism/motel|Super 8 -> shop/supermarket|Super8: 9 at 0.9714285714285714
tourism/hotel|B&B Hôtel -> amenity/parking|B&B Hotel: 6 at 0.9555555555555556
tourism/hotel|B&B Hôtel -> tourism/hotel|B&B Hotel: 31 at 0.9555555555555556
tourism/hotel|B&B Hôtel -> tourism/hotel|B&b Hôtel: 71 at 1.0
tourism/hotel|Campanile -> tourism/hotel|Campanille: 6 at 0.98
tourism/hotel|Comfort Inn & Suites -> tourism/hotel|Comfort Inn and Suites: 17 at 0.9627272727272728
@tas50
tas50 / gist:9f7e8be30955090eb65bbbbb65d637c1
Created April 14, 2019 17:52
Use jaro winkler to analyze brand name data in OSM
#!/usr/local/opt/ruby/bin/ruby
require 'json'
require 'jaro_winkler'
# parse out all the brands files
files = Dir.glob('brands/**/*.json')
brand_data = {}
files.each { |f| brand_data.merge!(JSON.parse(File.read(f))) }
brands = brand_data.keys
Ops code Summit takeaways
Overall product roadmap
The server is being rewritten in Erlang (no longer ruby) for .11 to greatly reduce memory usage and CPU usage. There's a large push for scalability as Opscode uses the same code base on just 6 servers to do Hosted Chef
CouchDB is being replaced with MySQL as the data store to improve db response time, performance, and ease replication/maintenance
.11 will ship with DB plugins for multiple SQL servers. No word on if they may support MS SQL at some point. I will follow up with their product manager to express our interest in this use case
Windows product roadmap
.10.6 comes out next week with significant fixes for Windows support
All future releases will ship on all platforms the same day

Keybase proof

I hereby claim:

  • I am tas50 on github.
  • I am tas50 (https://keybase.io/tas50) on keybase.
  • I have a public key ASCWk8cbCTHrI5_p2mVk0KFdYJfTsKiGenbB0KaIzZmv4Ao

To claim this, I am signing this object:

Fine Grained Product Channels
---
RFC: unassigned
Title: Fine Grained Product Channels
Author:
Tim Smith <tsmith@chef.io>
Status: Draft
Type: Informational
recipe:
apt_preference 'libmysqlclient16' do
action :remove
end
chef run:
[2017-08-10T23:43:37+00:00] WARN: No config file found or specified on command line, using command line options.