Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
D
docker-neo4j-backup
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
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
europdx
LAS
docker-neo4j-backup
Commits
fba12767
Commit
fba12767
authored
6 years ago
by
Radim Peša
Browse files
Options
Downloads
Plain Diff
Merge branch '2780-master-patch-88711' into 'master'
Update backup.sh, Dockerfile files See merge request
!1
parents
a411df03
6cac8d35
No related branches found
No related tags found
1 merge request
!1
Update backup.sh, Dockerfile files
Pipeline
#10977
passed
6 years ago
Stage: build
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
Dockerfile
+2
-1
2 additions, 1 deletion
Dockerfile
backup.sh
+8
-1
8 additions, 1 deletion
backup.sh
with
10 additions
and
2 deletions
Dockerfile
+
2
−
1
View file @
fba12767
FROM
alpine
FROM
alpine
LABEL
maintainer="pesa@ics.muni.cz"
LABEL
maintainer="pesa@ics.muni.cz"
RUN
apk add
--no-cache
tzdata
#
RUN apk add --no-cache tzdata
ENV
TZ Europe/Prague
ENV
TZ Europe/Prague
COPY
backup.sh /backup.sh
COPY
backup.sh /backup.sh
RUN
chmod
+x /backup.sh
RUN
chmod
+x /backup.sh
ENTRYPOINT
["/backup.sh"]
ENTRYPOINT
["/backup.sh"]
CMD
["backup"]
This diff is collapsed.
Click to expand it.
backup.sh
+
8
−
1
View file @
fba12767
#!/bin/sh
#!/bin/sh
if
[
"
$1
"
=
"recover"
]
;
then
echo
"Starting Neo4j database recovery."
tar
-xvzf
/neo4j.tgz
-C
/neodata/
exit
0
fi
echo
"Starting backup in container."
echo
"Starting backup in container."
BACKUP_DIR
=
/backup/
$ENV_NOW
/
$ENV_NOWT
/neo4j
BACKUP_DIR
=
/backup/
$ENV_NOW
/
$ENV_NOWT
/neo4j
...
@@ -7,4 +14,4 @@ mkdir -p $BACKUP_DIR
...
@@ -7,4 +14,4 @@ mkdir -p $BACKUP_DIR
echo
"Backup dir is
$BACKUP_DIR
."
echo
"Backup dir is
$BACKUP_DIR
."
echo
"Creating tgz file."
echo
"Creating tgz file."
tar
-zcvf
$BACKUP_DIR
/neo4j.tgz /neodata/
*
#
tar -zcvf $BACKUP_DIR/neo4j.tgz /neodata/*
\ No newline at end of file
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