@@ -25,15 +25,25 @@ First of all, you need to install the latest versions of
25
25
now) and [ VirtualBox] ( https://www.virtualbox.org/wiki/Downloads ) (currently at
26
26
version 5.2.4) on your host machine.
27
27
28
- If you use a version of VirtualBox that isn't 5.1.6 or newer you may run into
29
- problems creating the NFS mount. You can either upgrade VirtualBox, or you can
30
- try to install the [ vagrant-vbguest] ( https://github.com/dotless-de/vagrant-vbguest )
31
- plugin, which will attempt to install your local version of GuestAdditions into
32
- the VM.
28
+ If you use Linux, you'll need to ensure proper support for NFS installed so the
29
+ Vagrant shared folders feature works. On Debian/ubuntu systems this can be
30
+ achieved with:
33
31
34
- ```
35
- vagrant plugin install vagrant-vbguest
36
- ```
32
+ $ sudo apt-get install nfs-kernel-server
33
+
34
+ On Fedora/CentOS systems you'll need to execute something like:
35
+
36
+ $ sudo dnf install nfs-utils && sudo systemctl enable nfs-server
37
+
38
+ If you use a version of VirtualBox that isn't 5.1.6 you may run into problems
39
+ creating the NFS mount. You can either
40
+
41
+ * Upgrade to VirtualBox 5.2.4
42
+ * Or you can try to install the [ vagrant-vbguest] ( https://github.com/dotless-de/vagrant-vbguest )
43
+ plugin, which will attempt to install your local version of GuestAdditions
44
+ into the VM:
45
+
46
+ vagrant plugin install vagrant-vbguest
37
47
38
48
Booting the VM
39
49
--------------
@@ -157,6 +167,39 @@ like so:
157
167
158
168
The test suite will sometimes hang when running selenium tests in parallel mode.
159
169
170
+ Troubleshooting
171
+ ---------------
172
+
173
+ ### Strange errors when running tests
174
+
175
+ The ` tox.ini ` configuration file shipped with the Django source code directs
176
+ tox to create the virtual environments it uses for every test matrix
177
+ configuration below a ` .tox ` directory it creates on the Django source code top
178
+ directory.
179
+
180
+ django-box reuses Django's tox configuration, but executes tox inside the VM,
181
+ so that ` .tox/ ` tree gets persisted between test runs and shared between a tox
182
+ copy you could use on the host and the django-box tox.
183
+
184
+ So it might happen than when faced with a mismatch between the version of Python
185
+ used to create a virtual environment and the version currently in use to run
186
+ the tests (e.g. Python micro version gets upgraded from 3.6.3 to 3.6.4 and this
187
+ upgrade reaches your Linux host and/or the repositories used by the django-box
188
+ VM), weird errors happen.
189
+
190
+ You can solve this by removing the virtualenv tree, e.g.:
191
+
192
+ (host) $ rm -rf <Django souce code top dir>/.tox/py36-mysql
193
+ (vm) $ rm -rf /django/.tox/py36-mysql
194
+
195
+ or more drastically, removing the ` .tox ` directory:
196
+
197
+ (host) $ rm -rf <Django souce code top dir>/.tox
198
+ (vm) $ rm -rf /django/.tox
199
+
200
+ This way the next time you run the tests, tox will rebuild the virtual
201
+ environment anew with the correct version of Python.
202
+
160
203
Building the documentation
161
204
--------------------------
162
205
0 commit comments