Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
A
autoicon
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
w2w
autoicon
Commits
76d1efd9
Commit
76d1efd9
authored
1 year ago
by
Oriol Tintó
Browse files
Options
Downloads
Patches
Plain Diff
Fix prepare_date_local.sh and prepare_date_remote.sh
parent
b50f532e
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Pipeline
#18779
passed
1 year ago
Stage: everything
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
templates/real-from-dwd-ana/prepare_date_local.sh
+11
-35
11 additions, 35 deletions
templates/real-from-dwd-ana/prepare_date_local.sh
templates/real-from-dwd-ana/prepare_date_remote.sh
+16
-33
16 additions, 33 deletions
templates/real-from-dwd-ana/prepare_date_remote.sh
with
27 additions
and
68 deletions
templates/real-from-dwd-ana/prepare_date_local.sh
+
11
−
35
View file @
76d1efd9
...
...
@@ -33,42 +33,18 @@ if [ "${IS_LOCAL}" == "True" ]; then
exit
1
fi
# Create member folder and go there
mkdir
-p
${
COMMON_DATE_FOLDER
}
cd
${
COMMON_DATE_FOLDER
}
||
exit
# Check if we copy the initial conditions from the local system or the remote one
if
[
"
${
IS_LOCAL
}
"
!=
"True"
]
;
then
# Create member folder
ssh
"
${
HPCUSER
}
@
${
HPCHOST
}
"
mkdir
-p
${
COMMON_DATE_FOLDER
}
# Save filenames to be used later by other scripts.
echo
"
${
AN_FILE
}
"
>
an_file.txt
echo
"
${
FG_FILE
}
"
>
fg_file.txt
# Save filenames to be used later by other scripts.
echo
"
${
AN_FILE
}
"
>
an_file.txt
echo
"
${
FG_FILE
}
"
>
fg_file.txt
rsync
-v
an_file.txt
"
${
HPCUSER
}
@
${
HPCHOST
}
"
:
"
${
COMMON_DATE_FOLDER
}
/an_file.txt"
rsync
-v
fg_file.txt
"
${
HPCUSER
}
@
${
HPCHOST
}
"
:
"
${
COMMON_DATE_FOLDER
}
/fg_file.txt"
# Copy the first-guess and analysis files.
cp
"
${
FG_SOURCE
}
"
"
${
FG_FILE
}
"
cp
"
${
AN_SOURCE
}
"
"
${
AN_FILE
}
"
# Remove temporary files.
rm
an_file.txt
rm
fg_file.txt
# Copy the first-guess and analysis files.
rsync
-v
"
${
FG_SOURCE
}
"
"
${
HPCUSER
}
@
${
HPCHOST
}
"
:
"
${
COMMON_DATE_FOLDER
}
/
${
FG_FILE
}
"
rsync
-v
"
${
AN_SOURCE
}
"
"
${
HPCUSER
}
@
${
HPCHOST
}
"
:
"
${
COMMON_DATE_FOLDER
}
/
${
AN_FILE
}
"
# Change permissions to read only.
ssh
"
${
HPCUSER
}
@
${
HPCHOST
}
"
chmod
440
"
${
COMMON_DATE_FOLDER
}
/*"
else
# Create member folder and go there
mkdir
-p
${
COMMON_DATE_FOLDER
}
cd
${
COMMON_DATE_FOLDER
}
||
exit
# Save filenames to be used later by other scripts.
echo
"
${
AN_FILE
}
"
>
an_file.txt
echo
"
${
FG_FILE
}
"
>
fg_file.txt
# Copy the first-guess and analysis files.
cp
"
${
FG_SOURCE
}
"
"
${
FG_FILE
}
"
cp
"
${
AN_SOURCE
}
"
"
${
AN_FILE
}
"
# Change permissions to read only.
chmod
440 ./
*
fi
# Change permissions to read only.
chmod
440 ./
*
fi
\ No newline at end of file
This diff is collapsed.
Click to expand it.
templates/real-from-dwd-ana/prepare_date_remote.sh
+
16
−
33
View file @
76d1efd9
...
...
@@ -2,7 +2,7 @@
IS_LOCAL
=
%SIMULATION.INITIAL_CONDITIONS.LOCAL%
if
[
"
${
IS_LOCAL
}
"
==
"
0
"
]
;
then
if
[
"
${
IS_LOCAL
}
"
==
"
False
"
]
;
then
# Get some variables provided by autosubmit.
WORKDIR
=
%HPCROOTDIR%
STARTDATE
=
%SDATE%
...
...
@@ -32,42 +32,25 @@ if [ "${IS_LOCAL}" == "0" ]; then
exit
1
fi
# Check if we copy the initial conditions from the local system or the remote one
if
[
"
${
IS_LOCAL
}
"
==
"True"
]
;
then
# Create member folder
ssh
"
${
HPCUSER
}
@
${
HPCHOST
}
"
mkdir
-p
${
COMMON_DATE_FOLDER
}
# Save filenames to be used later by other scripts.
echo
"
${
AN_FILE
}
"
>
an_file.txt
echo
"
${
FG_FILE
}
"
>
fg_file.txt
rsync
-v
an_file.txt
"
${
HPCUSER
}
@
${
HPCHOST
}
"
:
"
${
COMMON_DATE_FOLDER
}
/an_file.txt"
rsync
-v
fg_file.txt
"
${
HPCUSER
}
@
${
HPCHOST
}
"
:
"
${
COMMON_DATE_FOLDER
}
/fg_file.txt"
# Create member folder
ssh
"
${
HPCUSER
}
@
${
HPCHOST
}
"
mkdir
-p
${
COMMON_DATE_FOLDER
}
# Remove temporary files.
rm
an_file.txt
rm
fg_file.txt
# Save filenames to be used later by other scripts.
echo
"
${
AN_FILE
}
"
>
an_file.txt
echo
"
${
FG_FILE
}
"
>
fg_file.txt
rsync
-v
an_file.txt
"
${
HPCUSER
}
@
${
HPCHOST
}
"
:
"
${
COMMON_DATE_FOLDER
}
/an_file.txt"
rsync
-v
fg_file.txt
"
${
HPCUSER
}
@
${
HPCHOST
}
"
:
"
${
COMMON_DATE_FOLDER
}
/fg_file.txt"
#
Copy the first-guess and analysis
files.
r
sync
-v
"
${
FG_SOURCE
}
"
"
${
HPCUSER
}
@
${
HPCHOST
}
"
:
"
${
COMMON_DATE_FOLDER
}
/
${
FG_FILE
}
"
r
sync
-v
"
${
AN_SOURCE
}
"
"
${
HPCUSER
}
@
${
HPCHOST
}
"
:
"
${
COMMON_DATE_FOLDER
}
/
${
AN_FILE
}
"
#
Remove temporary
files.
r
m
an_file.txt
r
m
fg_file.txt
# Change permissions to read only.
ssh
"
${
HPCUSER
}
@
${
HPCHOST
}
"
chmod
440
"
${
COMMON_DATE_FOLDER
}
/*"
else
# Create member folder and go there
mkdir
-p
${
COMMON_DATE_FOLDER
}
cd
${
COMMON_DATE_FOLDER
}
||
exit
# Copy the first-guess and analysis files.
rsync
-v
"
${
FG_SOURCE
}
"
"
${
HPCUSER
}
@
${
HPCHOST
}
"
:
"
${
COMMON_DATE_FOLDER
}
/
${
FG_FILE
}
"
rsync
-v
"
${
AN_SOURCE
}
"
"
${
HPCUSER
}
@
${
HPCHOST
}
"
:
"
${
COMMON_DATE_FOLDER
}
/
${
AN_FILE
}
"
# Save filenames to be used later by other scripts.
echo
"
${
AN_FILE
}
"
>
an_file.txt
echo
"
${
FG_FILE
}
"
>
fg_file.txt
# Change permissions to read only.
ssh
"
${
HPCUSER
}
@
${
HPCHOST
}
"
chmod
440
"
${
COMMON_DATE_FOLDER
}
/*"
# Copy the first-guess and analysis files.
cp
"
${
FG_SOURCE
}
"
"
${
FG_FILE
}
"
cp
"
${
AN_SOURCE
}
"
"
${
AN_FILE
}
"
# Change permissions to read only.
chmod
440 ./
*
fi
fi
\ No newline at end of file
This diff is collapsed.
Click to expand it.
Oriol.Tinto
@Oriol.Tinto
mentioned in commit
a9da0e06
·
1 year ago
mentioned in commit
a9da0e06
mentioned in commit a9da0e069b97227fcc45e81c828cfdfd5f3b0af3
Toggle commit list
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment