- Best place to get started
- https://eksworkshop.com/
- Talk Minikube
- Talk Play with Kubernetes
- https://labs.play-with-k8s.com/
- EKS Service Role
- Create EKS Cluster (with same user who will use kubectl)
- Talk about IAM and K8s RBAC
- What is kubectl?
- Use AWS CLI to update kubeconfig
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: Namespace | |
metadata: | |
name: sock-shop | |
--- | |
apiVersion: extensions/v1beta1 | |
kind: Deployment | |
metadata: | |
name: carts-db |
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
AWSTemplateFormatVersion: "2010-09-09" | |
Description: >- | |
EKS for us-east-1 with Kubernetes Object deployment support. | |
Resources: | |
##### START VPC RESOURCES ##### | |
VPC: | |
Type: AWS::EC2::VPC | |
Properties: | |
CidrBlock: 10.0.0.0/16 | |
InstanceTenancy: default |
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: Namespace | |
metadata: | |
name: gremlin |
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
using System; | |
using System.Threading.Tasks; | |
using Amazon.SQS; | |
using Amazon.SQS.Model; | |
using Newtonsoft.Json; | |
using SQSConsumer.Models; | |
using Amazon.SimpleSystemsManagement; | |
using Amazon.SimpleSystemsManagement.Model; | |
using System.Collections.Generic; | |
using Amazon.DynamoDBv2.DataModel; |
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
AWSTemplateFormatVersion: "2010-09-09" | |
Description: >- | |
This template creates a Multi-AZ, multi-subnet VPC infrastructure with managed NAT | |
gateways in the public subnet for each Availability Zone. You can also create additional | |
private subnets with dedicated custom network access control lists (ACLs). If you | |
deploy the Quick Start in a region that doesn't support NAT gateways, NAT instances | |
are deployed instead. **WARNING** This template creates AWS resources. You will | |
be billed for the AWS resources used if you create a stack from this template. QS(0027) | |
Resources: | |
##### START VPC RESOURCES ##### |
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
package com.sf.handler; | |
import com.amazonaws.services.lambda.runtime.Context; | |
import com.amazonaws.services.lambda.runtime.RequestHandler; | |
import com.amazonaws.services.lambda.runtime.events.SQSEvent; | |
import com.amazonaws.services.lambda.runtime.events.SQSEvent.SQSMessage; | |
import com.amazonaws.services.secretsmanager.*; | |
import com.amazonaws.services.secretsmanager.model.*; | |
public class WorkflowExecuteHandler implements RequestHandler<SQSEvent, Void>{ |
This CloudFormation template creates an API Gateway that will pass all JSON data sent as a PUT request to Kinesis Firehose which in turn deposits the data into S3.
aws cloudformation describe-stacks --stack-name <STACK_NAME> --query Stacks[].Outputs[].[OutputKey,OutputValue]
curl -X PUT -H 'Content-Type: application/json' -d '{"event":"sent"}' https://xd8tc7fim2.execute-api.us-east-1.amazonaws.com/prod
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
const AWS = require('aws-sdk'); | |
module.exports.handler = async (event) => { | |
console.log(JSON.stringify(event, 2)); | |
const { send, connectionId } = getSocketContext(event); | |
await send( | |
JSON.stringify( | |
{ |
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
$results = Get-Content -Path './transcribe/results.json' | ConvertFrom-Json | |
$items = $results.results.items | |
# only works on macOS | |
Start-Process afplay -ArgumentList @('./transcribe/cropped_podcast.mp3') -NoNewWindow | |
$counter = 1 | |
foreach ($item in $items) { | |
if ($item.end_time -lt $counter) { | |
if ($item.alternatives[0].content -eq '.') { | |
write-host -NoNewline $item.alternatives[0].content |