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
--- | |
- block: | |
- name: Raw Python 2 | Bootstrap | Try to gather facts | |
setup: | |
rescue: | |
- name: Raw Python 2 | Bootstrap | Install 'python-minimal' | |
raw: "test -e /usr/bin/python || (apt -y update && apt install -y python-minimal)" | |
- name: Raw Python 2 | Bootstrap | Gather facts |
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
for f in /path/to/your/files*; do | |
## Check if the glob gets expanded to existing files. | |
## If not, f here will be exactly the pattern above | |
## and the exists test will evaluate to false. | |
if [ -e "$f" ] then | |
echo "Mask exists" | |
fi | |
## This is all we needed to know, so we can break after the first iteration | |
break |
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
# netsh advfirewall firewall add rule name="Open Port 80" dir=in action=allow protocol=TCP localport=80 | |
# netsh advfirewall firewall add rule name="Open Port 443" dir=in action=allow protocol=TCP localport=443 | |
New-NetFirewallRule -DisplayName 'HTTP(S) Inbound' -Profile @('Domain', 'Private') -Direction Inbound -Action Allow -Protocol TCP -LocalPort @('80', '443') | |
Get-NetFirewallRule | Where { $_.Enabled –eq ‘True’ –and $_.Direction –eq ‘Inbound’ } |
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
Import-Module WebAdministration | |
Set-WebConfiguration ` | |
-Filter "/System.webServer/modules" ` | |
-Metadata overrideMode ` | |
-Value Allow ` | |
-PSPath "IIS:\" |
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
mkvirtualenv --python=/usr/bin/python3 | |
# ... | |
workon ML | |
pip install numpy | |
pip install scipy | |
pip install matplotlib | |
pip install pandas | |
pip install scikit-learn |
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
https://groups.google.com/forum/#!aboutgroup/ansible-project |
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
# delete local tag '12345' | |
git tag -d 12345 | |
# delete remote tag '12345' (eg, GitHub version too) | |
git push origin :refs/tags/12345 | |
# alternative approach | |
git push --delete origin tagName | |
git tag -d tagName |
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/sh | |
sudo yum install -y yum-utils | |
sudo yum-config-manager --add-repo https://download.docker.com/linux/centos/docker-ce.repo | |
sudo yum makecache fast | |
sudo yum install -y http://mirror.centos.org/centos/7/extras/x86_64/Packages/container-selinux-2.33-1.git86f33cd.el7.noarch.rpm | |
sudo yum install -y docker-ce |
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/sh | |
snap install kubectl --classic | |
snap install vscode | |
snap install atom | |
snap install skype | |
snap install vlc | |
snap install slack | |
snap install telegram-desktop | |
snap install phpstorm | |
snap install pycharm-community |
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
Press Alt+F2 to switch to a new console | |
sudo apt-get purge xserver-xorg-video-intel then reboot | |
sudo apt-get install xserver-xorg-video-intel | |
nano /etc/X11/xorg.conf, remove any present code (if applicable) and enter the following: | |
Section "Device" | |
Identifier "Card0" | |
Driver "intel" | |
Option "AccelMethod" "sna" | |
EndSection | |
Save the file and reboot |