Skip to content

Instantly share code, notes, and snippets.

diff --git a/src/bosh-director/spec/spec_helper.rb b/src/bosh-director/spec/spec_helper.rb
index 1b6bc561b8..1e707cb0ed 100644
--- a/src/bosh-director/spec/spec_helper.rb
+++ b/src/bosh-director/spec/spec_helper.rb
@@ -228,11 +228,11 @@ RSpec.configure do |rspec|
allow(Bosh::Director::Config).to receive(:cloud).and_return(instance_double(Bosh::Clouds::ExternalCpi))
- threadpool = instance_double(Bosh::Director::ThreadPool)
- allow(Bosh::Director::ThreadPool).to receive(:new).and_return(threadpool)
@jrussett
jrussett / Full syntax of short bosh-dns names
Created January 16, 2018 21:58
Shows total order of the short version of bosh-dns names
q-a0m0n1s0.q-g0.tld
q-<AZ id> <instances row id / numerical uuid> <Network ID> <Healthiness> . q-<group id>.tld
@jrussett
jrussett / quick_reference.md
Last active February 16, 2024 21:47
Quick Reference

How to focus rake tests:

it 'does some sort of testing', :focus => true do

run_integration_specs(spec_path: 'spec/gocli/integration', tags: 'focus') or

rspec --tag focus spec/my_spec.rb

How to run bosh integration tests as a one-off in fly:

// +build windows
package main
import (
"fmt"
"unsafe"
"unicode/utf16"
"golang.org/x/sys/windows"
@jrussett
jrussett / hotswap_break_network_failures.md
Last active February 21, 2018 00:20
Hotswap failures

No longer cause issues after being run in CI

  • rspec ./spec/gocli/integration/calculated_vm_properties_spec.rb:91 # calculated vm properties when deploying with default CPI deploys vms with size calculated from vm block
  • rspec ./spec/gocli/integration/cli_deploy_uploading_spec.rb:25 # cli: deploy uploading with a remote release uploads the release from the remote url in the manifest
  • rspec ./spec/gocli/integration/cli_deploy_uploading_spec.rb:36 # cli: deploy uploading with a remote release does not upload the same release twice
  • rspec ./spec/gocli/integration/cli_deploy_uploading_spec.rb:52 # cli: deploy uploading with a remote release fails when the sha1 does not match
  • rspec ./spec/gocli/integration/cli_deploy_uploading_spec.rb:60 # cli: deploy uploading with a remote release allows multiple digests in the sha1 field
  • rspec ./spec/gocli/integration/cli_ignore_spec.rb:14 # ignore/unignore-instance changes the ignore value of vms correctly

Other issues + Notes:

@jrussett
jrussett / bosh-create-release.md
Created March 2, 2018 23:53
When making your own release

Do not forget this portion:

Record the binary name including version number, with a slash and the binary filename concatenated to it. It’s a good idea to cite the official URL in a comment, in the same line.

That is...

---
@jrussett
jrussett / gist:0fecb73a10232e0e5f4424157f56c539
Created June 8, 2018 00:26
task debug with mocked agent timeout to reproduce multiple compilation vm deletion
I, [2018-06-08T00:01:05.039642 #13] [0x2afc7de58c34] INFO -- TaskHelper: Director Version: 266.0.0
I, [2018-06-08T00:01:05.039699 #13] [0x2afc7de58c34] INFO -- TaskHelper: Enqueuing task: 89
I, [2018-06-08T00:01:05.200413 #29011] [] INFO -- DirectorJobRunner: Looking for task with task id 89
D, [2018-06-08T00:01:05.201579 #29011] [] DEBUG -- DirectorJobRunner: (0.000297s) (conn: 47018331589620) SELECT * FROM "tasks" WHERE "id" = 89
I, [2018-06-08T00:01:05.203007 #29011] [] INFO -- DirectorJobRunner: Found task #<Bosh::Director::Models::Task @values={:id=>89, :state=>"processing", :timestamp=>2018-06-08 00:01:05 UTC, :description=>"create deployment", :result=>nil, :output=>"/var/vcap/store/director/tasks/89", :checkpoint_time=>2018-06-08 00:01:05 UTC, :type=>"update_deployment", :username=>"admin", :deployment_name=>"zookeeper", :started_at=>nil, :event_output=>"", :result_output=>"", :context_id=>""}>
I, [2018-06-08T00:01:05.203086 #29011] [] INFO -- DirectorJobRunner: Running from worker 'worker_3' on
Things that probably need to be included in the terraform file:
google_compute_address
google_compute_target_pool
google_compute_forwarding_rule (x3?)
Then in the cloud config
vm_type
- name: concourse_core
@jrussett
jrussett / test-cred-alert-cli.sh
Last active October 30, 2018 20:26
Testing the pivotal cred-alert-cli
#! /bin/bash
set -eux
tmpdir=$(mktemp -d)
pushd "$tmpdir" || return
git init
@jrussett
jrussett / ubuntu_pkglist
Last active December 13, 2018 22:55
Packages that need extra setup
# install cmd
xargs -a packages.txt sudo apt-get install
# Packages that need extra/non-package manager setup
adobe-source-code-pro-fonts
[ -d /usr/share/fonts/opentype ] || sudo mkdir /usr/share/fonts/opentype
sudo git clone https://github.com/adobe-fonts/source-code-pro.git /usr/share/fonts/opentype/scp
sudo fc-cache -f -v
chruby && ruby-install