View portainer.sh
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
docker volume create portainer_data | |
docker run -d -p 8000:8000 -p 9443:9443 \ | |
--name portainer \ | |
--restart=always \ | |
-v /var/run/docker.sock:/var/run/docker.sock \ | |
-v portainer_data:/data \ | |
portainer/portainer-ce:latest |
View gist:d6ad6510b1b744cd93b160e8daaaaf7f
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: '3.3' | |
services: | |
db: | |
image: mysql:5.7 | |
volumes: | |
- db_data:/var/lib/mysql | |
restart: always | |
environment: |
View volume_provision.sh
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
glusterName=glusterfs-cluster | |
glusterEP=10.240.0.10 | |
glusterNode01Path=gluster01:/storage-pool | |
glusterNode02Path=gluster02:/storage-pool | |
while true; do | |
check=$(kubectl get pvc --all-namespaces --no-headers |grep Pending | head -1) |
View http-tls.go
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// main.go | |
package main | |
import ( | |
"crypto/tls" | |
"log" | |
"net/http" | |
) |
View ferm-docker.conf
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- shell-script -*- | |
# | |
# Configuration file for ferm(1). | |
# | |
# Chain policies | |
# We define our Docker IPv4 ranges | |
@def $DOCKER_RANGE = (172.16.0.0/12); | |
# We drop INPUT/FORWARD by default and ACCEPT output |
View letsencrypt-auto
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# | |
# Download and run the latest release version of the Certbot client. | |
# | |
# NOTE: THIS SCRIPT IS AUTO-GENERATED AND SELF-UPDATING | |
# | |
# IF YOU WANT TO EDIT IT LOCALLY, *ALWAYS* RUN YOUR COPY WITH THE | |
# "--no-self-upgrade" FLAG | |
# | |
# IF YOU WANT TO SEND PULL REQUESTS, THE REAL SOURCE FOR THIS FILE IS |
View ha-wordpress.service
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /bin/bash | |
wordpressPath=/srv/wp01 | |
wordpressName=wordpress01 | |
wordpressPwd=pAssw0rd | |
wordpressUrl=wordpress01.example.com | |
################################## | |
mkdir -p "$wordpressPath"/db |
View wordpress-docker.service
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
docker service create --name wordpress-db01 \ | |
--replicas 1 \ | |
-p 3001:3306/tcp \ | |
-e MYSQL_ROOT_PASSWORD=pAssw0rd \ | |
-e MYSQL_DATABASE=wordpress \ | |
--mount type=bind,src=/srv/swarm/wordpress01/db,dst=/var/lib/mysql \ | |
mysql:latest | |
docker service create --name wordpress01 \ | |
--replicas 1 \ |
View nginx.conf
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# to generate your dhparam.pem file, run in the terminal | |
openssl dhparam -out /etc/nginx/ssl/dhparam.pem 2048 |
NewerOlder