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
{ | |
// Define o tema do VSCode | |
"workbench.colorTheme": "Shades of Purple", | |
// Configura tamanho e família da fonte | |
"editor.fontSize": 18, | |
"editor.lineHeight": 24, | |
"editor.fontFamily": "Fira Code", | |
"editor.fontLigatures": true, | |
"explorer.compactFolders": false, |
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
const { exec } = require('child_process') | |
/** | |
* It delegates to the operating system the execution of the instruction passed as a parameter | |
* @param {string} command Instruction to be executed on the operating system | |
* @returns {Promise} Resolves to an object: {success: [boolean], content: [string]} | |
*/ | |
const newProcess = command => { | |
return new Promise((resolve, reject) => { | |
exec(command, (_, stdout, stderr) => { |
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 | |
SERVERS=(host01 host02 host03); | |
echo "##################"; | |
echo "# Header Example #"; | |
echo -e "##################\n"; | |
echo -e "Run on: $(date '+%F - %T')\n" | |
for i in "${!SERVERS[@]}" |
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 | |
FILESYSTEM="/storage" | |
SERVERS=(host01 host02 host03) | |
for i in "${!SERVERS[@]}" | |
do | |
STATUS=$(ssh -q -oStrictHostKeyChecking=no ${SERVERS[i]} "if mountpoint -q ${FILESYSTEM}; then echo "OK"; else echo "NOK"; fi") | |
if [[ $? != 0 ]]; |
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
############### | |
### PHP 7.1 ### | |
############### | |
sudo apt-get update | |
sudo apt-get upgrade -y | |
# Sempre que questionado, responda "Y" | |
sudo apt-get install software-properties-common python3-software-properties -y |
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
language: php | |
env: | |
global: | |
- setup=stable | |
matrix: | |
fast_finish: true | |
include: | |
- php: 7.1 |