Live data from Hacker News

Ask HN: How do you work with AWS?

news.ycombinator.com

21–30 of 36 posts

Re: Ask HN: How do you work with AWS?

#21

When I'm trying out a new AWS service I start using it through the web console. Once I gain some familiarity with the service and settle into a pattern of manual operations, I translate the manual operations into CLI commands. The most commonly run CLI commands I throw into a shell script. For instance, I started using AWS Lambda by manually uploading the lambda code .zip file through the web console. Later on I wrot…

What about using Serverless or a framwork for Lambda stuff?

(I'm not the one you were replying to, FWIW)

> What about using Serverless or a framwork for Lambda stuff?

If you're using other parts of AWS than Lambda, is there a benefit to using serverless? If I still need to know aws cli for the other services I use, what's the point in learning a specialized tool that only works for one service?

Re: Ask HN: How do you work with AWS?

#22
I've experimented with a few different things and there really are lots of valid ways to work depending on context.

Terraform: at some point you will probably end up here. It gives you so much control, it's fast and (mostly) easy to work with. It gives you a good idea of what it is doing and why.

Cloudformation: mostly I've used this embedded in some other tool. For example we have a fairly small Elastic Beanstalk app which uses SQS and SNS - nice to be able to extend the basic infrastructure easily inline with your app definition. Similar situation with serverless.

Awless: this is a really nice (scriptable!) CLI alternative. Nothing wrong with the normal AWS CLI but this does some things simpler/nicer. If what you are doing is simple enough you can script infrastructure with these tools.

Console: I really use this alongside the other things as I'm building automation or to explore some new service I've not used before.

Ansible: for configuration management (post terraform apply) we are using ansible. So far we set up an admin box inside the infrastructure and run ansible from there. We've experimented with having ansible build the inventory but currently looking at a bash/jq/awless combo to build it dynamically.

Edit: not ever used ansible to modify AWS infrastructure. We keep infrastructure separate with a configuration management separate from setting up the infrastructure.

Re: Ask HN: How do you work with AWS?

#23

Earlier quoted context omitted.

What about using Serverless or a framwork for Lambda stuff?

(I'm not the one you were replying to, FWIW) > What about using Serverless or a framwork for Lambda stuff? If you're using other parts of AWS than Lambda, is there a benefit to using serverless? If I still need to know aws cli for the other services I use, what's the point in learning a specialized tool that only works for one service?

Its less overhead. You don't have to worry about keeping the EC2 instance or web server running/patched/updated/etc. The juice may not worth the squeeze with the extra complexity of using AWS Lambda.

Re: Ask HN: How do you work with AWS?

#24

When I'm trying out a new AWS service I start using it through the web console. Once I gain some familiarity with the service and settle into a pattern of manual operations, I translate the manual operations into CLI commands. The most commonly run CLI commands I throw into a shell script. For instance, I started using AWS Lambda by manually uploading the lambda code .zip file through the web console. Later on I wrot…

What about using Serverless or a framwork for Lambda stuff?

Thanks for the tip, I'll try out Serverless.

Re: Ask HN: How do you work with AWS?

#26

Earlier quoted context omitted.

(I'm not the one you were replying to, FWIW) > What about using Serverless or a framwork for Lambda stuff? If you're using other parts of AWS than Lambda, is there a benefit to using serverless? If I still need to know aws cli for the other services I use, what's the point in learning a specialized tool that only works for one service?

Its less overhead. You don't have to worry about keeping the EC2 instance or web server running/patched/updated/etc. The juice may not worth the squeeze with the extra complexity of using AWS Lambda.

[deleted]

Re: Ask HN: How do you work with AWS?

#27

Earlier quoted context omitted.

What about using Serverless or a framwork for Lambda stuff?

(I'm not the one you were replying to, FWIW) > What about using Serverless or a framwork for Lambda stuff? If you're using other parts of AWS than Lambda, is there a benefit to using serverless? If I still need to know aws cli for the other services I use, what's the point in learning a specialized tool that only works for one service?

Its your call. I like Serverless because it configures all the infrastructure for me, and keeps my lambda code super organized and in an immediately understandable framework.

Its like you COULD just use Ruby to code a site but all the power of Rails adds so much to it!

Re: Ask HN: How do you work with AWS?

#28
post #9

Earlier quoted context omitted.

I generally love Hashicorp's tools, but never really got using Terraform over CloudFormation. I found the cloud-agnostic claim to be a bit of an exaggeration, plus most clients are happy to stick to one provider. Sure, CloudFormation is a bit slow, and the JSON is awful, but with YAML it's okay. And I don't need yet another tool. What am I missing?

I'm not too familiar with using straight up CloudFormation JSON definitions. Are you able to create reusable modules in CloudFormation? In Terraform you're able to create modules that you can use to setup uniform infrastructure. For example, you could have an RDS module that aside from setting up the database it also sets up a replica, a dedicated KMS encryption key, IAM policies, security groups, parameter groups, e…

> Are you able to create reusable modules in CloudFormation?

Not out of the box but Cloudformation templates (jinja2) + Ansible works really well.

Re: Ask HN: How do you work with AWS?

#29
Console to figure out a new service (it’s a quick way to see all the different configuration options). CLI for some actions not supported by the console.

Then once we’ve figured out how we want to use the service, we script the deployment with CloudFormation and put it in an Ansible playbook. This allows us to rebuild everything from scratch, and that’s actually what we do for each deployment. Also makes it super easy to set up a new environment (e.g. to onboard a new team member).

We briefly considered Terraform but the learning curve seemed steep - should we give it another shot?

Re: Ask HN: How do you work with AWS?

#30
post #9

Earlier quoted context omitted.

I generally love Hashicorp's tools, but never really got using Terraform over CloudFormation. I found the cloud-agnostic claim to be a bit of an exaggeration, plus most clients are happy to stick to one provider. Sure, CloudFormation is a bit slow, and the JSON is awful, but with YAML it's okay. And I don't need yet another tool. What am I missing?

I'm not too familiar with using straight up CloudFormation JSON definitions. Are you able to create reusable modules in CloudFormation? In Terraform you're able to create modules that you can use to setup uniform infrastructure. For example, you could have an RDS module that aside from setting up the database it also sets up a replica, a dedicated KMS encryption key, IAM policies, security groups, parameter groups, e…

Arguably you can create a stack that does this and exports the DB identifier to be used in other stacks. It doesn't sound as convenient though, and child stacks have some annoying limitations.
Post reply on HN