Compare commits

...

4 Commits
devel ... main

Author SHA1 Message Date
Dirk Müller
44b4d690db
Only stop importing when it isn't a jengelh repository 2024-12-02 09:34:49 +01:00
Dirk Müller
a69e861614
Switch the operating organization on the "pool" 2024-12-02 09:33:52 +01:00
Dirk Müller
1da740bd8b
Strip multibuild flavors from monitoring 2024-09-09 09:34:12 +02:00
Dirk Mueller
b3107ba3bf Merge pull request 'Stop importing/exporting scmsync packages/projects' (#32) from adamm/git-importer:option_for_non_factory into main
Reviewed-on: importers/git-importer#32
Reviewed-by: Dirk Mueller <dirkmueller@noreply@src.opensuse.org>
2024-09-03 12:40:00 +02:00
3 changed files with 10 additions and 5 deletions

View File

@ -251,7 +251,7 @@ class Git:
def add_gitea_remote(self, package):
repo_name = package.replace("+", "_")
org_name = "rpm"
org_name = "pool"
if not os.getenv("GITEA_TOKEN"):
logging.warning("Not adding a remote due to missing $GITEA_TOKEN")

View File

@ -268,9 +268,12 @@ class Importer:
return self.scmsync_cache[key]
root = self.obs._meta(key)
scmsync = None
scmsync_exists = False
if root is not None:
scmsync_exists = root.find('scmsync') is not None
if root and root.find('scmsync') is not None:
scmsync = root.find('scmsync').text
if scmsync:
scmsync_exists = scmsync.startswith('https://src.opensuse.org/pool/')
self.scmsync_cache[key] = scmsync_exists
return scmsync_exists

View File

@ -36,10 +36,12 @@ def listen_events():
and "package" in body
and body["project"] == "openSUSE:Factory"
):
if "/" in body["package"]:
# Strip multibuild flavors
package = body["package"].partition(':')[0]
if "/" in package:
return
(MY_TASKS_DIR / body["package"]).touch()
(MY_TASKS_DIR / package).touch()
print(" [x] %r:%r" % (method.routing_key, body["package"]))
channel.basic_consume(queue_name, callback, auto_ack=True)