This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Allan | |
def initialize(app, env) | |
@app = app | |
@machine = env[:machine] | |
end | |
def call(env) | |
@app.call env | |
setup_debian_apt if @machine.box.name =~ /bento\/debian/ | |
setup_centos_yum if @machine.box.name =~ /centos\/7/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Allan | |
def initialize(app, env) | |
@app = app | |
@machine = env[:machine] | |
end | |
def call(env) | |
@app.call env | |
setup_debian_apt if @machine.box.name =~ /bento\/debian/ | |
setup_centos_yum if @machine.box.name =~ /centos\/7/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /nix/store/jxs0zbsbvajw2kbf6j1pqvpsf3cijqbm-perl-5.24.1/bin/perl -w -I/nix/store/0m3cha88h649i7zf3q7qm2ky87y10wkw-nix-1.11.13/lib/perl5/site_perl/5.24.1/darwin-2level -I/nix/store/yj53jd5kl0ipq3ba3kj2m8spl0d7wl7w-perl-DBI-1.636/lib/perl5/site_perl -I/nix/store/c09ysri8dvrckn8pzh11vhyv3ikyr3b9-perl-DBD-SQLite-1.50/lib/perl5/site_perl -I/nix/store/yikv6vgrfc9602wpgq19njk1dphrylil-perl-WWW-Curl-4.17/lib/perl5/site_perl | |
use utf8; | |
use strict; | |
use File::Basename; | |
use File::Path qw(mkpath); | |
use File::stat; | |
use File::Copy; | |
use MIME::Base64; | |
use Nix::Config; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
nix-store --realize /nix/store/fzp63riikr25vx2h367jwlri5ffaknhr-test-kitchen-1.16.0 --option extra-binary-caches http://proxy.dev:8081/repository/nixos-cache/ -vvvvv --option debug-subst 1 | |
starting substituter program ‘/nix/store/crqd5wmrqipl4n1fcm5kkc1zg4sj80js-nix-1.11.11/libexec/nix/substituters/download-using-manifests.pl’ | |
starting substituter program ‘/nix/store/crqd5wmrqipl4n1fcm5kkc1zg4sj80js-nix-1.11.11/libexec/nix/substituters/download-from-binary-cache.pl’ | |
download-from-binary-cache.pl: expired 0 negative entries | |
download-from-binary-cache.pl: checking binary caches for info on /nix/store/fzp63riikr25vx2h367jwlri5ffaknhr-test-kitchen-1.16.0 | |
don't know how to build these paths: | |
/nix/store/fzp63riikr25vx2h367jwlri5ffaknhr-test-kitchen-1.16.0 | |
building ‘/nix/store/fzp63riikr25vx2h367jwlri5ffaknhr-test-kitchen-1.16.0’ | |
| substitution of ‘/nix/store/fzp63riikr25vx2h367jwlri5ffaknhr-test-kitchen-1.16.0’: created | |
| substitution of ‘/nix/store/fzp63riikr25vx2h367jwlri5ffaknhr-test-kitchen-1.16.0’: woken |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
https://chefcommunity.slack.com/archives/C2VACTK2A/p1497900148839848 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'chef/resource' | |
require 'kramdown' | |
require 'minitest/autorun' | |
DOC = DATA.read | |
class SomeResource < Chef::Resource | |
property :base_properties | |
def self.use_version(version) | |
if version == '1.6.1' | |
load_kube_16 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
irb> require 'image_science' | |
/tmp/ccLnaq6a.o: In function `raise_error': | |
Inline_ImageScience_20a6c1167e26493622aab915959b49d1.c:(.text+0xd): undefined reference to `rb_thread_current' | |
Inline_ImageScience_20a6c1167e26493622aab915959b49d1.c:(.text+0x18): undefined reference to `rb_thread_local_aref' | |
Inline_ImageScience_20a6c1167e26493622aab915959b49d1.c:(.text+0x2f): undefined reference to `rb_thread_current' | |
Inline_ImageScience_20a6c1167e26493622aab915959b49d1.c:(.text+0x3f): undefined reference to `rb_thread_local_aset' | |
Inline_ImageScience_20a6c1167e26493622aab915959b49d1.c:(.text+0x49): undefined reference to `rb_string_value_cstr' | |
Inline_ImageScience_20a6c1167e26493622aab915959b49d1.c:(.text+0x53): undefined reference to `rb_eRuntimeError' | |
Inline_ImageScience_20a6c1167e26493622aab915959b49d1.c:(.text+0x64): undefined reference to `rb_raise' | |
Inline_ImageScience_20a6c1167e26493622aab915959b49d1.c:(.text+0x6b): undefined reference to `rb_eRuntimeError' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# To build on macOS | |
# NIX_CURRENT_LOAD=`pwd` NIX_REMOTE_SYSTEMS=`pwd`/remotes.conf \ | |
# NIX_BUILD_HOOK=$HOME/.nix-profile/libexec/nix/build-remote.pl \ | |
# nix-build --argstr system x86_64-linux | |
# | |
# remotes.conf | |
# vagrant@<ip> x86_64-linux $HOME/.vagrant.sh/insecure_private_key 1 | |
{ system ? builtins.currentSystem }: | |
with import <nixpkgs> { | |
system = system; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
with import <nixpkgs> {}; | |
stdenv.mkDerivation { | |
name = "cpu-app"; | |
enableSharedExecutables = false; | |
buildInputs = [ | |
(haskellPackages.ghcWithPackages (p: [p.yesod ])) | |
]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
with import <nixpkgs> {}; | |
stdenv.mkDerivation { | |
name = "cpu-app"; | |
enableSharedExecutables = false; | |
buildInputs = [ | |
(haskellPackages.ghcWithPackages (p: [p.yesod ])) | |
]; | |
} |