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
| #!/usr/bin/env bash | |
| : ' | |
| Script file to upload AWS step functions state machine. | |
| Ensure AWS is installed and configured, | |
| define script variables, then execute script. | |
| Accepts -v (verbose output) and -q (quiet output) arguments. |
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
| #!/usr/bin/env bash | |
| : ' | |
| Script file to build and publish AWS EC2 instance start-up package. | |
| Ensure AWS is installed and configured, | |
| define script variables, then execute script. | |
| Accepts -v (verbose output) and -q (quiet output) arguments. | |
| Prerequisites: |
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
| #!/usr/bin/env bash | |
| : ' | |
| Script file to prepare and deploy AWS ElasticBeanstalk applications. | |
| Ensure AWS EB CLI is installed and configured, | |
| define script variables, then execute script. | |
| First argument must be ElasticBeanstalk environment name, | |
| secondly optional option -c <configuration>, and |
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
| #!/usr/bin/env bash | |
| : ' | |
| Script file to run prior to other script files for more unified and pretty shell scripts. | |
| Accepts -v (verbose output) and -q (quiet output) arguments. | |
| Features: | |
| - variable "QUIET_OUTPUT": set by -q option | |
| (e.g. % command &> $\{QUIET_OUTPUT}\) |
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
| #!/usr/bin/env bash | |
| : ' | |
| Script file to package and deploy AWS CloudFormation stacks. | |
| Ensure AWS CLI is installed and configured, ensure STOML is installed, | |
| define script variables and configuration file, then execute script. | |
| Accepts -v (verbose output) and -q (quiet output) arguments. |
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
| #!/usr/bin/env bash | |
| : ' | |
| Script file to build, package, and deploy AWS SAM applications. | |
| Ensure AWS CLI and SAM CLI are installed and configured, | |
| define script variables and configuration file, then execute script. | |
| Accepts -v (verbose output) and -q (quiet output) arguments. |
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
| #!/usr/bin/env bash | |
| : ' | |
| Script file to build and publish AWS lambda layer. | |
| Ensure AWS is installed and configured, docker engine is started, | |
| define script variables, then execute script. | |
| Accepts -v (verbose output) and -q (quiet output) arguments. |
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
| var shopifyUrl = `https://${env.shopifyShopUrl}/admin/api/${env.shopifyApiVersion}`; | |
| var shopifyCreds = btoa(`${env.shopifyApiKey}:${env.shopifyApiSecretKey}`); | |
| var shopifyHeaders = { | |
| "Content-Type" : "application/json", | |
| "Authorization" : `Basic ${shopifyCreds}` | |
| }; | |
| let shopifyResponse = await fetch(`${shopifyUrl}/orders/${orderId}.json`, {headers: shopifyHeaders}); | |
| // let response = await shopifyResponse.json(); | |
| let response = await shopifyResponse.text(); |
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
| // encode | |
| var s = '' | |
| var c, d, e, f, g, h, i, j, o, b = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=", k = 0, l = 0, m = "", n = []; | |
| do c = s.charCodeAt(k++), d = s.charCodeAt(k++), e = s.charCodeAt(k++), j = c << 16 | d << 8 | e, f = 63 & j >> 18, g = 63 & j >> 12, h = 63 & j >> 6, i = 63 & j, n[l++] = b.charAt(f) + b.charAt(g) + b.charAt(h) + b.charAt(i); while (k < s.length); | |
| m = n.join(""), o = s.length % 3; | |
| s = (o ? m.slice(0, o - 3) :m) + "===".slice(o || 3); | |
| // decode | |
| var s = '' | |
| var b, c, d, e = {}, f = 0, g = 0, h = "", i = String.fromCharCode, j = s.length; |
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
| // trigger: When webhook received | |
| // action: run script | |
| let env = input.config(); | |
| // TODO: verify webhook | |
| // python ex | |
| // hmac.compare_digest( | |
| // base64.b64encode( | |
| // hmac.new( |
NewerOlder