Commit e789016a authored by iv's avatar iv

wip

parent 345b7374
......@@ -108,6 +108,8 @@ startup = ${:etc}/run
service = ${:etc}/service
promise = ${:etc}/promise
promise.slow = ${:promise}.slow
# gitlab backup location
backup = ${:var}/backup
# gitlab: etc/ log/ ...
[gitlab-dir]
......@@ -842,9 +844,12 @@ time = daily
command = ${logrotate:wrapper}
[cron-entry-git-backup]
# XXX(IV): add time command to have feedbacks on how much time it takes?
<= cron-entry
time = weekly
command = ${directory:bin}/git-backup --help # XXX(IV): run a simple command for now
time = hourly
command = cd ${directory:backup};
${directory:bin}/xnice ${directory:bin}/gitlab-backup pull >
${directory:log}/gitlab-backup.log
# 6. on-reinstantiate actions
......
......@@ -49,7 +49,7 @@ parts =
gzip
dcron-output
logrotate
git-backup
xnice-gitlab-backup-git-backup
############################
......@@ -142,6 +142,13 @@ repository = https://lab.nexedi.com/kirr/git-backup.git
revision = 302aaaea2a1bfa9a5352b11c3fce813641015d19
location = ${buildout:parts-directory}/git-backup
[xnice-repository]
# to get kirr's misc repo containing xnice script
<= git-repository
repository = https://lab.nexedi.com/kirr/misc.git
revision = 4073572ea700bf1b115f3a135aebebe5b3b824e4
location = ${buildout:parts-directory}/misc
# build needed-by-gitlab gems via bundler
[gitlab/vendor/bundle]
recipe = slapos.recipe.cmmi
......@@ -182,13 +189,19 @@ make-targets= ${:_buildout_section_name_}
environment =
PATH=${golang15:location}/bin:%(PATH)s
[git-backup]
recipe = slapos.recipe.cmmi
path = ${git-backup-repository:location}
[xnice-gitlab-backup-git-backup]
# build and install git-backup,
# copy gitlab-backup, xnice scripts
recipe = slapos.recipe.cmmi
path = ${git-backup-repository:location}
configure-command = :
make-binary =
make-targets= cd ${:path} && ${golang15:location}/bin/go build -o
${buildout:bin-directory}/${:_buildout_section_name_} *.go
make-binary =
make-targets = cd ${git-backup-repository:location} &&
${golang15:location}/bin/go build -o
${buildout:bin-directory}/${:_buildout_section_name_} *.go ;
cp ${git-backup-repository:location}/contrib/gitlab-backup
${xnice-repository:location}/bin/xnice
${buildout:bin-directory}
###############################
# Trampoline for instance #
......@@ -264,7 +277,7 @@ md5sum = 8f1c52ed223ee2c2d07c6c79bcd2f6c0
[instance-gitlab.cfg.in]
<= download-file
md5sum = 767956feaa9cec43d2d9ea6b98da2e20
md5sum = 2b631d2aac727f06310d87d2af50ba1e
[macrolib.cfg.in]
<= download-file
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment