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

port_mokumoku_lt_ec2-toys

 port_mokumoku_lt_ec2-toys

E8ac626646da35420ffba5da02f4787d?s=128

Shuichi Ohsawa

September 24, 2016
Tweet

Transcript

  1. EC2Πϯελϯε΁ͷSSHΛ ศར͢ΔπʔϧΛGoݴޠͰ࡞ͬͨ @ohsawa0515

  2. ࣗݾ঺հ େᖒलҰ (@ohsawa0515) GitHub: https://github.com/ohsawa0515 Blog: http://blog.jicoman.info/

  3. ͭ͘Γ·ͨ͠ • ec2-toys • https://github.com/ohsawa0515/ec2-toys • Amazon EC2 ΛΞϨίϨ͢Δπʔϧ(༧ఆ)

  4. ͳͥͭͬͨ͘ͷ͔ • αʔόʹSSH͢ΔͷΛָʹ͔ͨͬͨ͠ • ࣗ෼PC -> ౿Έ୆αʔό -> ໨తαʔό ͱ2ճSSH͢Δඞཁ͕͋Δ

    • αʔόͷIPΞυϨεΛҰʑௐ΂Δͷ͕໘౗͍͘͞ • ssh_config ʹ ProxyCommand ΛೖΕΔ͜ͱͰ1ճͰSSHͰ͖Δ͕ɺ EC2Πϯελϯε͕૿͑ͨΓݮͬͨΓ͢Δͷʹ߹Θͤͯssh_config Λ ॻ͖׵͑Δͷ͸ਏ͍ • ଞʹಉ͡πʔϧ͕͋Δ͕࢖͍উख͕ѱ͍(ಈ͔ͳ͍ etc)
  5. Πϯετʔϧ&ઃఆ • $ go get -u github.com/ohsawa0515/ec2-toys • $ export

    AWS_ACCESS_KEY_ID=ACCESS_KEY_ID • $ export AWS_SECRET_ACCESS_KEY=ECRET_ACCESS_KEY • $ export AWS_REGION=us-east-1
  6. ४උ • ~/.ssh/config • ࢀߟ: ࠷ڧͷSSH౿Έ୆ઃఆ • http://qiita.com/kawaz/items/a0151d3aa2b6f9c4b3b8 )PTUTUFQTFSWFS 

    1SPYZ$PNNBOETTI8 CBTFOBNFI Q EJSOBNFlI  )PTUTUFQTFSWFS )PTUOBNFYYYYYYYYYYY 6TFSGPP *EFOUJUZ'JMFdTTIJE@STB
  7. ࣮ߦ FDUPZTMJTUpMUFST/BNFJOTUBODFTUBUFOBNF 7BMVFTSVOOJOHcQFDPc BXL\QSJOU^cYBSHT*\^TIDTTIlTUFQTFSFS\^EFWUUZTTI pecoΛ࢖͍·͢ɻ

  8. ·ͱΊ • Amazon EC2 ΛΞϨίϨ͢ΔπʔϧΛ࡞Γ·ͨ͠ • ػೳͱͯ͠͸ෆे෼ͳͷͰ͜Ε͔ΒΞοϓσʔτ ͍͖ͯ͠·͢ʂ • Goݴޠָ͍͠ʂ