Jon Warbrick, July 2014, V3.2 (for Ansible 1.7)
First one found from of
| #!/bin/bash | |
| CLOUDFRONT_DISTRIBUTION_ID=E2C3RNL2F4MRMQ | |
| NEW_ORIGIN="origin2-zaid.s3.us-west-2.amazonaws.com" | |
| ETAG=`aws cloudfront get-distribution --id $CLOUDFRONT_DISTRIBUTION_ID | jq -r .ETag` | |
| aws cloudfront get-distribution --id $CLOUDFRONT_DISTRIBUTION_ID | \ | |
| jq --arg NEW_ORIGIN "$NEW_ORIGIN" '.Distribution.DistributionConfig.Origins.Items[0].Id=$NEW_ORIGIN' | \ | |
| jq --arg NEW_ORIGIN "$NEW_ORIGIN" '.Distribution.DistributionConfig.Origins.Items[0].DomainName=$NEW_ORIGIN' | \ | |
| jq --arg NEW_ORIGIN "$NEW_ORIGIN" '.Distribution.DistributionConfig.DefaultCacheBehavior.TargetOriginId=$NEW_ORIGIN' | \ | |
| jq .Distribution.DistributionConfig > config.json | |
| aws cloudfront update-distribution --id $CLOUDFRONT_DISTRIBUTION_ID --distribution-config "file://config.json" --if-match $ETAG > /dev/null |
Jon Warbrick, July 2014, V3.2 (for Ansible 1.7)
First one found from of
| version: '3' | |
| services: | |
| mongo1: | |
| hostname: mongo1 | |
| container_name: localmongo1 | |
| image: mongo | |
| restart: always | |
| expose: | |
| - 27017 | |
| ports: |
| #!/bin/bash | |
| # | |
| # βββ βββ βββββ βββ ββ βββ βββ βββ ββ β βββ ββββ | |
| # βββ βββ βββββ βββ ββ βββ βββ βββ ββ β βββ ββββ | |
| # | |
| # Description: | |
| # - This script automates bumping the git software project's version using automation. | |
| # - It does several things that are typically required for releasing a Git repository, like git tagging, | |
| # automatic updating of CHANGELOG.md, and incrementing the version number in various JSON files. |
| terragrunt: | |
| plan: | |
| steps: | |
| - env: | |
| name: TERRAGRUNT_TFPATH | |
| command: 'echo "terraform${ATLANTIS_TERRAFORM_VERSION}"' | |
| - run: node ~/terragrunt_light.js plan $PLANFILE | |
| apply: | |
| steps: | |
| - env: |
| /** | |
| * Wrapper around terragrunt to display output succinctly on Atlantis. | |
| * | |
| * Terragrunt is notoriously verbose, which can cause Atlantis to output | |
| * hundreds of comments on single PRs, which can be annoying. | |
| * | |
| * This script will output just the final plan for resources to update on | |
| * successful terragrunt runs, but will output all terragrunt output on | |
| * errors. | |
| */ |
Note: currently only works on *nix systems (until a powershell script can be created)
With the technique below, you can run node, npm, npx, or yarn commands as if the programs were installed
natively on your system, and you won't even know the difference! This includes any ports that your app or dev process
will start up and use for development, as well as compatibility with persistent npm config --global cli usage.
See more in the Usage section below.
| // create a bookmark and use this code as the URL, you can now toggle the css on/off | |
| // thanks+credit: https://dev.to/gajus/my-favorite-css-hack-32g3 | |
| javascript: (function() { | |
| var domStyle = document.createElement("style"); | |
| domStyle.append( | |
| '* { color:#0f0!important;outline:solid #f00 1px!important; background-color: rgba(255,0,0,.2) !important; }\ | |
| * * { background-color: rgba(0,255,0,.2) !important; }\ | |
| * * * { background-color: rgba(0,0,255,.2) !important; }\ | |
| * * * * { background-color: rgba(255,0,255,.2) !important; }\ | |
| * * * * * { background-color: rgba(0,255,255,.2) !important; }\ |
| # Hello, and welcome to makefile basics. | |
| # | |
| # You will learn why `make` is so great, and why, despite its "weird" syntax, | |
| # it is actually a highly expressive, efficient, and powerful way to build | |
| # programs. | |
| # | |
| # Once you're done here, go to | |
| # http://www.gnu.org/software/make/manual/make.html | |
| # to learn SOOOO much more. |