Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

set hostname using ansible rather than vagrant #13

Merged
merged 1 commit into from
Aug 29, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions Vagrantfile
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,6 @@ config.ssh.insert_key = false # workaround for https://github.com/mitchellh/vagr

(0..MONITORNO - 1).each do |i|
config.vm.define "mon#{i}" do |mon|
mon.vm.hostname = "mon#{i}"
mon.vm.network :private_network, ip: "#{SUBNET}.1#{i}"
mon.vm.provider :virtualbox do |vb|
vb.customize ['modifyvm', :id, '--memory', '192']
Expand All @@ -49,7 +48,6 @@ config.ssh.insert_key = false # workaround for https://github.com/mitchellh/vagr

(0..OSDNO - 1).each do |i|
config.vm.define "osd#{i}" do |osd|
osd.vm.hostname = "osd#{i}"
osd.vm.network :private_network, ip: "#{SUBNET}.10#{i}"
osd.vm.network :private_network, ip: "#{SUBNET}.20#{i}"
osd.vm.provider :virtualbox do |vb|
Expand Down
7 changes: 7 additions & 0 deletions roles/common/tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,13 @@
#


- name: "set hostname"
hostname:
name: "{{ inventory_hostname }}"

- name: "set git config http"
command: git config --global url."https://".insteadOf git://

- name: Copying Ceph key
template: src=roles/common/templates/ceph-key dest=/tmp/ceph-key owner=root group=root mode=0644
ignore_errors: True
Expand Down