Forum Discussion
kakabubu
2 years agoContributor
I've come up with a WSL2 solution.
WSL with Ubuntu and remmina app preconfigured to connect to the test environment
The script below is run from the pipeline to activate remmina session
REMINNA_FILE_PATH= 'PATH TO YOUR .remmina FILE HERE'
EXPECTED_ERROR='PDU_TYPE_DATA'
echo $(date)'Started *** *** *** *** *** *** *** ***'
cat /dev/null >nohup.out
nohup remmina $REMINNA_FILE_PATH & disown
if timeout 30 tail -n 100 -f ./nohup.out | grep --line-buffered -m 1 $EXPECTED_ERROR; then
echo $(date) $EXPECTED_ERROR 'catched' $RVALUE
cat /dev/null >nohup.out
exit 0
else
echo $(date) $EXPECTED_ERROR 'not catched' $RVALUE
cat /dev/null >nohup.out
exit 1
fi
The issue I didn't figure out:
The script continues running while the session is active so I just set a 1-minute timeout for this operation in the pipeline.
BTW It would be cool If someone could give advice, on how to continue running the pipeline after the specific error was caught in the script
Related Content
Recent Discussions
- 2 hours ago
- 10 hours ago
Working with Visual Test
Solved2 days ago