Skip to content

Instantly share code, notes, and snippets.

Avatar

Damien Duportal dduportal

View GitHub Profile
View gist:dd89581f2110391929d4d157e8dbf6a0
<p>
Execute <a href="https://www.updatecli.io/updatecli" target="_blank">updatecli</a> on the repository.
<p>
The following arguments are available for this function:
<ul>
<li>String action: (Optional - Default: "diff") Updatecli action (e.g. subcommand) to execute.</li>
<li>String config: (Optional - Default: "./updatecli/updatecli.d") path to the file or directory with the updatecli configuration (flag "--config").</li>
<li>String values: (Optional - Default: "./updatecli/values.yaml") path to the file with the updatecli values (flag "--values").</li>
View update-plugins.sh
#!/bin/bash
# This script updates all the installed plugins of a Jenkins docker container,
# restart the instance and outputs the resulting list of updated plugins (aka. "plugins.txt")
#
set -eu -o pipefail
JENKINS_URL=https://"${JENKINS_HOST}"
JENKINS_TEST_CREDZ="admin:${ADMIN_TOKEN}"
JENKINS_CONTAINER_NAME="${PROJECT_ID:-default}_jenkins_1"
View .env
# No double quotes around the rule!
SERVICES_JENKINS_DIR=./
TRAEFIK_ROUTER_RULE_FOR_JENKINS=Host(`localhost`) || Host(`127.0.0.1`) || Host(`172.17.0.1`)
EXTERNAL_HTTP_PORT=80
EXTERNAL_HTTPS_PORT=443
EXTERNAL_JNLP_PORT=50000
JENKINS_MAX_MEMORY=4096M
JENKINS_MAX_CPUS=1.8
JENKINS_INTERNAL_HTTP_PORT=8080
JENKINS_INTERNAL_JNLP_PORT=50000
View Makefile
BATS_HELPERS_DIR ?= $(CURDIR)/helpers
export BATS_HELPERS_DIR
BATS_BIN ?= $(CURDIR)/bats/bin/bats
tests:
$(BATS_BIN) $(CURDIR)/example.bats
View multipass-cloudinit-docker.yml
#cloud-config
package_update: true
manage-resolv-conf: true
resolv_conf:
nameservers:
- '9.9.9.9'
packages:
View traefik-le-and-redire-docker-compose.yml
version: '3'
services:
reverse-proxy:
image: traefik:v2.0
command:
- --providers.docker
- --entryPoints.web.address=:80
- --entryPoints.websecure.address=:443
- --api.dashboard=true
View README.md
View docker-whoami.yml
version: '3'
services:
webapp:
image: containous/whoami
# Move this directive under the "deploy:" if you are deploying to swarm instead of standalone Docker Engine
labels:
# Traefik v1
- "traefik.frontend.rule=Host:whoami.localhost"
# Traefik v2
View main.tf
provider "aws" {
region = "eu-west-2"
version = "~> 2.0"
}
variable "base_domain" {
type = "string"
description = "Base domain used for this experimentation"
default = "damienduportal.org"
}
View docker-compose.yml
version: '3.7'
services:
reverse-proxy:
image: traefik:${TRAEFIK_LATEST_STABLE}
command:
- "--docker"
- "--api"
ports:
- "80:80"