Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
O
OpenXG-RAN
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Michael Black
OpenXG-RAN
Commits
044f6657
Commit
044f6657
authored
Jan 29, 2021
by
hardy
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/ci-deploy-asterix' into integration_2021_wk04_b
parents
5db5657d
747695e4
Changes
3
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
151 additions
and
28 deletions
+151
-28
ci-scripts/cls_containerize.py
ci-scripts/cls_containerize.py
+101
-23
ci-scripts/html.py
ci-scripts/html.py
+48
-1
ci-scripts/sshconnection.py
ci-scripts/sshconnection.py
+2
-4
No files found.
ci-scripts/cls_containerize.py
View file @
044f6657
This diff is collapsed.
Click to expand it.
ci-scripts/html.py
View file @
044f6657
...
@@ -218,7 +218,7 @@ class HTMLManagement():
...
@@ -218,7 +218,7 @@ class HTMLManagement():
self
.
htmlFile
.
write
(
' <div id="build-tab" class="tab-pane fade">
\n
'
)
self
.
htmlFile
.
write
(
' <div id="build-tab" class="tab-pane fade">
\n
'
)
self
.
htmlFile
.
write
(
' <table class="table" border = "1">
\n
'
)
self
.
htmlFile
.
write
(
' <table class="table" border = "1">
\n
'
)
self
.
htmlFile
.
write
(
' <tr bgcolor = "#33CCFF" >
\n
'
)
self
.
htmlFile
.
write
(
' <tr bgcolor = "#33CCFF" >
\n
'
)
self
.
htmlFile
.
write
(
' <th>Relative Time (
m
s)</th>
\n
'
)
self
.
htmlFile
.
write
(
' <th>Relative Time (s)</th>
\n
'
)
self
.
htmlFile
.
write
(
' <th>Test Id</th>
\n
'
)
self
.
htmlFile
.
write
(
' <th>Test Id</th>
\n
'
)
self
.
htmlFile
.
write
(
' <th>Test Desc</th>
\n
'
)
self
.
htmlFile
.
write
(
' <th>Test Desc</th>
\n
'
)
self
.
htmlFile
.
write
(
' <th>Test Options</th>
\n
'
)
self
.
htmlFile
.
write
(
' <th>Test Options</th>
\n
'
)
...
@@ -399,6 +399,53 @@ class HTMLManagement():
...
@@ -399,6 +399,53 @@ class HTMLManagement():
self
.
htmlFile
.
write
(
' </tr>
\n
'
)
self
.
htmlFile
.
write
(
' </tr>
\n
'
)
self
.
htmlFile
.
close
()
self
.
htmlFile
.
close
()
def
CreateHtmlNextTabHeaderTestRow
(
self
,
collectInfo
,
allImagesSize
,
machine
=
'eNB'
):
if
(
self
.
htmlFooterCreated
or
(
not
self
.
htmlHeaderCreated
)):
return
self
.
htmlFile
=
open
(
'test_results.html'
,
'a'
)
if
bool
(
collectInfo
)
==
False
:
self
.
htmlFile
.
write
(
' <tr bgcolor = "red" >
\n
'
)
self
.
htmlFile
.
write
(
' <td colspan='
+
str
(
5
+
self
.
htmlUEConnected
)
+
'><b> ----IMAGES BUILDING FAILED - Unable to recover the image logs ---- </b></td>
\n
'
)
self
.
htmlFile
.
write
(
' </tr>
\n
'
)
else
:
for
image
in
collectInfo
:
files
=
collectInfo
[
image
]
# TabHeader for image logs on built shared and target images
self
.
htmlFile
.
write
(
' <tr bgcolor = "#F0F0F0" >
\n
'
)
self
.
htmlFile
.
write
(
' <td colspan='
+
str
(
5
+
self
.
htmlUEConnected
)
+
'><b> ---- '
+
image
+
' IMAGE STATUS ----> Size '
+
allImagesSize
[
image
]
+
' </b></td>
\n
'
)
self
.
htmlFile
.
write
(
' </tr>
\n
'
)
self
.
htmlFile
.
write
(
' <tr bgcolor = "#33CCFF" >
\n
'
)
self
.
htmlFile
.
write
(
' <th colspan="2">Element</th>
\n
'
)
self
.
htmlFile
.
write
(
' <th>Nb Errors</th>
\n
'
)
self
.
htmlFile
.
write
(
' <th>Nb Warnings</th>
\n
'
)
self
.
htmlFile
.
write
(
' <th colspan='
+
str
(
1
+
self
.
htmlUEConnected
)
+
'>Status</th>
\n
'
)
self
.
htmlFile
.
write
(
' </tr>
\n
'
)
for
fil
in
files
:
parameters
=
files
[
fil
]
# TestRow for image logs on built shared and target images
self
.
htmlFile
.
write
(
' <tr>
\n
'
)
self
.
htmlFile
.
write
(
' <td colspan="2" bgcolor = "lightcyan" >'
+
fil
+
' </td>
\n
'
)
if
(
parameters
[
'errors'
]
==
0
):
self
.
htmlFile
.
write
(
' <td bgcolor = "green" >'
+
str
(
parameters
[
'errors'
])
+
'</td>
\n
'
)
else
:
self
.
htmlFile
.
write
(
' <td bgcolor = "red" >'
+
str
(
parameters
[
'errors'
])
+
'</td>
\n
'
)
if
(
parameters
[
'warnings'
]
==
0
):
self
.
htmlFile
.
write
(
' <td bgcolor = "green" >'
+
str
(
parameters
[
'warnings'
])
+
'</td>
\n
'
)
elif
((
parameters
[
'warnings'
]
>
0
)
and
(
parameters
[
'warnings'
]
<=
20
)):
self
.
htmlFile
.
write
(
' <td bgcolor = "orange" >'
+
str
(
parameters
[
'warnings'
])
+
'</td>
\n
'
)
else
:
self
.
htmlFile
.
write
(
' <td bgcolor = "red" >'
+
str
(
parameters
[
'warnings'
])
+
'</td>
\n
'
)
if
(
parameters
[
'errors'
]
==
0
)
and
(
parameters
[
'warnings'
]
==
0
):
self
.
htmlFile
.
write
(
' <th colspan='
+
str
(
1
+
self
.
htmlUEConnected
)
+
' bgcolor = "green" ><font color="white">OK </font></th>
\n
'
)
elif
(
parameters
[
'errors'
]
==
0
)
and
((
parameters
[
'warnings'
]
>
0
)
and
(
parameters
[
'warnings'
]
<=
20
)):
self
.
htmlFile
.
write
(
' <th colspan='
+
str
(
1
+
self
.
htmlUEConnected
)
+
' bgcolor = "orange" ><font color="white">OK </font></th>
\n
'
)
else
:
self
.
htmlFile
.
write
(
' <th colspan='
+
str
(
1
+
self
.
htmlUEConnected
)
+
' bgcolor = "red" > NOT OK </th>
\n
'
)
self
.
htmlFile
.
write
(
' </tr>
\n
'
)
self
.
htmlFile
.
close
()
def
CreateHtmlTestRowQueue
(
self
,
options
,
status
,
ue_status
,
ue_queue
):
def
CreateHtmlTestRowQueue
(
self
,
options
,
status
,
ue_status
,
ue_queue
):
if
((
not
self
.
htmlFooterCreated
)
and
(
self
.
htmlHeaderCreated
)):
if
((
not
self
.
htmlFooterCreated
)
and
(
self
.
htmlHeaderCreated
)):
self
.
htmlFile
=
open
(
'test_results.html'
,
'a'
)
self
.
htmlFile
=
open
(
'test_results.html'
,
'a'
)
...
...
ci-scripts/sshconnection.py
View file @
044f6657
...
@@ -52,13 +52,11 @@ class SSHConnection():
...
@@ -52,13 +52,11 @@ class SSHConnection():
self
.
picocom_closure
=
True
self
.
picocom_closure
=
True
def
open
(
self
,
ipaddress
,
username
,
password
):
def
open
(
self
,
ipaddress
,
username
,
password
):
extraSshOptions
=
''
count
=
0
count
=
0
connect_status
=
False
connect_status
=
False
if
ipaddress
==
'192.168.18.197'
:
extraSshOptions
=
' -o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no'
while
count
<
4
:
while
count
<
4
:
self
.
ssh
=
pexpect
.
spawn
(
'ssh'
,
[
username
+
'@'
+
ipaddress
+
extraSshOptions
],
timeout
=
5
)
self
.
ssh
=
pexpect
.
spawn
(
'ssh -o PubkeyAuthentication=no {}@{}'
.
format
(
username
,
ipaddress
))
self
.
ssh
.
timeout
=
5
self
.
sshresponse
=
self
.
ssh
.
expect
([
'Are you sure you want to continue connecting (yes/no)?'
,
'password:'
,
'Last login'
,
pexpect
.
EOF
,
pexpect
.
TIMEOUT
])
self
.
sshresponse
=
self
.
ssh
.
expect
([
'Are you sure you want to continue connecting (yes/no)?'
,
'password:'
,
'Last login'
,
pexpect
.
EOF
,
pexpect
.
TIMEOUT
])
if
self
.
sshresponse
==
0
:
if
self
.
sshresponse
==
0
:
self
.
ssh
.
sendline
(
'yes'
)
self
.
ssh
.
sendline
(
'yes'
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment