Good riddance to track-upstream and its cronjob

We've stopped relying on jeepyb's track-upstream feature, so stop
installing the entrypoint script and cease running its cronjob.

Depends-On: https://review.opendev.org/799123
Change-Id: I0d6edcc34f25e6bfe2bc41d328ac76618b59f62d
This commit is contained in:
Jeremy Stanley 2021-07-01 22:40:40 +00:00
parent 736b0ac233
commit c0adfca28e
3 changed files with 4 additions and 43 deletions

View File

@ -158,10 +158,7 @@ in projects.yaml.
Manage Projects
---------------
Some projects may have upstreams defined in Jeepyb; the
``track-upstream`` cron job will update these remotes so that their
commits are available in Gerrit. It will also ensure that project metadata
is set up as defined in projects.yaml.
This ensures that project metadata is set up as defined in projects.yaml.
RSS feeds
---------

View File

@ -220,16 +220,13 @@
- static/system-cla.html
- static/usg-cla.html
- name: Write jeepyb utility scripts
- name: Write manage-projects script
template:
src: "{{ item }}.j2"
dest: "/usr/local/bin/{{ item }}"
src: "manage-projects.j2"
dest: "/usr/local/bin/manage-projects"
owner: root
group: root
mode: 0755
loop:
- manage-projects
- track-upstream
- name: Write projects.ini
template:
@ -319,14 +316,6 @@
minute: 17
hour: 4
- name: Set up cron job to track upstream
cron:
name: track-upstream
job: '/usr/local/bin/track-upstream'
user: root
minute: 42
state: "{{ gerrit_track_upstream | bool | ternary('present', 'absent') }}"
# Gerrit rotates their own logs, but doesn't clean them out
# Delete logs older than a month
- name: Set up cron job to clean old gerrit logs

View File

@ -1,25 +0,0 @@
#!/bin/bash
# Copyright 2020 Red Hat, Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
# implied.
# See the License for the specific language governing permissions and
# limitations under the License.
exec docker run --rm --net=host -u root \
-v/opt/project-config:/opt/project-config \
-v/opt/project-config/gerrit/projects.yaml:/home/gerrit2/projects.yaml \
-v/opt/lib/jeepyb:/opt/lib/jeepyb \
-v/home/gerrit2/review_site/etc/ssh_project_rsa_key:/home/gerrit2/review_site/etc/ssh_project_rsa_key \
-v/home/gerrit2/projects.ini:/home/gerrit2/projects.ini \
-v/root/.ssh/known_hosts:/root/.ssh/known_hosts \
-v/var/log:/var/log \
{{ gerrit_container_image }} track-upstream -v -l /var/log/track_upstream.log