-
Notifications
You must be signed in to change notification settings - Fork 213
Remove pslot dir from local archive folder on CI case completion #2961
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 6 commits
1c159d8
e7aa3ba
463655a
b511367
40c96b2
54ce216
cacde8c
c8a10a9
7c93f4b
bb92a39
bfcbba5
69fc51b
49b4489
b776a59
d8af194
d54bd8d
85f6369
6a09b36
32b8cd0
e01d9d3
3d5e851
162474a
7da3721
c6ad4ec
bef32e7
02642fc
62ec3f6
7e5b4fb
bf3b80f
cd4e27b
5ea8d3d
99b9322
f56be33
9a381b4
788dd8f
7d3b8bf
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -155,3 +155,25 @@ function publish_logs() { | |
| fi | ||
| echo "${URL}" | ||
| } | ||
|
|
||
| function cleanup_experiment() { | ||
|
|
||
| # cleanup_experiment function | ||
| # This function takes a directory path of an EXPDIR and | ||
| # gets HOMEDIR value from config.base to | ||
| # clean up the archived files on disk. | ||
|
|
||
| local PSLOT_PATH | ||
| local pslot | ||
| local HOMEDIR | ||
| local ARCHIVEDIR | ||
|
|
||
| PSLOT_PATH="$1" | ||
|
|
||
| pslot=$(basename "${PSLOT_PATH}") | ||
| HOMEDIR=$(grep 'export HOMEDIR=' "${PSLOT_PATH}/config.base" | cut -d'=' -f2 | tr -d '[:space:]') | ||
|
|
||
| ARCHIVEDIR="${HOMEDIR}/archive" | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I think this should be reading in @WalterKolczynski-NOAA On the other hand
Collaborator
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Yeah, we should have lead with that.
Collaborator
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Ok updated using ARCDIR.
Collaborator
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Test failed because ARCDIR has an unresolved sub-string
Collaborator
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @WalterKolczynski-NOAA David Huber came up with idea of scraping the archive log files in COMROOT: I'll get that in tomorrow as another proposed solution.
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Instead of that, why not just feed the value of Or if we want to be more rigorous Or we could just cut to the chase and source
Collaborator
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. IMHO "reconstructing" paths from hidden knowledge of their specificity such as interim archive placements is a non-systematic and haphazard approach resulting in a one-off paradigm. If we really want to be rigorous I would propose a transformation from logs to a systematic and intent-full pedigree framework that could be leveraged for a requirement such as this. |
||
|
|
||
| rm -rf "${ARCHIVEDIR}/${pslot}" | ||
|
|
||
| rm -Rf "${PSLOT_PATH}" | ||
| rm -Rf "${PSLOT_PATH}/../COMROOT/${pslot}" | ||
| } | ||
|
|
||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.