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 | |
#Vault password is 1 | |
echo "Converting vault to yaml format:" | |
ansible-vault decrypt --output - vault | python ./convert_vault.py > new-vault.yml | |
echo "Decrypting a variable from the converted vault" | |
ansible localhost -i localhost, -e @new-vault.yml -m debug -a 'var=secret' --ask-vault-pas |
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
job "selenium-hub" { | |
region = "global" | |
datacenters = ["dc1"] | |
type = "service" | |
priority = 50 | |
update { | |
stagger = "10s" | |
max_parallel = 1 | |
} |
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
## 1. If file does not exist create file and encrypt password. | |
## 2. Else Read decrypted password and print on screen. | |
## 3. Additionally set password to clipboard. | |
$PASSFILE = "$HOME\pass.txt" | |
If (!(Test-Path $PASSFILE)) { | |
$sstring = Read-Host "Enter a password for user account: " -AsSecureString | |
$secure = $sstring | ConvertFrom-SecureString | |
$secure | Out-File $PASSFILE | |
} Else { |
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
openapi: 3.0.3 | |
info: | |
title: '' | |
version: 0.0.0 | |
paths: | |
/api/animals/: | |
get: | |
operationId: api_animals_list | |
description: '' | |
tags: |
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 | |
import sys | |
import exifread | |
import time | |
from os import path, utime | |
k = 'EXIF DateTimeOriginal' | |
for fn in sys.argv[1:]: |
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
# credits @Marco Louro (https://lincolnloop.com/blog/installing-nodejs-and-npm-python-virtualenv/) | |
$ workon myvirtualenv | |
$ curl http://nodejs.org/dist/node-latest.tar.gz | tar xvz | |
$ cd node-v* | |
$ ./configure --prefix=$VIRTUAL_ENV | |
$ make install |
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
# since 2.x use inventory | |
cat > ~/.ansible.cfg << EOF | |
[defaults] | |
inventory = ~/.ansible/hosts | |
EOF | |
test -d ~/.ansible || mkdir ~/.ansible | |
# put your hosts here | |
cat > ~/.ansible/hosts << EOF | |
[vms] |
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
gcc | |
automake | |
python-devel | |
openssl-devel | |
glibc-devel | |
libffi-devel |