This file contains hidden or 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
| --- | |
| - hosts: localhost | |
| gather_facts: no | |
| # # darwin | |
| # vars: | |
| # ansible_python_interpreter: /usr/local/bin/python | |
| tasks: | |
| - block: | |
| - apt: |
This file contains hidden or 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
| DOMAIN=e-xample.com | |
| PROXY_TO=127.0.0.1:8427 | |
| cat << EOF > nginx.yml | |
| --- | |
| - hosts: ${DOMAIN} | |
| vars: | |
| upstreams: |
This file contains hidden or 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
| cat << EOF > config | |
| DRIVE1 /dev/nvme0n1 | |
| DRIVE2 /dev/nvme1n1 | |
| SWRAID 1 | |
| SWRAIDLEVEL 0 | |
| BOOTLOADER grub | |
| HOSTNAME $(hostname) |
This file contains hidden or 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 -xe | |
| cat << EOF > runner-values.yaml | |
| --- | |
| concurrent: 4 | |
| checkInterval: 3 | |
| rbac: | |
| create: true | |
| clusterWideAccess: false | |
| runners: |
This file contains hidden or 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 -xe | |
| cat << EOF > /etc/systemd/system/log-dns-query.service | |
| [Unit] | |
| Description=dns | |
| [Service] | |
| ExecStart=/bin/sh -c "script -q -c \"tcpdump -l port 53 2>/dev/null | grep --line-buffered ' A? ' | cut -d' ' -f8\" | tee -a /var/log/dns.log" | |
| [Install] |
This file contains hidden or 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 -xe | |
| [ -f /usr/local/bin/gitlab-runner ] || curl -L --output /usr/local/bin/gitlab-runner https://gitlab-runner-downloads.s3.amazonaws.com/latest/binaries/gitlab-runner-linux-amd64 | |
| chmod +x /usr/local/bin/gitlab-runner | |
| gitlab-runner register -n \ | |
| --url https://gitlab.com \ | |
| --registration-token qwerty \ | |
| --executor docker \ | |
| --description "dind runner" \ |
This file contains hidden or 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
| apiVersion: v1 | |
| kind: PersistentVolume | |
| metadata: | |
| name: pv-gitlab-managed-apps-prometheus-server | |
| spec: | |
| accessModes: | |
| - ReadWriteOnce | |
| capacity: | |
| storage: 10Gi | |
| claimRef: |
This file contains hidden or 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 -xe | |
| # Disk wipe | |
| sgdisk --zap-all ${DEV:-/dev/sda} | |
| # Disk partitioning | |
| sgdisk -og ${DEV:-/dev/sda} | |
| sgdisk -n 1:2048:+128M -t 1:fd00 ${DEV:-/dev/sda} | |
| sgdisk -n 128:-3M:0 -t 128:ef02 ${DEV:-/dev/sda} |
This file contains hidden or 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 -xe | |
| [ -b ${DISK_1:-/dev/sda} ] || exit 1 | |
| [ -b ${DISK_2:-/dev/sdb} ] || exit 1 | |
| mdadm --stop --scan | |
| sgdisk -og ${DISK_1:-/dev/sda} | |
| sgdisk -n 1:2048:+${SIZE_ROOTFS:-128M} -t 1:fd00 ${DISK_1:-/dev/sda} | |
| sgdisk -n 128:-3M:0 -t 128:ef02 ${DISK_1:-/dev/sda} |
This file contains hidden or 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 | |
| mkdir hello_app | |
| cd hello_app | |
| echo '#!/usr/bin/env ruby' > hello.rb | |
| echo 'puts "hello world"' >> hello.rb | |
| ruby hello.rb | |
| mkdir -p hello-1.0.0-linux-x86/lib/app |