Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
ベンダー開発モジュールの使い方
Search
yascaim
November 20, 2019
Technology
2.6k
3
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
ベンダー開発モジュールの使い方
20191120 Ansiblejp ネットワーク部 LTで使用
yascaim
November 20, 2019
Transcript
17 slides
1 ベンダー開発の モジュールの使い方 (オマケ) 手順書をPlaybook化 するときに気にしてる事 @yascaim1
2 仕事:DCNWの設計、構築? 好きなもの: - Ansible - ボードゲーム - 数学
- ケーキ Ansible歴:1年6か月 自己紹介
3 A10製品とAnsible
4 A10networksとは 製品概要: - ロードバランサー、セキュリティプラットフォームなど - CLI,GUI,APIが揃ってて ”Cisco” 触った人なら馴染み易い -
まだ商用で使えてないけど面白い機能が結構ある
5 https://docs.ansible.com/ansible/latest/modules/list_of_network_modules.html モジュールはどうなの?
6 あるところにはある 大体1,600くらい(やべー https://github.com/a10networks/a10-ansible
7 用法用量を守らない使い方
8 Ansibleもくもく会 また企画したろ。 モジュール増えたなぁ とりあえずgit clone したろ。 検証環境で ワークショップの復習だ!
9 Playbook全部動かない...ッ!
10 今のところ見つけた差分: - NW機器の接続プロトコルの書き方が違う - パラメータの名前が変わってて”undefined” - パラメータの型が変わってる - パラメータで指定できる値が変わってる
tasks: - name: Enable ethernet interfaces a10_interface_ethernet: a10_host: "{{ a10_host }}" a10_port: "{{ a10_port }}" a10_username: "{{ a10_username }}" a10_password: "{{ a10_password }}" ifnum: "{{ item.ifnum }}" action: enable state: present partition: test with_items: - { ifnum: 1 } - { ifnum: 2 } tasks: - name: Enable ethernet interfaces a10_interface_ethernet: a10_host: "{{ a10_host }}" a10_port: "{{ a10_port }}" a10_username: "{{ a10_username }}" a10_password: "{{ a10_password }}" a10_protocol: “https” ifnum: "{{ item.ifnum }}" action: enable state: present a10_partition: name: test shared: 0 with_items: - { ifnum: 1 } - { ifnum: 2 } プロトコル指定が requiredなパラメータで増えた パラメータの名前が変わってる 気付いたら辞書型になってる shared指定の仕方が変わってる
11 メリデメの整理
12 メリット: - やりたいこと:モジュール が 1:1で大体ある - YAMLで書くため、機器初心者でも可読性が高い - 強制的にモジュールのコードを読むことになる デメリット:
- Ansible docのリリースノートに載ってない - OSのリリースノートにも載ってない - モジュールを使ったサンプルコードが落ちてない 用法用量は模索中
13 まとめ
14 - 当然ですが商用環境でいきなりアップデートはやらない - github見て何かが違う!?って思ったらサポートに聞く - 極力、変数はPlaybookの外で管理する - library を別の
directoryで管理する(ansible.cfgで切替える)
ご清聴ありがとうございました! 15
16 おまけ(気を付けてること編)
17 動作確認 事前ログ取得 事後ログ取得 設定変更 ・どこから何を確認するかを明記 ・「異常がないこと」という記載を一切排除 ・作業前との比較結果 ↑全て比較、一致、含む、含まない で記述 ・設定変更/追加する順序を考える
- script投入の順番 - 作業機器の順番 ・作業を切り戻す際の順序を考える ・検証環境で絶対試す 最初からAnsible化することを想定し、 Playbookにし易い手順書を常に心がける。
More Decks by yascaim
See All by yascaim
Ansible Towerでやってること、やれること、やりたいこと
yascaim
3
2.4k
Other Decks in Technology
See All in Technology
あの日、見つかっていなかったらどうなっていたか
kazzpapa3
2
230
サーバーラックは作る時代! 3Dプリンターで作る10インチラックのススメ
jacopen
1
200
E2E Test というハーネス — AI時代の自動テスト民主化
daishukojima
5
2k
JAWS_FESTA2026_オンプレ-AWS間プロキシサーバの移行_性能_障害対応で得た実践ノウハウ_高島一晃.pdf
tkazuaki0820
1
140
プロダクションコードにおける encoding/json から encoding/json/v2 へのスムーズな移行
sansantech
PRO
1
440
Context Ontology Accelerator 入門 (業務データの意味を、AI エージェントに渡す)
inariku
PRO
3
690
Reticulum, le réseau cypherpunk dont vous avez besoin !
rlifchitz
0
150
Re:ゼロから始めるシェアハウスのペットな鯖
silmin_
0
140
SSFの現在地 ― CAEP/RISCからAI Identityへ
oidfj
0
450
Oracle Base Database Service 技術詳細
oracle4engineer
PRO
17
120k
An Introduction to Context Ontology Accelerator (teaching AI agents what your data means)
inariku
PRO
1
270
20261113_JAWS_Osaka
takuyay0ne
0
510
Featured
See All Featured
How Software Deployment tools have changed in the past 20 years
geshan
3
35k
Pawsitive SEO: Lessons from My Dog (and Many Mistakes) on Thriving as a Consultant in the Age of AI
davidcarrasco
1
300
Designing for humans not robots
tammielis
254
26k
How To Stay Up To Date on Web Technology
chriscoyier
790
250k
Lightning Talk: Beautiful Slides for Beginners
inesmontani
PRO
2
840
Designing for Timeless Needs
cassininazir
1
560
How to Get Subject Matter Experts Bought In and Actively Contributing to SEO & PR Initiatives.
livdayseo
1
240
Principles of Awesome APIs and How to Build Them.
keavy
128
18k
Redefining SEO in the New Era of Traffic Generation
szymonslowik
1
530
Making the Leap to Tech Lead
cromwellryan
135
10k
Building a Scalable Design System with Sketch
lauravandoore
464
34k
Unlocking the hidden potential of vector embeddings in international SEO
frankvandijk
0
1k