gogetit 0.5.3 → 0.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 148adb0a4d5bf1227bba264f035bf222b6a3c5bf
4
- data.tar.gz: f8d3d1a7f5762574f08acdc470f663c7d103ae9f
3
+ metadata.gz: 12e40cd361023a3ff153bcc3e0287a4cfed104fc
4
+ data.tar.gz: d66b86f684ba545e9cc4b1570700daeccc9e7220
5
5
  SHA512:
6
- metadata.gz: ab49648f3d9db3e552b523716ab85f1271952249fc392a970f812212d3511812256d246e2f2e2d9336b15a550d11ecccc7ed12d089e31def95fbc46ce2662b4e
7
- data.tar.gz: 547011a4d9d806019e802eb6e890080354f521b2ca048c170288e36442b270d268c9f68a7852c03a5c2227c895986060e92e1c229d03bc799013a13f6960fee0
6
+ metadata.gz: a2bc0eed67e003d9d6e8d51118fc4d8c7e4e55433ca0dafad9f3513a201f5e9e3b4e4a1e723e219153590c41dbf7c2c803cc831f1c5e4fb278d01ab62d91f38b
7
+ data.tar.gz: df8b808cc5898aeee76d05554ee0e9c21f0e090742efe0a1cc594979164bd799956d9424d3d0bb499af88a1d36f7ea88eb868bbb791d6ae61db811911b5700e7
data/lib/gogetit/cli.rb CHANGED
@@ -9,11 +9,11 @@ module Gogetit
9
9
 
10
10
  desc 'list', 'List containers and instances, running currently.'
11
11
  def list
12
- puts "Listing LXD containers on #{Gogetit.config[:lxd][:url]}.."
13
- system("lxc list #{Gogetit.config[:lxd][:name]}:")
12
+ puts "Listing LXD containers on #{Gogetit.config[:lxd][:nodes][0][:url]}.."
13
+ system("lxc list #{Gogetit.config[:lxd][:nodes][0][:name]}:")
14
14
  puts ''
15
- puts "Listing KVM domains on #{Gogetit.config[:libvirt][:url]}.."
16
- system("virsh -c #{Gogetit.config[:libvirt][:url]} list --all")
15
+ puts "Listing KVM domains on #{Gogetit.config[:libvirt][:nodes][0][:url]}.."
16
+ system("virsh -c #{Gogetit.config[:libvirt][:nodes][0][:url]} list --all")
17
17
  end
18
18
 
19
19
  desc 'create NAME', 'Create either a container or KVM domain.'
@@ -1,3 +1,3 @@
1
1
  module Gogetit
2
- VERSION = "0.5.3"
2
+ VERSION = "0.6.0"
3
3
  end
@@ -12,7 +12,7 @@ module Gogetit
12
12
 
13
13
  def initialize(conf, maas, logger)
14
14
  @config = conf
15
- @conn = Libvirt::open(config[:libvirt][:url])
15
+ @conn = Libvirt::open(config[:libvirt][:nodes][0][:url])
16
16
  @maas = maas
17
17
  @logger = logger
18
18
  end
data/lib/providers/lxd.rb CHANGED
@@ -11,7 +11,7 @@ module Gogetit
11
11
  def initialize(conf, maas, logger)
12
12
  @config = conf
13
13
  @conn = Hyperkit::Client.new(
14
- api_endpoint: config[:lxd][:url],
14
+ api_endpoint: config[:lxd][:nodes][0][:url],
15
15
  verify_ssl: false
16
16
  )
17
17
  @maas = maas
@@ -1,22 +1,29 @@
1
1
  default:
2
2
  user: ubuntu
3
3
  root_bridge: $root_bridge
4
- # etcd:
5
- # url: http://etcd.example.com:2379
6
- # about MAAS
4
+
7
5
  maas:
8
6
  key: K:E:Y
9
7
  url: http://maas.example.com/MAAS/api/2.0
10
- # about LXD
8
+
11
9
  lxd:
12
- url: https://lxd.example.com:8443
13
- name: REMOTE_NAME
10
+ nodes:
11
+ -
12
+ name: lxd01
13
+ url: https://lxd01.example.com:8443
14
+ -
15
+ name: lxd02
16
+ url: https://lxd01.example.com:8443
14
17
  default_alias: ubuntu-16.04
15
- profiles:
16
- - my_favorite_bridge
17
- # about Libvirt
18
+
18
19
  libvirt:
19
- url: qemu+ssh://WHOAMI@kvm.example.com/system
20
+ nodes:
21
+ -
22
+ name: kvm01
23
+ url: qemu+ssh://$whoami@kvm01.example.com/system
24
+ -
25
+ name: kvm02
26
+ url: qemu+ssh://$whoami@kvm02.example.com/system
20
27
  specs:
21
28
  default:
22
29
  vcpu: 1
@@ -39,7 +46,7 @@ libvirt:
39
46
  -
40
47
  pool: hdd
41
48
  capacity: 8
42
- # about Chef
49
+
43
50
  chef:
44
51
  chef_repo_root: /SOMEWHERE/CHEF_REPO
45
52
  target_environment: THE_ENV_YOU_ARE_TARGETING
@@ -47,12 +54,3 @@ chef:
47
54
  install_script:
48
55
  libvirt: http://chef.example.com/install_chef_script.sh
49
56
  lxd: http://chef.example.com/install_chef_script_for_lxd.sh
50
-
51
- # To configure LXD remote
52
- # lxc remote add host_name host_fqdn --accept-certificate
53
- # i.e) lxc remote add lxd lxd.example.com --accept-certificate
54
- #
55
- # To make sure libvirt connection via ssh available
56
- # ssh-keygen -t rsa
57
- # ssh-copy-id WHOAMI@kvm.example.com
58
- # i.e) ssh-copy-id ubuntu@kvm.example.com
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gogetit
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.3
4
+ version: 0.6.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Don Draper
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-10-18 00:00:00.000000000 Z
11
+ date: 2017-10-19 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler