#filler
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
| The go playground is a great place to try out go in a browser | |
| https://play.golang.org/ | |
| Golang dot org contains documentation for the standard library | |
| https://golang.org/ | |
| Godoc.org contains documentation for the standard library and a bunch of other packages. | |
| https://godoc.org |
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
| 60 wget https://dl-ssl.google.com/dl/linux/direct/mod-pagespeed-beta_current_amd64.deb | |
| 61 sudo dpkg -i mod-pagespeed-beta_current_amd64.deb | |
| 62 sudo apt-get -f install |
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
| Vagrant.configure("2") do |config| | |
| config.vm.define "web01" do |web01| | |
| config.vm.box = "ubuntu/trusty64" | |
| config.vm.hostname = "web01" | |
| config.vm.network :private_network, ip: "10.0.1.101" | |
| config.vm.provision "ansible" do |ansible| | |
| ansible.playbook = "web.yml" | |
| end | |
| end | |
| config.vm.define "web02" do |web02| |
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 re | |
| def regexTrim(theString): | |
| # Neat little trim function that uses expressions and replace/substring | |
| resultString = re.sub("^\s+", "", theString) # Trim Start | |
| resultString = re.sub("\s+$", "", resultString) # Trim End | |
| return resultString | |
| def trim(theString): |
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
| # This is the Original Code. | |
| # list(map(lambda x: chr(int(x***2)), [8.54, 10.5, 10.72, 10.6, 10.25, 10.68, 10.04, 10, 7.07, 6.93, 7, 7.35)) | |
| # Our first iteration was this: | |
| # list(map(lambda x: chr(int(x**2)), [8.54, 10.5, 10.72, 10.6, 10.25, 10.68, 10.04, 10, 7.07, 6.93, 7, 7.35])) | |
| # which produced -> ['H', 'n', 'r', 'p', 'i', 'r', 'd', 'd', '1', '0', '1', '6'] | |
| # It almost looks like it ends with '2016' so we try rounding before casting | |
| # Here's the last 4 items out of the x**2 part: |
##Javascript starter app
For me, this is the minimum amount of configuration required in order to write some javascript code.
- Make the root application directory
- Make subfolders, one for the app and one for tests.
mkdir _app
mkdir _tests
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
| <# | |
| .SYNOPSIS | |
| Get's a full list of users that are currently logged | |
| into a system. | |
| .DESCRIPTION | |
| Leverages WMI calls to extract user and session details | |
| .PARAMETER UserName |
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 AWSPowershell | |
| $access = "AAAAAAAAABBBBBBCCCCCCCCC" | |
| $private = "NNNNNNNNN+OOOOOOOOPPPPPPPPP" | |
| $bucketName = "mybucket.org" | |
| Set-AWSCredentials -AccessKey $access -SecretKey $private | |
| # It is imperative that the path end in a backslash |
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
| FROM ubuntu:trusty | |
| MAINTAINER Luke Muccillo version: 0.1 | |
| ENV APACHE_RUN_USER www-data | |
| ENV APACHE_RUN_GROUP www-data | |
| ENV APACHE_LOG_DIR /var/log/apache2 | |
| ENV APACHE_LOCK_DIR /var/lock/apache2 | |
| RUN DEBIAN_FRONTEND=noninteractive apt-get update |
NewerOlder