Skip to content

Instantly share code, notes, and snippets.

View mgreau's full-sized avatar

Maxime Gréau mgreau

View GitHub Profile
@inadarei
inadarei / minikube-sierra.md
Last active October 20, 2020 01:57
Minikube Setup: Docker for Mac / Sierra

Prerequisite: latest Docker for Mac on MacOS Sierra

$ brew update
$ brew install --HEAD xhyve
$ brew install docker-machine-driver-xhyve
$ sudo chown root:wheel $(brew --prefix)/opt/docker-machine-driver-xhyve/bin/docker-machine-driver-xhyve
$ sudo chmod u+s $(brew --prefix)/opt/docker-machine-driver-xhyve/bin/docker-machine-driver-xhyve

$ curl -Lo minikube https://storage.googleapis.com/minikube/releases/v0.18.0/minikube-darwin-amd64 && chmod +x minikube && sudo mv minikube /usr/local/bin/
@paliwodar
paliwodar / ExampleSpec.groovy
Last active May 24, 2018 10:58
A simple implementation of retry mechanism in Groovy
class SpecFile extends Specification {
def "Order delivery example test case"() {
given:
def product = createProduct()
expect:
retry { user pay product } waiting 500 upTo 3000 until {
it?.responseData?.status == "success"
}
@BretFisher
BretFisher / docker-for-mac.md
Last active May 7, 2024 08:34
Getting a Shell in the Docker Desktop Mac VM

2021 Update: Easiest option is Justin's repo and image

Just run this from your Mac terminal and it'll drop you in a container with full permissions on the Docker VM. This also works for Docker for Windows for getting in Moby Linux VM (doesn't work for Windows Containers).

docker run -it --rm --privileged --pid=host justincormack/nsenter1

more info: https://github.com/justincormack/nsenter1


@kevin-smets
kevin-smets / 1_kubernetes_on_macOS.md
Last active May 5, 2024 10:12
Local Kubernetes setup on macOS with minikube on VirtualBox and local Docker registry

Requirements

Minikube requires that VT-x/AMD-v virtualization is enabled in BIOS. To check that this is enabled on OSX / macOS run:

sysctl -a | grep machdep.cpu.features | grep VMX

If there's output, you're good!

Prerequisites

Role: Junior Developer Advocate

Employer: Exoscale

Location: Flexible; Berlin or Switzerland preferred

How to apply: Email your CV/resume and supporting information to mrevell@exoscale.ch

Summary:

new BaseJobBuilder(
name: "operations-jira-restart",
description: "Restarts dev jira. To be used when Jira is not responding",
emails: ["foo@example.com", "bar@example.com"]
).build(this).with {
scm {
git("https://[redacted]/SoftwareDevelopment/operations-jenkins-automation.git", "master")
}
steps {
shell("fab restart_jira")
@makolesnik
makolesnik / Selenide cheat sheet
Last active December 26, 2022 13:57
Selenide cheat sheet to create concise UI tests in Java. What is Selenide? Selenide is a wrapper for Selenium WebDriver. http://selenide.org/
=Navigating=
baseUrl = "http://site.com";
open("/login");
open("http://google.com");
switchTo().frame($("#myFrame").toWebElement());
=Alert=
switchTo().alert().accept();
@rochacbruno
rochacbruno / ACCESS_ELASTIC.md
Last active May 3, 2024 19:15
Docker-compose wait-to-start

When unsing docker compose you can have a problem with the order of dependent linked containers

The solution is to start a script which tries to access a service and waits until it gets ready before loading your program

@dalekurt
dalekurt / gist:7b44632d28b7b34afb55
Created May 20, 2015 21:27
Install Docker Machine with dependencies
#!/bin/bash
#
# A script for setting up a productive development environment with Docker
# on OS X. See https://github.com/brikis98/docker-osx-dev for more info.
set -e
# Environment variable file constants
readonly BASH_PROFILE="$HOME/.bash_profile"
readonly BASH_RC="$HOME/.bashrc"
@domenic
domenic / 0-github-actions.md
Last active April 8, 2024 23:35
Auto-deploying built products to gh-pages with Travis

Auto-deploying built products to gh-pages with GitHub Actions

This is a set up for projects which want to check in only their source files, but have their gh-pages branch automatically updated with some compiled output every time they push.

A file below this one contains the steps for doing this with Travis CI. However, these days I recommend GitHub Actions, for the following reasons:

  • It is much easier and requires less steps, because you are already authenticated with GitHub, so you don't need to share secret keys across services like you do when coordinate Travis CI and GitHub.
  • It is free, with no quotas.
  • Anecdotally, builds are much faster with GitHub Actions than with Travis CI, especially in terms of time spent waiting for a builder.