Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
reposync
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
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
linuxsupport
cronjobs
reposync
Merge requests
!216
New build method
Code
Review changes
Check out branch
Download
Patches
Plain diff
Merged
New build method
simplify
into
master
Overview
0
Commits
1
Pipelines
4
Changes
2
Merged
Alex Iribarren
requested to merge
simplify
into
master
2 years ago
Overview
0
Commits
1
Pipelines
4
Changes
2
Expand
0
0
Merge request reports
Compare
master
version 3
4132a60c
2 years ago
version 2
f3adc570
2 years ago
version 1
541b2a9f
2 years ago
master (base)
and
latest version
latest version
ea45e27e
1 commit,
2 years ago
version 3
4132a60c
3 commits,
2 years ago
version 2
f3adc570
2 commits,
2 years ago
version 1
541b2a9f
1 commit,
2 years ago
2 files
+
13
−
8
Inline
Compare changes
Side-by-side
Inline
Show whitespace changes
Show one file at a time
Files
2
Search (e.g. *.vue) (Ctrl+P)
.gitlab-ci.yml
+
12
−
6
Options
@@ -23,18 +23,24 @@ generate_jobs:
expire_in
:
1 day
build_reposync
:
stage
:
build
tags
:
-
docker-image-build
script
:
"
echo"
# unused but this line is required by GitLab CI
extends
:
.build_image
variables
:
CONTEXT_DIR
:
reposync
TO
:
$CI_REGISTRY_IMAGE/reposync:$CI_COMMIT_REF_NAME
DOCKER_FILE
:
reposync/Dockerfile
TO
:
$CI_REGISTRY_IMAGE/reposync
PARENT_PIPELINE_ID
:
${CI_PIPELINE_ID}
ARTIFACT_JOB
:
prepare_dirs
stop_deleted
:
extends
:
.nomad
stage
:
cleanup
script
:
-
set +e
-
nomad job status | grep running | cut -d' ' -f1 | grep "^${PREFIX}_reposync_[^\/]\+$" | sort > oldjobs
-
set -e
-
ls *.nomad | sed 's/\.nomad//' | sort > newjobs
-
for JOB in `diff --new-line-format="" --unchanged-line-format="" oldjobs newjobs`; do echo -e "\nDeleting job ${JOB}:"; nomad job stop -verbose ${JOB} ||
true
; done
-
|
for JOB in $(diff --new-line-format="" --unchanged-line-format="" oldjobs newjobs); do
echo -e "\nDeleting job ${JOB}:"
nomad job stop -verbose ${JOB} || true
done
Loading