blob: 1c621a3bd554b01b21445e4f5e0099184bca779f (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
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(
'mkdir -p Temp_Img && wget http://artifacts.opnfv.org/qtip/QTIP_CentOS.qcow2 -P Temp_Img')
filepath = './Temp_Img/QTIP_CentOS.qcow2'
while not os.path.isfile(filepath):
time.sleep(10)
print 'Download Completed!'
|