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
# Metadata listing mode | |
kcat -L \ | |
-b $KAFKA_BROKER:9096 \ | |
-X security.protocol=SASL_SSL \ | |
-X sasl.mechanisms=SCRAM-SHA-512 \ | |
-X sasl.username=$USERNAME \ | |
-X sasl.password=$PASSWORD | |
# Producer mode | |
kcat -t $KAFKA_TOPIC -P \ |
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
#! /usr/bin/env bash | |
pulumi new https://github.com/peterkowalski/pulumi-template-aws-python.git --generate-only |
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
ldapsearch -D "uid=USER_UID,ou=USER_OU1,ou=USER_OU2,o=USER_O" -x -b "o=SEARCH_O" -H ldaps://myldap.example.com -z 5 -l 1 -W |
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
# 1. Install | |
docker volume create gitlab-runner-config | |
docker run -d --name gitlab-runner --restart always \ | |
-v /var/run/docker.sock:/var/run/docker.sock \ | |
-v gitlab-runner-config:/etc/gitlab-runner \ | |
gitlab/gitlab-runner:latest | |
# 2. Register | |
docker run --rm -it -v gitlab-runner-config:/etc/gitlab-runner gitlab/gitlab-runner:latest register |
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
ansible localhost -m debug -a var="passwordVariable" -e "@encrypted-file.yml" --vault-password-file ~/password |
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
# Required by sshpass | |
export ANSIBLE_HOST_KEY_CHECKING=False | |
ansible all -i "192.168.1.1," -m authorized_key -a "user=other-user state=present key=\"{{ lookup('file', 'other-public-key.pub') }}\"" -u root -k #-CD (check and show diff) |
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
--- | |
# three node (two workers) cluster config | |
kind: Cluster | |
apiVersion: kind.x-k8s.io/v1alpha4 | |
nodes: | |
- role: control-plane | |
- role: worker | |
- role: worker |
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
pip freeze > req.txt | |
pip install -r req.txt --upgrade |
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
molecule init role -r geerlingguy.example -d docker | |
molecule converge | |
<do some work on the role> | |
molecule converge | |
<see that some changes didn't work> | |
molecule converge | |
<see everything working well, commit my changes> | |
molecule converge | |
<idempotence check - make sure Ansible doesn't report any changes on a second run> | |
molecule destroy |
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
ssh [email protected] 'bash -s' < local_script.sh |
NewerOlder