Upgrade to Pro — share decks privately, control downloads, hide ads and more …

CNCF Linz meetup - Taming and Testing the Cloud...

CNCF Linz meetup - Taming and Testing the Cloud Environment from localhost to CI

CNCF Meetup in Linz on the 21st of November 2023

Anca Ghenade

November 23, 2023
Tweet

More Decks by Anca Ghenade

Other Decks in Programming

Transcript

  1. 2. Developing on a local machine, they soon find out

    that there are lots of dependencies with resources in the cloud
  2. 3. They realize that the dev & test loop is

    extremely slow and tedious. Every local change needs to be packaged and uploaded to the cloud for testing.
  3. 4. Now a Software Ninja has a red build on

    their feature branch, but can’t efficiently test and debug their code in the CI/CD pipeline.
  4. 5. The whole team is using Git flow for development

    - one CI build per feature branch. There is an explosion of different environments required for development (branches x developers).
  5. 6. The Ninja manager approaches the team and complains that

    AWS dev/test resources are not being cleaned up properly causing cost spikes.
  6. Title: Complexity and Risk - Setting up an AWS developer

    sandbox. - Making sure you have the right permissions to not blow up resources. - “Who is worthy of AWS access?”
  7. Title: The Fear That someone leaves resources on overnight… You

    get an email from your boss’ boss’ boss the next morning.
  8. Title: Running out of Time - Your application is never

    fully tested before release. - AWS is slow to create and handle all those resources.
  9. Title: Wasted Time & Money Disaster recovery testing was not

    done thoroughly dues to costs. You think you’re safe, but you’re not.
  10. How much of your system you can test Cloud emulation

    Full cloud emulation with service integration Staging environments Highest fidelity because it actually runs in the cloud Mocking Mock out cloud APIs What are our options in terms of testability? 3 4 Service emulation Replace individual services with local versions 2 1
  11. What is LocalStack and how can it help you? A

    fully functional local cloud stack that was born out of these exact concerns.
  12. • Enables a highly efficient dev & test loop for

    cloud apps • Ships as a Docker image, easy to install and start up • Support for 90-ish services (and growing): ◦ compute (Lambda, ECS, EKS) ◦ various databases (DynamoDB, RDS) ◦ messaging (SQS, Kinesis, MSK) ◦ some sophisticated/exotic APIs (Athena, Glue) • CI integrations & advanced collaboration features • Branching out into other areas: Chaos Engineering, IAM Security Testing, Cloud Ephemeral Environments, 3rd Party Extensions, etc
  13. • Automated Testing • Continuous Deployment • Integration Testing •

    Code Quality Analysis • Infrastructure as Code (IaC) Validation • Containerization and Orchestration • Feature Branch Testing • Rollbacks and Blue/Green Deployments • Performance Testing and Scalability • Automated Documentation Generation
  14. • Automated Testing • Continuous Deployment • Integration Testing •

    Code Quality Analysis • Infrastructure as Code (IaC) Validation • Containerization and Orchestration • Feature Branch Testing • Rollbacks and Blue/Green Deployments • Performance Testing and Scalability • Automated Documentation Generation
  15. Some things cannot just easily be tested, you need a

    certain amount of reality in order to do that.
  16. What if there’s a breaking change in the latest version

    of our mocked dependency? The mock doesn’t care, it will just do what you tell it to do.
  17. 1/2

  18. 2/2

  19. Cloud Pods Persistent Shareable Sandboxes Cloud Pods are a mechanism

    that allows you to take a snapshot of the state in your current LocalStack instance, persist it to a storage backend, and easily share it with your team members.
  20. Just FYI - Top 3 podium - Game of correctness

    and agility - You can play as many times as you want