Skip to content

Instantly share code, notes, and snippets.

View inventory.yml
---
# 元ネタ: https://tekunabe.hatenablog.jp/entry/2019/03/10/ansible_inventory_yaml
all:
hosts:
web01:
ansible_host: 127.16.0.1
router:
children:
junos:
ios:
@wate
wate / Vagrantfile
Last active Oct 20, 2018
Let's Scratch 3.0 GUI
View Vagrantfile
# -*- mode: ruby -*-
# vi: set ft=ruby :
Vagrant.configure("2") do |config|
config.vm.box = "histudy/stretch"
config.vm.network "forwarded_port", guest: 8601, host: 8601
config.vm.provider "virtualbox" do |vb|
vb.memory = "1024"
end
# Ansibleのインストール
@wate
wate / install_grafana.yml
Last active Jul 3, 2018
CentOS 7にGrafanaをインストールします
View install_grafana.yml
# ネタ元:https://wiki.infra-workshop.tech/%E5%8B%89%E5%BC%B7%E4%BC%9A%E3%83%AD%E3%82%B0/2018/07/03/Zabbix%26Grafana%E3%81%A7%E7%9B%A3%E8%A6%96%E3%82%92%E5%8F%AF%E8%A6%96%E5%8C%96%E3%81%97%E3%81%A6%E3%81%BF%E3%81%9F
- name: install grafana(CentOS 7 Only)
hosts: all
become: yes
vars:
grafana_plugins:
- alexanderzobnin-zabbix-app
tasks:
- name: add yum repository
yum_repository:
@wate
wate / toJPY.js
Created Jun 28, 2017
EC2インスタンス料金月額日本円化(改)
View toJPY.js
/*
* 元ネタ
*
* EC2インスタンス料金月額日本円化
* http://qiita.com/yuroyoro/items/08cded7662cf494d53f2
*
* YQLを使ってYahoo! Financeから為替レートを取得する
* http://qiita.com/masato/items/6f81bdc89f81a7b6cc3a
*/
$.getJSON("https://query.yahooapis.com/v1/public/yql?q=select%20*%20from%20yahoo.finance.xchange%20where%20pair%20in%20(%22USDJPY%22)&format=json&env=store%3A%2F%2Fdatatables.org%2Falltableswithkeys", function(yqlResult){
@wate
wate / .gitignore
Last active Jun 20, 2017
高火力コンピューティングのセットアップ用?
View .gitignore
# Created by https://www.gitignore.io/api/vagrant
### Vagrant ###
.vagrant/
# End of https://www.gitignore.io/api/vagrant
View sample.tf
provider sakuracloud {
zone = "tk1v"
}
/*
* ロードバランサーを利用するか否か
*/
variable use_loadbalanser {
default = false
}
@wate
wate / install_usacloud.yml
Last active Apr 2, 2017
[title]install "Unofficial" CLI client for the Sakura Cloud
View install_usacloud.yml
---
# Usage
# ---------------------------------
#
# ```
# ansible -i 127.0.0.1, install_usacloud.yml -c local
# ```
#
- hosts: all
tasks:
View servers.tf
provider sakuracloud {
zone = "tk1v"
}
data sakuracloud_archive "debian" {
filter = {
name = "Tags"
values = ["current-stable", "distro-debian"]
}
}
@wate
wate / Vagrantfile
Created Dec 11, 2016
Vagrant Sakura Providerサンプル
View Vagrantfile
# -*- mode: ruby -*-
# vi: set ft=ruby :
Vagrant.configure("2") do |config|
config.vm.box = "dummy"
config.vm.box_url = 'https://github.com/tsahara/vagrant-sakura/raw/master/dummy.box'
config.ssh.username = "ubuntu"
config.vm.provider :sakura do |sakura|
sakura.access_token = "さくらのクラウドAPIにアクセスするためのAPIキー(ACCESS TOKEN)"
View Vagrantfile
# -*- mode: ruby -*-
# vi: set ft=ruby :
Vagrant.configure("2") do |config|
# Every Vagrant development environment requires a box. You can search for
# boxes at https://atlas.hashicorp.com/search.
config.vm.box = "wate/debian-8"
# config.vm.box = " bento/debian-8.4"
You can’t perform that action at this time.