반응형 AWS89 CH03_02 패커 다루어보기 이번에는 패커를 이용해서 AWS의 AMI를 만들어보자 앞으로 진행할 실습 코드들은 아래 링크에서 확인할 수 있다. https://github.com/tedilabs/fastcampus-devops/tree/main/2-packer GitHub - tedilabs/fastcampus-devops: 🚀 패스트캠퍼스 데브옵스 초격차 코스 자료 🚀 패스트캠퍼스 데브옵스 초격차 코스 자료. Contribute to tedilabs/fastcampus-devops development by creating an account on GitHub. github.com terraform의 파일 확장자는 .tf 였지만 packer의 파일 확장자는 .pkr.hcl 이다. 코드의 최상단에는 packer 블록이 있는데 이는 필.. 2022. 6. 7. CH03_01 패커 소개 패커는 이미지 빌더이다. AWS ec2 같은 경우에는 AMI, Docker 같은 경우에는 Image 와 같이 여러 플랫폼들의 머신 이미지들을 하나의 소스 설정으로 생성시킨다. 패커의 상태는 코드로 관리할 수 있게에 GitOps를 통해 협업이 가능해진다. 페커의 템플릿은 HCL 템플릿과 JSON 템플릿으로 두 가지 타입이 있다. 현재는 HCL 템플릿이 주로 사용된다. https://www.packer.io/docs/templates/hcl_templates Packer by HashiCorp Packer uses text files to describe infrastructure and to set variables. These text files are called Packer _configuration.. 2022. 6. 7. CH02_17. 테라폼 워크스페이스 디렉토리 구성 전략 아래 링크에서 테라폼 공식 convention으로 구성된 디렉토리 구조를 보자 https://github.com/tedilabs/fastcampus-devops/tree/main/2-terraform/15-directory-structure GitHub - tedilabs/fastcampus-devops: 🚀 패스트캠퍼스 데브옵스 초격차 코스 자료 🚀 패스트캠퍼스 데브옵스 초격차 코스 자료. Contribute to tedilabs/fastcampus-devops development by creating an account on GitHub. github.com 구성하고자 하는 리소스(ex: nacl.tf, nat.tf, routes.tf, subnet.tf, vpc.tf, vpc endpoints.t.. 2022. 6. 4. CH02_16. 테라폼 terraform_remote_state 데이터소스 활용 테라폼의 remote state는 data 블록으로 열여서 데이터소스로 활용할 수 있다. https://registry.terraform.io/providers/hashicorp/terraform/latest/docs/data-sources/remote_state Terraform Registry registry.terraform.io 인프라 규모가 커진다면 여러 워크스페이스로 인프라 관리를 하게 될 것이다. 그리고 여러 워크스페이스 간에 의존성이 생길 수 있는데 의존하는 워크스페이스의 attribute를 참조해야 할 때 remote state를 사용하면 좋다. local backend를 사용할 때는 backend 속성을 local로 지정하고 config블록에서 path를 지정한다. remote back.. 2022. 6. 4. 이전 1 ··· 6 7 8 9 10 11 12 ··· 23 다음 반응형