Skip to content
This repository has been archived by the owner on Sep 8, 2024. It is now read-only.

Commit

Permalink
Merge pull request #2944 from MycroftAI/bugfix/ci-unique-temp-paths
Browse files Browse the repository at this point in the history
Use unique paths for temp file storage
  • Loading branch information
krisgesling authored Aug 4, 2021
2 parents 7c413de + d14e6b6 commit c996008
Showing 1 changed file with 12 additions and 5 deletions.
17 changes: 12 additions & 5 deletions Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -107,13 +107,20 @@ pipeline {
sh 'rmdir $HOME/core/$BRANCH_ALIAS'
sh (
label: 'Publish Report to Web Server',
script: '''scp allure-report.zip [email protected]:~;
ssh [email protected] "unzip -o ~/allure-report.zip";
script: '''
ssh [email protected] "mkdir -p ~/allure-reports/core/${BRANCH_ALIAS}";
scp allure-report.zip [email protected]:~/allure-reports/core/${BRANCH_ALIAS};
ssh [email protected] "unzip -o ~/allure-reports/core/${BRANCH_ALIAS}/allure-report.zip -d ~/allure-reports/core/${BRANCH_ALIAS}/";
ssh [email protected] "rm -rf /var/www/voight-kampff/core/${BRANCH_ALIAS}";
ssh [email protected] "mv allure-report /var/www/voight-kampff/core/${BRANCH_ALIAS}"
scp mycroft-logs.zip [email protected]:~;
ssh [email protected] "mv ~/allure-reports/core/${BRANCH_ALIAS}/allure-report /var/www/voight-kampff/core/${BRANCH_ALIAS}"
ssh [email protected] "rm ~/allure-reports/core/${BRANCH_ALIAS}/allure-report.zip";
ssh [email protected] "rmdir ~/allure-reports/core/${BRANCH_ALIAS}";
ssh [email protected] "mkdir -p ~/mycroft-logs/core/${BRANCH_ALIAS}";
scp mycroft-logs.zip [email protected]:~/mycroft-logs/core/${BRANCH_ALIAS}/;
ssh [email protected] "mkdir -p /var/www/voight-kampff/core/${BRANCH_ALIAS}/logs"
ssh [email protected] "unzip -oj ~/mycroft-logs.zip -d /var/www/voight-kampff/core/${BRANCH_ALIAS}/logs/";
ssh [email protected] "unzip -oj ~/mycroft-logs/core/${BRANCH_ALIAS}/mycroft-logs.zip -d /var/www/voight-kampff/core/${BRANCH_ALIAS}/logs/";
ssh [email protected] "rm ~/mycroft-logs/core/${BRANCH_ALIAS}/mycroft-logs.zip";
ssh [email protected] "rmdir ~/mycroft-logs/core/${BRANCH_ALIAS}";
'''
)
echo 'Report Published'
Expand Down

0 comments on commit c996008

Please sign in to comment.