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 | |
hosts=( "host3" "host4" ) | |
for i in "${hosts[@]}" | |
do | |
echo "----------" | |
echo "- Host: $i" | |
ssh -q "$i" << SSH_COMMANDS | |
sudo apt-get upgrade -y |
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 | |
hosts=( "host1" "host2" ) | |
for i in "${hosts[@]}" | |
do | |
echo "----------" | |
echo "- Host: $i" | |
ssh -q "$i" << SSH_COMMANDS | |
sudo yum update -y |
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
<?php | |
/** | |
* @param string $charset the entire set of characters to permute | |
* @param array|int[] $ring an array of counters representing the character pointed to by each element of the cipher ring | |
* @return Generator | |
*/ | |
function permute($charset, array $ring = [0]) | |
{ | |
while (count($ring) <= strlen($charset)) { |