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 | |
| UAA_marketplace_name="predix-uaa" | |
| UAA_plan_name="Tiered" | |
| Login_Name="MRO" | |
| #set -x | |
| if (( $EUID != 501 )); then | |
| echo "Please run as predix" |
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
| # Post | |
| https://predix-asset.run.aws-usw02-pr.ice.predix.io/locomotive | |
| # Add a Custom Header | |
| Name: Content-Type | |
| Value: application/json | |
| # Add a Custom Header | |
| Name: x-tenant | |
| Value: eaccfb4a-6ee6-4df1-acab-afbe41aaa506 |
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
| # Do a POST | |
| https://299fbc8e-3050-4392-8047-86d3fcc5a145.predix-uaa.run.aws-usw02-pr.ice.predix.io/oauth/token | |
| #uname | |
| training_client | |
| #password | |
| training_secret | |
| #Custom Header |
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
| Token | |
| eyJhbGciOiJSUzI1NiJ9.eyJqdGkiOiJjMTE4NmY2Mi0yZWY0LTRiYmUtYTAxMS03OThkZTExNDdjYWMiLCJzdWIiOiJ0cmFpbmluZ19jbGllbnQiLCJzY29wZSI6WyJwcmVkaXgtYXNzZXQuem9uZXMuZWFjY2ZiNGEtNmVlNi00ZGYxLWFjYWItYWZiZTQxYWFhNTA2LnVzZXIiLCJ1YWEubm9uZSJdLCJjbGllbnRfaWQiOiJ0cmFpbmluZ19jbGllbnQiLCJjaWQiOiJ0cmFpbmluZ19jbGllbnQiLCJhenAiOiJ0cmFpbmluZ19jbGllbnQiLCJncmFudF90eXBlIjoiY2xpZW50X2NyZWRlbnRpYWxzIiwicmV2X3NpZyI6Ijg3OTgwZDk3IiwiaWF0IjoxNDYyMzc3ODE0LCJleHAiOjE0NjI0MjEwMTQsImlzcyI6Imh0dHBzOi8vMjk5ZmJjOGUtMzA1MC00MzkyLTgwNDctODZkM2ZjYzVhMTQ1LnByZWRpeC11YWEucnVuLmF3cy11c3cwMi1wci5pY2UucHJlZGl4LmlvL29hdXRoL3Rva2VuIiwiemlkIjoiMjk5ZmJjOGUtMzA1MC00MzkyLTgwNDctODZkM2ZjYzVhMTQ1IiwiYXVkIjpbInRyYWluaW5nX2NsaWVudCIsInByZWRpeC1hc3NldC56b25lcy5lYWNjZmI0YS02ZWU2LTRkZjEtYWNhYi1hZmJlNDFhYWE1MDYiXX0.nWX_BLFIWqprCh2bQk_rHU3KNLI0k6beFwlbrU_VAA_dP5zazi50530_Pym_zOMkHOsVFYx3ZiDCb-RoGxrlbIOzgH3bkHj32AMqoq0eX3Jy1nE6bJiX6E83cS8R0a0mI02QeGXr_V7IykIvIZjotZwRly7cOsQBJ8_Kvvtc2CL4q-OfNfVVyTHy9I9mvYfFx0dUGixxrv6PnyjSw9ZWQgQRkPlozEIwm6G4nyLttEZwhdnDB485JzvmS6KwT |
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 | |
| yum install perl-Switch perl-DateTime perl-Sys-Syslog perl-LWP-Protocol-https -y | |
| curl http://aws-cloudwatch.s3.amazonaws.com/downloads/CloudWatchMonitoringScripts-1.2.1.zip -O | |
| unzip CloudWatchMonitoringScripts-1.2.1.zip | |
| rm CloudWatchMonitoringScripts-1.2.1.zip |
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
| # create a vault | |
| aws glacier create-vault --account-id - --vault-name my-vault-name | |
| # check that the vault was created successfully | |
| aws glacier describe-vault --account-id - --vault-name my-vault-name | |
| # upload a file to the vault | |
| aws glacier upload-archive --vault-name my-vault-name --account-id - --archive-description "my-archive-description" --body my-text-file.txt | |
| # request an inventory of the vault |
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: node_js | |
| node_js: | |
| - '8' | |
| cache: | |
| yarn: true | |
| directories: | |
| - node_modules | |
| script: | |
| - yarn test | |
| before_deploy: |
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 boto3 | |
| import logging | |
| #setup simple logging for INFO | |
| logger = logging.getLogger() | |
| logger.setLevel(logging.INFO) | |
| #define the connection | |
| ec2 = boto3.resource('ec2') |
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
| apiVersion: v1 | |
| kind: Pod | |
| metadata: | |
| name: kuard | |
| spec: | |
| containers: | |
| - image: gcr.io/kuar-demo/kuard-amd64:1 | |
| name: kuard | |
| ports: | |
| - containerPort: 8080 |
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
| <td>{{book.price | currency:'EUR':'symbol':'1.2-2':'de-DE'}}</td> |
OlderNewer