summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIury Gregory Melo Ferreira <iurygregory@gmail.com>2018-10-16 15:09:58 +0200
committerJim Rollenhagen <jim@jimrollenhagen.com>2018-10-16 10:49:19 -0400
commit7a551c4f4ad3852c1a37ec29235b131d20b6612b (patch)
tree9f56789c19e91b79fbf71480baaa7ce79f8e37c7
parent596c03e9ebde267114b54186efd51b53b817a04e (diff)
Remove VagrantHEADmaster
The files for Vagrants are too outdated, this patch removes the information about Vagrant in the documentation and the old files used to set up a Vagrant environment. Change-Id: Ieee7b76172874e67bb31055c0c40beb41785f7bb
Notes
Notes (review): Code-Review+2: Jim Rollenhagen <jim@jimrollenhagen.com> Code-Review+1: Kaifeng Wang <kaifeng.w@gmail.com> Code-Review+1: Madhuri Kumari <madhuri.kumari@intel.com> Code-Review+2: Dmitry Tantsur <divius.inside@gmail.com> Workflow+1: Dmitry Tantsur <divius.inside@gmail.com> Verified+2: Zuul Submitted-by: Zuul Submitted-at: Wed, 17 Oct 2018 14:22:39 +0000 Reviewed-on: https://review.openstack.org/610964 Project: openstack/ironic Branch: refs/heads/master
-rw-r--r--Vagrantfile31
-rw-r--r--doc/source/contributor/dev-quickstart.rst24
-rw-r--r--releasenotes/notes/remove_vagrant-4472cedd0284557c.yaml6
-rw-r--r--vagrant.yaml159
4 files changed, 8 insertions, 212 deletions
diff --git a/Vagrantfile b/Vagrantfile
deleted file mode 100644
index f15adc5..0000000
--- a/Vagrantfile
+++ /dev/null
@@ -1,31 +0,0 @@
1# -*- mode: ruby -*-
2# vi: set ft=ruby :
3
4# WARNING: This Vagrantfile is for development purposes only. It is intended to
5# bootstrap required services - such as mysql and rabbit - into a reliably
6# accessible VM, rather than forcing the engineer to install and manage these
7# services manually. This Vagrantfile is not intended to assist in provisioning
8# Ironic. For that, please use the bifrost project.
9
10VAGRANTFILE_API_VERSION = '2'
11
12Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
13
14 config.vm.box = 'ubuntu/trusty64'
15
16 config.vm.define 'ironic' do |ironic|
17 ironic.vm.provider :virtualbox do |vb|
18 vb.customize ['modifyvm', :id, '--memory', '512', '--cpuexecutioncap', '25']
19 end
20
21 ironic.vm.network 'private_network', ip: '192.168.99.11' # It goes to 11.
22
23 ironic.vm.provision 'ansible' do |ansible|
24 ansible.verbose = 'v'
25 ansible.playbook = 'vagrant.yaml'
26 ansible.extra_vars = {
27 ip: '192.168.99.11'
28 }
29 end
30 end
31end
diff --git a/doc/source/contributor/dev-quickstart.rst b/doc/source/contributor/dev-quickstart.rst
index 87d0c31..62447a0 100644
--- a/doc/source/contributor/dev-quickstart.rst
+++ b/doc/source/contributor/dev-quickstart.rst
@@ -207,29 +207,9 @@ Step 1: Create a Python virtualenv
207 export OS_TOKEN=fake-token 207 export OS_TOKEN=fake-token
208 export OS_URL=http://localhost:6385/ 208 export OS_URL=http://localhost:6385/
209 209
210Next, install and configure system dependencies. Two different approaches are 210Next, install and configure system dependencies.
211described below; you should only do one of these.
212 211
213Step 2a: System Dependencies In A Virtual Machine 212Step 2: Install System Dependencies Locally
214-------------------------------------------------
215
216This option requires `virtualbox <https://www.virtualbox.org>`_,
217`vagrant <https://www.vagrantup.com>`_, and
218`ansible <https://www.ansible.com>`_. You may install these using your
219favorite package manager, or by downloading from the provided links.
220
221#. Let vagrant do the work::
222
223 vagrant up
224
225This will create a VM available to your local system at `192.168.99.11`,
226will install all the necessary service dependencies,
227and configure some default users. It will also generate
228`./etc/ironic/ironic.conf.local` preconfigured for local dev work.
229We recommend you compare and familiarize yourself with the settings in
230`./etc/ironic/ironic.conf.sample` so you can adjust it to meet your own needs.
231
232Step 2b: Install System Dependencies Locally
233-------------------------------------------- 213--------------------------------------------
234 214
235This option will install RabbitMQ and MySQL on your local system. This may not 215This option will install RabbitMQ and MySQL on your local system. This may not
diff --git a/releasenotes/notes/remove_vagrant-4472cedd0284557c.yaml b/releasenotes/notes/remove_vagrant-4472cedd0284557c.yaml
new file mode 100644
index 0000000..d2b88a6
--- /dev/null
+++ b/releasenotes/notes/remove_vagrant-4472cedd0284557c.yaml
@@ -0,0 +1,6 @@
1---
2other:
3 - |
4 Removes Vagrant files and the information in documentation since
5 the files were too outdated. This would lead to errors if developers
6 tried to set up an environment with Vagrant.
diff --git a/vagrant.yaml b/vagrant.yaml
deleted file mode 100644
index 2426c71..0000000
--- a/vagrant.yaml
+++ /dev/null
@@ -1,159 +0,0 @@
1---
2###############################################################################
3# This ansible playbook installs all supporting software necessary to run the
4# ironic service locally into the vagrant VM attached. Its intent is to provide
5# a quickstart development environment that doesn't pollute an engineer's own
6# machine.
7#
8# The vagrant vm's IP address is assumed to be 192.168.99.11
9#
10# https://docs.openstack.org/ironic/latest/contributor/dev-quickstart.html#exercising-the-services-locally
11#
12- hosts: ironic
13 sudo: yes
14 tasks:
15 ############################################################################
16 # APT Updates
17 ############################################################################
18 # Make sure our VM's software is ~@Latest
19 - name: Apt Update
20 apt: update_cache=yes
21 upgrade=dist
22 cache_valid_time=86400
23
24 # Reboot if required.
25 - name: Reboot system if required
26 command: shutdown -r now 'Rebooting to complete system upgrade'
27 removes=/var/run/reboot-required
28 register: rebooted
29 - name: Wait for VM Reboot.
30 sudo: no
31 local_action: wait_for
32 port=22
33 host="{{ip}}"
34 search_regex=OpenSSH
35 delay=10
36 timeout=900
37 when: rebooted.changed
38
39 ############################################################################
40 # Install all the needed packages in one go.
41 ############################################################################
42 - name: Install Required Packages
43 apt: name={{item}}
44 state=present
45 with_items:
46 - rabbitmq-server
47 - python-mysqldb
48 - mysql-server
49 - mysql-client
50
51 ############################################################################
52 # Configure rabbitmq.
53 ############################################################################
54 - name: Ensure rabbitmq is running
55 service: name=rabbitmq-server
56 state=started
57 enabled=yes
58 - name: Add ironic RabbitMQ user
59 rabbitmq_user: user=ironic
60 password=ironic
61 vhost=/
62 configure_priv=.*
63 read_priv=.*
64 write_priv=.*
65 state=present
66
67 ############################################################################
68 # Configure mysql.
69 ############################################################################
70 - name: Configure MySQL
71 lineinfile: dest=/etc/mysql/my.cnf
72 line="bind-address={{ip}}"
73 regexp="^bind\-address"
74 notify: Restart MySQL
75 - name: Create MySQL Database
76 mysql_db: name=ironic state=present
77 - name: Create ironic MySQL user
78 mysql_user: name=ironic
79 password=ironic
80 host={{item}}
81 priv=ironic.*:ALL
82 state=present
83 with_items:
84 - localhost
85 - "%"
86 - name: Ensure mysql is running
87 service: name=mysql
88 state=started
89 enabled=yes
90
91 ############################################################################
92 # Create ironic.conf.local configuration.
93 ############################################################################
94 - name: Update local configuration with vagrant parameters.
95 sudo: no
96 local_action: ini_file dest=etc/ironic/ironic.conf.local
97 section="{{item.section}}"
98 option="{{item.option}}"
99 value="{{item.value}}"
100 with_items:
101 - {
102 section: 'glance',
103 option: 'auth_strategy', value: 'noauth'
104 }
105 - {
106 section: 'neutron',
107 option: 'auth_strategy', value: 'noauth'
108 }
109 - {
110 section: 'database',
111 option: 'connection', value: "mysql+pymysql://ironic:ironic@{{ip}}/ironic"
112 }
113 - {
114 section: 'DEFAULT',
115 option: 'auth_strategy', value: 'noauth'
116 }
117 - {
118 section: 'DEFAULT',
119 option: 'enabled_drivers', value: 'pxe_ipmitool, agent_ipmitool, fake'
120 # All other testing drivers require add'l packages
121 # and should be enabled locally, if desired
122 }
123 - {
124 section: 'DEFAULT',
125 option: 'pecan_debug', value: 'true'
126 }
127 - {
128 section: 'DEFAULT',
129 option: 'verbose', value: 'true'
130 }
131 - {
132 section: 'DEFAULT',
133 option: 'debug', value: 'true'
134 }
135 - {
136 section: 'oslo_messaging_rabbit',
137 option: 'rabbit_host', value: "{{ip}}"
138 }
139 - {
140 section: 'oslo_messaging_rabbit',
141 option: 'rabbit_userid', value: "ironic"
142 }
143 - {
144 section: 'oslo_messaging_rabbit',
145 option: 'rabbit_password', value: "ironic"
146 }
147 - { # CORS Domain For Ironic-Webclient's dev server.
148 section: 'cors',
149 option: 'allowed_origin', value: "http://localhost:8000"
150 }
151
152 #############################################################################
153 # Handlers
154 #############################################################################
155 handlers:
156 - name: Restart MySQL
157 service: name=mysql
158 state=restarted
159 enabled=yes