aboutsummaryrefslogtreecommitdiffstats
path: root/func/fetchimg.py
diff options
context:
space:
mode:
Diffstat (limited to 'func/fetchimg.py')
-rw-r--r--func/fetchimg.py30
1 files changed, 30 insertions, 0 deletions
diff --git a/func/fetchimg.py b/func/fetchimg.py
new file mode 100644
index 00000000..106dc7e8
--- /dev/null
+++ b/func/fetchimg.py
@@ -0,0 +1,30 @@
+##############################################################################
+# Copyright (c) 2015 Dell Inc and others.
+#
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Apache License, Version 2.0
+# which accompanies this distribution, and is available at
+# http://www.apache.org/licenses/LICENSE-2.0
+##############################################################################
+
+
+
+import os
+import time
+
+
+class FetchImg:
+
+ def __init__(self):
+ print 'Fetching Image!'
+ print 'Fetching QTIP_VM Image'
+
+ def download(self):
+ time.sleep(2)
+ os.system(
+ 'cd ./Temp_Img && wget http://artifacts.opnfv.org/qtip/QTIP_CentOS.qcow2')
+
+ filepath = './Temp_Img/QTIP_CentOS.qcow2'
+ while not os.path.isfile(filepath):
+ time.sleep(10)
+ print 'Download Completed!'