Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
P
psot.repository
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
SOaAS
psot.repository
Commits
7a246f03
Commit
7a246f03
authored
6 years ago
by
Marc
Browse files
Options
Downloads
Patches
Plain Diff
add script 'download_databases_from_s3bucket'
parent
3fd9f365
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
psot/helpers/download_databases_from_s3bucket.sh
+44
-0
44 additions, 0 deletions
psot/helpers/download_databases_from_s3bucket.sh
with
44 additions
and
0 deletions
psot/helpers/download_databases_from_s3bucket.sh
0 → 100755
+
44
−
0
View file @
7a246f03
#! /bin/bash
LOGFILE
=
$1
DATADIR
=
$2
#s3 bucket from which the databases are downloaded
S3BUCKET
=
'psot-databases'
# list of database folders, downloaded as tar-archives
list
=
'ghostx uniprot pfam-31'
function
test_datadir
()
{
if
!
[[
-e
$DATADIR
&&
-d
$DATADIR
]]
;
then
mkdir
$DATADIR
sync_data
elif
[
-z
"
$(
ls
-A
$DATADIR
)
"
]
;
then
sync_data
fi
}
function
sync_data
()
{
echo
"Could not find databases in config given path"
echo
"Download databases... "
cd
$DATADIR
for
ele
in
$list
;
do
wget
-q
"https://
${
S3BUCKET
}
.s3.computational.bio.uni-giessen.de/
${
ele
}
.tar.gz"
tar
-zxf
"
${
ele
}
.tar.gz"
rm
"
${
ele
}
.tar.gz"
done
ln
-s
'pfam-31/'
'pfam'
echo
"[
$(
date
)
] psot (PID
$$
) downloaded databases to
$DATADIR
"
>>
$LOGFILE
}
if
[[
-e
$LOGFILE
]]
;
then
test_datadir
else
echo
"[
$(
date
)
] logfile created from psot (PID
$$
)"
>
$LOGFILE
test_datadir
fi
This diff is collapsed.
Click to expand it.
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