Skip to content

Instantly share code, notes, and snippets.

View mhaligowski's full-sized avatar
🎯
Focusing

Mateusz Haligowski mhaligowski

🎯
Focusing
  • yahoo.com
  • Seattle, WA
  • 23:12 (UTC -07:00)
View GitHub Profile
@mhaligowski
mhaligowski / stdout
Created February 1, 2025 21:53
helm upgrade --install --namespace loki --create-namespace loki grafana/loki
Error: template: loki/templates/write/statefulset-write.yaml:50:28: executing "loki/templates/write/statefulset-write.yaml" at <include "loki.configMapOrSecretContentHash" (dict "ctx" . "name" "/config.yaml")>: error calling include: template: loki/templates/_helpers.tpl:1131:8: executing "loki.configMapOrSecretContentHash" at <include (print .ctx.Template.BasePath .name) .ctx>: error calling include: template: loki/templates/config.yaml:19:7: executing "loki/templates/config.yaml" at <include "loki.calculatedConfig" .>: error calling include: template: loki/templates/_helpers.tpl:507:24: executing "loki.calculatedConfig" at <tpl .Values.loki.config .>: error calling tpl: error during tpl function execution for "{{- if .Values.enterprise.enabled}}
{{- tpl .Values.enterprise.config . }}
{{- else }}
auth_enabled: {{ .Values.loki.auth_enabled }}
{{- end }}
{{- with .Values.loki.server }}
server:
{{- toYaml . | nindent 2}}
{{- end}}
@mhaligowski
mhaligowski / index.js
Created October 6, 2023 20:13
ESM example with @gradientai/nodejs-sdk
import ora from "ora";
import { Gradient } from "@gradientai/nodejs-sdk";
const spinner = ora("").start();
async function run() {
spinner.start("Creating a new Gradient client");
const gradient = new Gradient({});
spinner.stopAndPersist({
text: "Gradient client created successfully",
import java.util.Random;
import java.util.*;
public class InputRandomGame {
public static void main(String[] args) {
intro();
gameMechanic();
ask();
}
public static void ask() {
@mhaligowski
mhaligowski / README
Created May 30, 2021 20:24
This is what happens with help when using yargs with `commandDir`.
Example project
@mhaligowski
mhaligowski / packer.json
Created July 6, 2018 05:34
Prepare VirtualBox VM (+Vagrant) with WordPress preinstalled
{
"_comment": "Build with `packer build ubuntu.json`",
"builders": [
{
"boot_command": [
"{{ user `boot_command_prefix` }}",
"/install/vmlinuz noapic ",
"initrd=/install/initrd.gz ",
"file=/floppy/{{ user `preseed` }} ",
"debian-installer={{ user `locale` }} auto locale={{ user `locale` }} kbd-chooser/method=us ",
@mhaligowski
mhaligowski / Monster.java
Created June 2, 2017 04:43
AssertJ collections example
public class Monster {
private String id;
private String name;
public Monster(final String id, final String name) {
this.id = id;
this.name = name;
}
runtime: python27
api_version: 1
threadsafe: true
handlers:
- url: /.*
script: main.app
@mhaligowski
mhaligowski / function.js
Created May 16, 2017 04:23
Handling with both Google Cloud Functions and Express
exports.hello = require('./hello');
@mhaligowski
mhaligowski / ScopesModule.java
Created March 12, 2017 22:27
Super simple Scope in Guice
import com.google.inject.*;
import javax.inject.Inject;
import java.lang.annotation.Retention;
import static java.lang.annotation.RetentionPolicy.RUNTIME;
@ScopeAnnotation
@Retention(RUNTIME)
@interface NameScoped {
@mhaligowski
mhaligowski / Gemfile
Last active August 29, 2015 14:03
rakefile for asciidoctor
source 'https://rubygems.org'
gem 'asciidoctor'
gem 'tilt'
gem 'haml'
gem 'rake'