Skip to content

Instantly share code, notes, and snippets.

View astral303's full-sized avatar

Oleg Rekutin astral303

  • Evergage
  • Somerville, MA
View GitHub Profile
* aws_ebs_volume[ebs0] action create[2017-06-28T00:29:34+00:00] INFO: Processing aws_ebs_volume[ebs0] action create (xyz::_xyz line 10)
================================================================================
Error executing action `create` on resource 'aws_ebs_volume[ebs0]'
================================================================================
Aws::EC2::Errors::InvalidVolumeNotFound
---------------------------------------
The volume 'vol-1118028b1c1a11ff1' does not exist.
===== ERROR (Brikit 2017-03-22 15:36:00) Unable to read theme properties for null
=====
===== ERROR (Brikit 2017-03-22 15:36:00) Caused by:
java.lang.NullPointerException
at com.google.common.base.Preconditions.checkNotNull(Preconditions.java:187)
at com.google.common.cache.LocalCache.get(LocalCache.java:3969)
at com.google.common.cache.LocalCache.getOrLoad(LocalCache.java:3974)
at com.google.common.cache.LocalCache$LocalManualCache.get(LocalCache.java:4834)
at com.brikit.themepress.settings.ThemePropertiesCache.getThemeProperties(ThemePropertiesCache.java:48)
at com.brikit.themepress.settings.ThemeProperties.getThemeProperties(ThemeProperties.java:92)
@astral303
astral303 / gist:ba4595210c9645e493dc
Created April 10, 2015 16:30
Running shell commands in Jenkins with sudo
// Use unbuffer to avoid sudo complaining about no tty requirement
def cmd = ["/bin/bash", "-c", "unbuffer sudo service sshd status"]
def proc = cmd.execute()
def outputStream = new StringBuffer()
def errStream = new StringBuffer()
proc.waitForProcessOutput(outputStream, errStream)
println(outputStream.toString())
println(errStream.toString())
@astral303
astral303 / gist:8007019
Created December 17, 2013 15:47
coerce null to undefined to work around angular.js #5442
'use strict';
angular.module('app')
.directive('coerceNullToUndefined', function () {
return {
restrict: 'A',
require: 'ngModel',
link: function (scope, element, attrs, ngModel) {
ngModel.$formatters.push(function (value) {
if (value === null) {