Skip to Content
코드로 인프라 관리하기: 효율적인 인프라 관리를 위한 자동화 방법
book

코드로 인프라 관리하기: 효율적인 인프라 관리를 위한 자동화 방법

by 강재준
May 2017
Beginner to intermediate
400 pages
7h 33m
Korean
Hanbit Media, Inc.
Content preview from 코드로 인프라 관리하기: 효율적인 인프라 관리를 위한 자동화 방법
86
코드로 인프라 관리하기
default
=
{
qa
=
"
subnet
-
12345678
"
stage
=
"
subnet
-
abcdabcd
"
prod
=
"
subnet
-
a1b2c3d4
"
}
}
resource
"
aws
_
instance
"
"
web
"
{
instance
_
type
=
"
t2
.
micro
"
ami
=
"
ami
-
87654321
"
subnet
_
id
=
"${
lookup
(
var
.
subnets
,
var
.
environment
)}"
}
이 정의와 스핀 스크립트 간의 차이는 동일한 인자로 여러 번 실행했을 때 나타난다. 동일한 환
경과 동일한 웹 서버 역할을 지정해 스핀 스크립트를 다섯 번 실행하면, 동일한 웹 서버 다섯
대가 생성될 것이다. 테라폼 정의는 다섯 번 적용하더라도 단 하나의 웹 서버만 생성할 것이다.
3
.
3
.
3
인프라 정의 도구 사용하기
인프라 정의 도구 대부분은 명령줄 도구를 사용해 구성 정의를 적용한다. 예를 들어 테라폼 정
의 예제를
web
_
server
.
tf
라는 파일로 저장했다면, 웹 서버를 생성하거나 업데이트하는 명령
줄 도구는 다음과 같은 명령어를 사용해 실행될 것이다.
#
terraform apply
-
var environment
=
qa web
_
server
.
tf
인프라 팀원이 로컬 워크스테이션이나 노트북에서 이 도구를 실행할 수도 있지만, 무인 방식으
로 실행하는 것이 더 좋다. 대화식으로 도구를 실행하는 방식은 개인 샌드박스
sandbox
인스턴스
에 정의를 먼저 적용해 인프라 변경을 시험해보는 데 편리하다.
그러나 정의 파일은 ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.

Read now

Unlock full access

More than 5,000 organizations count on O’Reilly

AirBnbBlueOriginElectronic ArtsHomeDepotNasdaqRakutenTata Consultancy Services

QuotationMarkO’Reilly covers everything we've got, with content to help us build a world-class technology community, upgrade the capabilities and competencies of our teams, and improve overall team performance as well as their engagement.
Julian F.
Head of Cybersecurity
QuotationMarkI wanted to learn C and C++, but it didn't click for me until I picked up an O'Reilly book. When I went on the O’Reilly platform, I was astonished to find all the books there, plus live events and sandboxes so you could play around with the technology.
Addison B.
Field Engineer
QuotationMarkI’ve been on the O’Reilly platform for more than eight years. I use a couple of learning platforms, but I'm on O'Reilly more than anybody else. When you're there, you start learning. I'm never disappointed.
Amir M.
Data Platform Tech Lead
QuotationMarkI'm always learning. So when I got on to O'Reilly, I was like a kid in a candy store. There are playlists. There are answers. There's on-demand training. It's worth its weight in gold, in terms of what it allows me to do.
Mark W.
Embedded Software Engineer

You might also like

스파크를 이용한 자연어 처리 : 대규모 텍스트를 다루는 가장 효율적인 딥러닝을 만나다

스파크를 이용한 자연어 처리 : 대규모 텍스트를 다루는 가장 효율적인 딥러닝을 만나다

이창현, 앨릭스 토머스
클라우드 엔지니어를 위한 97가지 조언

클라우드 엔지니어를 위한 97가지 조언

Emily Freeman, Nathen Harvey, 정기훈(Jung Ki Hun)

Publisher Resources

ISBN: 9788968483431