Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
P
portal-backend
Manage
Activity
Members
Labels
Plan
Issues
0
Issue boards
Milestones
Wiki
Code
Merge requests
0
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
HBP Medical Informatics Platform
portal-backend
Commits
cfabbe0f
Commit
cfabbe0f
authored
8 years ago
by
Mirco Nasuti
Browse files
Options
Downloads
Patches
Plain Diff
captain_run script to run the latest captain build using a postgres image for the portal-db
parent
a584f983
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
captain_run.sh
+33
-0
33 additions, 0 deletions
captain_run.sh
with
33 additions
and
0 deletions
captain_run.sh
0 → 100644
+
33
−
0
View file @
cfabbe0f
#!/usr/bin/env bash
if
[
$(
docker ps |
grep
portal-db |
wc
-l
)
-gt
0
]
;
then
docker
kill
portal-db
fi
if
[
$(
docker ps
-a
|
grep
portal-db |
wc
-l
)
-gt
0
]
;
then
docker
rm
-f
portal-db
fi
if
[
$(
docker ps |
grep
portal-backend |
wc
-l
)
-gt
0
]
;
then
docker
kill
portal-backend
fi
if
[
$(
docker ps
-a
|
grep
portal-backend |
wc
-l
)
-gt
0
]
;
then
docker
rm
-f
portal-backend
fi
docker run
--name
portal-db
-p
5432:5432
-e
POSTGRES_USER
=
postgres
-d
postgres
echo
'Wating for DB to start...'
until
[
$(
docker
exec
portal-db psql
-U
postgres
-c
"
\q
"
2>&1 |
wc
-l
)
-eq
0
]
;
do
printf
'.'
sleep
1
done
docker run
--name
portal-backend
-p
8080:8080
\
-e
"AUTHENTICATION=0"
\
-d
hbpmip/portal-backend
echo
'Wating for backend to start...'
until
[
$(
docker logs portal-backend |
grep
"Started MIPApplication"
|
wc
-l
)
-eq
1
]
;
do
printf
'.'
sleep
1
done
This diff is collapsed.
Click to expand it.
Preview
0%
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