main.tf 441 B

123456789101112131415161718192021222324252627282930
  1. terraform {
  2. required_providers {
  3. hashicups = {
  4. source = "hashicorp.com/edu/hashicups"
  5. }
  6. }
  7. }
  8. provider "hashicups" {
  9. host = "http://localhost:19090"
  10. username = "education"
  11. password = "test123"
  12. }
  13. resource "hashicups_order" "edu" {
  14. items = [
  15. {
  16. coffee = { id = 3 }
  17. quantity = 2
  18. },
  19. {
  20. coffee = { id = 2 }
  21. quantity = 2
  22. },
  23. ]
  24. }
  25. output "edu_order" {
  26. value = hashicups_order.edu
  27. }