Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
君の開発環境再現できる?~ローカルで始めるAnsible入門~ / An Introducti...
Search
Pudding
PRO
June 29, 2018
Programming
0
170
君の開発環境再現できる?~ローカルで始めるAnsible入門~ / An Introduction of Ansible
複雑怪奇な魔界となってしまいがちな開発環境を,プロビジョニングツールを使ってちゃんと管理したくないですか?という話
Pudding
PRO
June 29, 2018
Tweet
Share
More Decks by Pudding
See All by Pudding
GNU Make勉強会 / GNU Make Exercise
pddg
PRO
2
9.3k
雑に覚えるVim / Vim Tutorial
pddg
PRO
0
70
中古PCのススメ/The fundamentals of used PC
pddg
PRO
1
58
もっと気楽にいきましょうって話 / Make more relax
pddg
PRO
4
2.1k
アイデアの卵と動かざる手 / Do you have something to do to realize your idea?
pddg
PRO
0
150
Docker Seminar for SEL@KIT
pddg
PRO
0
95
進学先を間違ったなと思ったら / I made a mistake in my path
pddg
PRO
0
110
なぜ平文パスワードはNGなのか / Why are plain passwords evil?
pddg
PRO
1
150
Mizql Map @ KITハッカソン2018 by ツナ缶 / Mizql Map
pddg
PRO
0
92
Other Decks in Programming
See All in Programming
TypeScriptでライブラリとの依存を限定的にする方法
tutinoko
2
660
OnlineTestConf: Test Automation Friend or Foe
maaretp
0
110
とにかくAWS GameDay!AWSは世界の共通言語! / Anyway, AWS GameDay! AWS is the world's lingua franca!
seike460
PRO
1
860
色々なIaCツールを実際に触って比較してみる
iriikeita
0
330
聞き手から登壇者へ: RubyKaigi2024 LTでの初挑戦が 教えてくれた、可能性の星
mikik0
1
130
3rd party scriptでもReactを使いたい! Preact + Reactのハイブリッド開発
righttouch
PRO
1
600
Better Code Design in PHP
afilina
PRO
0
120
『ドメイン駆動設計をはじめよう』のモデリングアプローチ
masuda220
PRO
8
540
Outline View in SwiftUI
1024jp
1
330
Remix on Hono on Cloudflare Workers
yusukebe
1
280
3 Effective Rules for Using Signals in Angular
manfredsteyer
PRO
0
100
CSC509 Lecture 12
javiergs
PRO
0
160
Featured
See All Featured
Writing Fast Ruby
sferik
627
61k
A Philosophy of Restraint
colly
203
16k
Fantastic passwords and where to find them - at NoRuKo
philnash
50
2.9k
Practical Tips for Bootstrapping Information Extraction Pipelines
honnibal
PRO
10
720
Designing the Hi-DPI Web
ddemaree
280
34k
Happy Clients
brianwarren
98
6.7k
Fireside Chat
paigeccino
34
3k
Thoughts on Productivity
jonyablonski
67
4.3k
Java REST API Framework Comparison - PWX 2021
mraible
PRO
28
8.2k
Fight the Zombie Pattern Library - RWD Summit 2016
marcelosomers
232
17k
Sharpening the Axe: The Primacy of Toolmaking
bcantrill
38
1.8k
Large-scale JavaScript Application Architecture
addyosmani
510
110k
Transcript
君の 開発環境 できる? ʙϩʔΧϧͰ࢝ΊΔ"OTJCMFೖʙ
Ctrl+C Ctrl+V
None
յΕͨ ৽ௐͨ͠
ʁʁʁʁʁʁ Ͳ͏ΔΜ͚ͩͬ ʁʁʁʁʁʁ
ߏཧ͠Α͏ʂ
ίϯϐϡʔλγεςϜͷจ຺ʹ͓͍ͯ ˔ ΠϯϑϥʢωοτϫʔΫɼΫϥυʣཧ ˔ 04ͷઃఆ ˔ ϛυϧΣΞͷΠϯετʔϧ ˔ ϛυϧΣΞͷઃఆ ˔
ιϑτΣΞͷґଘؔղফ ˔ ιϑτΣΞӡ༻ͷࡍͷઃఆ ͳͲΛߦ͏͜ͱ ߏཧͱ
˔ υΩϡϝϯτΛͯ͠ίϐϖʢϒϩάͱ͔ʣ ˓ ίϐϖϛεͨ͠Βʜʁ ˓ ͕૿͑ͨΒʜʁ ˔ γΣϧεΫϦϓτ ˓ จࣈྻͷૢ࡞͕ͱʹ͔ͭ͘Β͍ʢTFEͱBXLͰʜʁʣ
˓ ෳճ࣮ߦͨ͠Βʜʁ ˓ ͕૿͑ͨΒʜʁ ࣗಈԽʜʁ
None
˔ ରϚγϯͷ͋Δ͖ঢ়ଶΛهड़͢Δ º ʮ˘˘ΛΠϯετʔϧ͢Δʯʮ˚˚Λઃఆ͢Δʯ ˓ ʮ˘˘͕Πϯετʔϧ͞Ε͍ͯΔʯʮ˚˚Ͱ͋Δʯ ˔ ΤʔδΣϯτϨε ˓ ରͷϚγϯʹ1ZUIPO͕ೖ͍ͬͯΕ0,
˔ ႈੑ ˓ ͋Δૢ࡞ΛҰճߦͬͯෳճߦͬͯ݁Ռ͕ಉ͡ ˓ ʢͨͩ͠"OTJCMF͕อূ͢ΔൣғͷΈʣ ˔ ZBNMͰهड़͢Δ ˓ ϓϩάϥϛϯάࣝෆཁʢෆཁͱݴͬͯͳ͍ʣ "OTJCMFͷಛ
˔ ΤʔδΣϯτͱɼઃఆΛ ࣮ߦ͢ΔιϑτΣΞ ˔ "OTJCMF44)ͱ1ZUIPOΛ ༻ ˓ ϗετ্ͷ1ZUIPO͕࣮ߦ ˓ ओཁͳ-JOVYσΟετϦϏϡʔ
γϣϯʹجຊతʹ1ZUIPO ·͕ͨଘࡏ ˓ ࣮࣭ΤʔδΣϯτϨε ˓ ϩʔΧϧͰQZUIPO͕ ͋Εಈ͘ ΤʔδΣϯτϨε 44) ΫϥΠΞϯτ ϗετ
˔ IPHFDPOGʹ4&$3&5IPHFͱॻ͖ࠐΈ͍ͨ ˔ ͍Ζ͍Ζͳํ๏͕͋Δ ˓ FDIPͰه ˓ DBUͰॻ͖ࠐΈ ˓ ͦͦॻ͖ࠐΜͰ͓͍ͨͷΛίϐʔ
ႈੑ $ echo "SECRET=hoge" >> hoge.conf $ echo "SECRET=hoge" | tee hoge.conf $ cat << EOF >> hoge.conf SECRET=hoge EOF $ cp hoge.conf /path/to/hoge.conf
IPHFDPOG ˔ ෳճ࣮ߦͨ͠Βʜʁ ႈੑ ˔ ႈͰ͋Δͱ͍͏͜ͱɼҰճͷ࣮ߦͰෳճ ͷ࣮ߦͰ݁Ռ͕มΘΒͳ͍͜ͱ IPHFDPOG 4&$3&5IPHF IPHFDPOG
IPHFDPOG 4&$3&5IPHF 4&$3&5IPHF 4&$3&5IPHF ճ ճ IPHFDPOG IPHFDPOG 4&$3&5IPHF IPHFDPOG IPHFDPOG 4&$3&5IPHF 4&$3&5IPHF ճ ճ
˔ γΣϧεΫϦϓτͰอূ͢Δͷ͍͠ ˓ ͦͷΈΛߟ͑Δ͚ͩͰͭΒ͍ ˔ هͰͳ্͘ॻ͖ʹ͢Ε͍͍ͷͰʜʁ ˓ ඞཁͳઃఆΛશͯهड़͢Δඞཁ͕ग़ͯ͘Δ ˓ ߋ৽࣌มߋ͞Εͯ͠·͏
˔ "OTJCMFͰMJOFJOpMFϞδϡʔϧ͕͑Δ ˓ طʹͦͷߦ͕ଘࡏ͢Δ߹ɼه͠ͳ͍ ˓ ͪΖΜߋ৽࣌มߋ͞Εͳ͍ ˓ ࣮ߦ͢Δʹک͑ͳͯ͘ࡁΉ ႈੑ
˔ ΄Ͳ͋ΔΒ͍͠ʁʢʣ ˔ جຊతͳૢ࡞ ˓ pMFɿϑΝΠϧɾσΟϨΫτϦͷૢ࡞ ˓ DPQZɿϑΝΠϧͷίϐʔ ˓ TIFMMɿγΣϧεΫϦϓτͷ࣮ߦ
˔ ύοέʔδཧ ˓ BQUɾCSFXɾZVNɾDIPDPɾQBDNBOʜ ˔ Ϋϥυ ˓ "84ɾ"[VSFɾ($1ʜ "OTJCMFNPEVMFT
ZBNM - block: - name: Obtain ubuntu code name shell:
lsb_release -cs register: ubuntu_codename changed_when: False - name: Create apt list dir file: path: /etc/apt/sources.list.d state: directory owner: root become: yes - name: Add IIJ and JAIST server to apt li template: src: 'templates/{{ item }}.list' dest: '/etc/apt/sources.list.d/{{ item owner: root become: yes with_items: - iij - jaist - name: Install python-apt package pip: name: python-apt become: yes tags: apt_add ˔ ઃఆϑΝΠϧͱͯ͠ ଟ͘࠾༻͞Ε͍ͯΔ ˔ Մಡੑ͕ൺֱతߴ͘ɼ ͍֮͑͢จ๏ ʢ΄Μ·͔ʣ ˔ ๛ͳઃఆྫ͕ωοτ ্ʹ͋Δ
"OTJCMF1MBZCPPL 1MBZCPPLʢFY։ൃڥߏஙʣ 3PMFʢFYWJNʣ 5BTL 5BTL FYΠϯετʔϧ .PEVMF .PEVMF FYWJNSDஔ .PEVMF
.PEVMF .PEVMF .PEVMF 5BTL 5BTL 5BTL 5BTL 3PMF 3PMF
˔ ࠷ॳʹ"OTJCMFΛΠϯετʔϧ͢ΔͷࣗಈԽ ͢Δͷ͘͠ͳ͍ ˓ γΣϧεΫϦϓτͰ͍͍ͩͨԿͱ͔ͳΔ ˔ .BDͰ"EPCFɼ.40⒏DFΛআ͍ͨ΄΅શͯ ˓ ޙ্ཱͪ͛ͯϩάΠϯ͢Δ͚ͩͳͲ͕ଟ͍ ˓
1MBZCPPLΛ࣮ߦͯ࣌ؒ͠΄Ͳ͚ͭͩ ˔ 6CVOUVͰ(6*ΞϓϦέʔγϣϯҎ֎ ˓ +FUCSBJOTͷ*%&ͱ͔ ˔ 8JOEPXT༻ͷϞδϡʔϧ͋Δʹ͋Δ ˓ 84-ͷ6CVOUVͷηοτΞοϓ͔ͯ͠͠ͳ͍ ࠓͷͱ͜ΖࣗಈԽ͍ͯ͠Δͷ
˔ ։ൃڥߏஙָ͕ʹͳΔ ˓ Ҿ͖ܧ͗ʹ͑Δ ˔ ڥ͕ݪҼͷόάͷ࠶ݱΛ औΓ͍͢ ˓ ಉҰͷڥͷ෮ݩ͕༰қ ˔
ཧղͷ্ ˔ Ϋϥυద༻͢Δ࿅श ˓ ຊདྷͷతଟͷϗετͷཧ ˓ ϩʔΧϧͰ͍ํΛֶͿ͜ͱ ൺֱతϋʔυϧ͕͍ ࣗಈԽͯ͠Կ͕خ͍͠ͷʁ
˔ ීஈԿؾͳ࣮͘ߦ͍ͯ͠ΔίϚϯυͷҙຯΛ ߟ͑Δඞཁ͕ग़ͯ͘Δ ˓ zԿΛz࣮ߦ͢Δ͔ΑΓzͳͥz࣮ߦ͢Δͷ͔ ˔ ͍͔ʹखΛಈ͔͞ͳ͍͔ ˓ UPVDIBOEUSZ͠ͳ͍ͱ͍͏ҙຯͰͳ͍ ˓
खಈͰઃఆ͍ͯ͠Δ߲ΛͰ͖Δ͚ͩίʔυʹ͢Δ ˓ (6*ఢ ˔ ࠷ॳ͔Β"OTJCMFͰͬͯ͠·͏ͱ͍͏ख͋Δ ڥߏஙΛࣗಈԽ͢Δʹ
ࣗಈԽ͕͋Δͱ͖ʂ
ͳ͍ͱ͖ʜ
ख࡞ۀΛল͍ͯ ϋοϐʔϥΠϑΛʂ