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 | |
mv /root/logs.txt /root/logs_`date +%s`.txt 2>/dev/null || true | |
exec &> >(tee -a "/root/logs.txt") | |
systemctl restart systemd-timesyncd | |
start_time=`date +%s` | |
export DEBIAN_FRONTEND=noninteractive | |
echo "===========================================" | |
echo " UPDATE SYSTEM" | |
echo "===========================================" | |
start_time_update=`date +%s` |
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
provider "libvirt" { | |
uri = "test:///default" | |
} | |
resource "libvirt_domain" "terraform_test" { | |
name = "terraform_test" | |
} |
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 | |
# install: | |
# NETBOX_FQDN=netbox.example.com bash -c "$(curl -Lso- https://git.io/fhp1D)" | |
export DEBIAN_FRONTEND=noninteractive | |
systemctl restart systemd-timesyncd | |
ipv6="${ipv6:-$( wget -qO- -t1 -T2 ipv6.icanhazip.com)}" | |
ipv4="${ipv4:-$( wget -qO- -t1 -T2 ipv4.icanhazip.com)}" | |
ipv4_slug="$(echo $ipv4 | sed 's/\./-/g').nip.io" | |
random_dbpass=`date +%s | sha256sum | base64 | head -c 32` | |
random_nbpass=`date +%s | sha256sum | base64 | head -c 32` |
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 | |
DEBIAN_FRONTEND=noninteractive apt-get update | |
DEBIAN_FRONTEND=noninteractive apt-get install -y curl openssh-server ca-certificates | |
DEBIAN_FRONTEND=noninteractive apt-get install -y postfix unattended-upgrades | |
# on centos use yum-cron instead of unattended-upgrades | |
cat <<'EOF' > /etc/apt/apt.conf.d/50unattended-upgrades | |
Unattended-Upgrade::Allowed-Origins { | |
"${distro_id}:${distro_codename}"; | |
"${distro_id}:${distro_codename}-security"; |
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
Alpha-file | |
{% for student in students %} | |
{{ lookup('template','beta.j2') }} | |
{%endfor%} |
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
#!/usr/bin/env python | |
# Adapted from Mark Mandel's implementation | |
# https://github.com/ansible/ansible/blob/devel/plugins/inventory/vagrant.py | |
import argparse | |
import json | |
import paramiko | |
import subprocess | |
import sys | |
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
{ | |
"$schema": "https://schema.management.azure.com/schemas/2015-01-01/deploymentTemplate.json#", | |
"contentVersion": "1.0.0.0", | |
"parameters": { | |
"dnsLabelPrefix": { | |
"type": "string", | |
"metadata": { | |
"description": "Unique DNS Name for the Storage Account where the Virtual Machine's disks will be placed." | |
} | |
}, |
This file has been truncated, but you can view the full file.
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
'.source.ansible': | |
'a10_server': | |
'prefix': "a10_server_snippet" | |
'description': "Manage A10 Networks AX/SoftAX/Thunder/vThunder devices' server object." | |
'body': """ | |
a10_server: | |
username: ${1:null} # required. An account with administrator privileges. | |
host: ${2:null} # required. Hostname or IP of the A10 Networks device. | |
password: ${3:null} # required. Password for the C(username) account. | |
server_name: ${4:undefined} # required. The SLB (Server Load Balancer) server name. |
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
#!/usr/bin/env python | |
# Adapted from Mark Mandel's implementation | |
# https://github.com/ansible/ansible/blob/devel/plugins/inventory/vagrant.py | |
import argparse | |
import json | |
import paramiko | |
import subprocess | |
import sys | |
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
FILES=*.rst | |
for f in $FILES | |
do | |
filename="${f%.*}" | |
echo "Converting $f to $filename.md" | |
`pandoc $f -f rst -t markdown -o $filename.md` | |
done |