Merge remote-tracking branch 'origin/master'

This commit is contained in:
grossmj committed 2015-04-08 11:17:49 -06:00
commit 7e8b0a48ab
107 files changed
+728 -227

No files matched your search

+1 -1
View File
@@ -40,7 +40,7 @@ class CrashReport:
Report crash to a third party service
"""
DSN = "sync+https://2f1f465755f3482993eec637cae95f4c:f71b4e8ecec54ea48666c09d68790558@app.getsentry.com/38482"
DSN = "sync+https://90fe04368a3e4109b584a116ee03ca87:268ef86c65cf4e8fa41d4c7fb1c70b72@app.getsentry.com/38482"
if hasattr(sys, "frozen"):
cacert = os.path.join(os.getcwd(), "cacert.pem")
if os.path.isfile(cacert):
+1 -1
View File
@@ -30,5 +30,5 @@ from gns3server.handlers.api.server_handler import ServerHandler
from gns3server.handlers.upload_handler import UploadHandler
from gns3server.handlers.index_handler import IndexHandler
if sys.platform.startswith("linux") or hasattr(sys, "_called_from_test"):
if sys.platform.startswith("linux") or hasattr(sys, "_called_from_test") or os.environ.get("PYTEST_BUILD_DOCUMENTATION") == "1":
from gns3server.handlers.api.iou_handler import IOUHandler
+2 -1
View File
@@ -16,6 +16,7 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>.
import sys
import os
from .vpcs import VPCS
from .virtualbox import VirtualBox
from .dynamips import Dynamips
@@ -23,7 +24,7 @@ from .qemu import Qemu
MODULES = [VPCS, VirtualBox, Dynamips, Qemu]
if sys.platform.startswith("linux") or hasattr(sys, "_called_from_test"):
if sys.platform.startswith("linux") or hasattr(sys, "_called_from_test") or os.environ.get("PYTEST_BUILD_DOCUMENTATION") == "1":
# IOU runs only on Linux
from .iou import IOU
MODULES.append(IOU)
+16 -1
View File
@@ -153,6 +153,16 @@ class IOUVM(BaseVM):
path = relative_path
self._path = path
# In 1.2 users uploaded images to the images roots
# after the migration their images are inside images/IOU
# but old topologies use old path
if "IOU" not in self._path:
location, filename = os.path.split(self._path)
fix_path = os.path.join(location, "IOU", filename)
if os.path.isfile(fix_path):
self._path = fix_path
if not os.path.isfile(self._path) or not os.path.exists(self._path):
if os.path.islink(self._path):
raise IOUError("IOU image '{}' linked to '{}' is not accessible".format(self._path, os.path.realpath(self._path)))
@@ -985,8 +995,13 @@ class IOUVM(BaseVM):
try:
script_file = os.path.join(self.working_dir, "initial-config.cfg")
# We disallow erasing the initial config file
if len(initial_config) == 0 and os.path.exists(script_file):
return
with open(script_file, 'w+') as f:
if initial_config is None:
if len(initial_config) == 0:
f.write('')
else:
initial_config = initial_config.replace("%h", self._name)
+1 -1
View File
@@ -23,5 +23,5 @@
# or negative for a release candidate or beta (after the base version
# number has been incremented)
__version__ = "1.3.1.dev1"
__version__ = "1.3.1.rc3"
__version_info__ = (1, 3, 0, 99)
+1
View File
@@ -37,6 +37,7 @@ class Documentation(object):
def write(self):
for handler_name in sorted(self._documentation):
print("Build {}".format(handler_name))
for path in sorted(self._documentation[handler_name]):