Skip to content

Commit

Permalink
Use GitLab for syncing upstream->downstream.
Browse files Browse the repository at this point in the history
This pull request allows using gitlab for
syncing upstream->downstream.

The rest of function remains. Like
git clonedownstream uses dist-git

Signed-off-by: Petr "Stone" Hracek <[email protected]>
  • Loading branch information
phracek committed Jan 26, 2023
1 parent 60cfbe3 commit 2963e06
Show file tree
Hide file tree
Showing 14 changed files with 1,632 additions and 9 deletions.
3 changes: 2 additions & 1 deletion Dockerfile.generator
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
FROM registry.fedoraproject.org/fedora:34
FROM quay.io/fedora/fedora:36
ENV CWT_DIR=/tmp/container-workflow-tool
RUN dnf install -y go-md2man \
make git python3-PyYAML \
python3-GitPython \
python3-requests-kerberos \
python3-pip \
python3-gitlab \
distgen

COPY ./ ${CWT_DIR}/
Expand Down
2 changes: 1 addition & 1 deletion Dockerfile.tests
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM registry.fedoraproject.org/fedora:34
FROM quay.io/fedora/fedora:36

RUN dnf install -y ansible

Expand Down
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.PHONY: test-in-container build-generator push-generator
.PHONY: test-in-container build-generator push-generator build

TEST_IMAGE=cwt-tests
GENERATOR_IMAGE=quay.io/rhscl/cwt-generator
Expand Down
5 changes: 5 additions & 0 deletions container_workflow_tool/cli_common.py
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,10 @@ def get_parser(self):
parsers['git'].add_argument('--rebuild-reason', help='Use a custom reason for rebuilding')
parsers['git'].add_argument('--commit-msg', help='Use a custom message instead of the default one')
parsers['git'].add_argument('--check-script', help='Script/command to be run when checking repositories')
parsers['git'].add_argument(
'--gitlab', action='store_true', default=False,
help='File a merge request to corresponding repository instead of directly to dist-git'
)
parsers['build'].add_argument(
'--repo-url', help='Set the url of a .repo file to be used when building the image'
)
Expand Down Expand Up @@ -106,6 +110,7 @@ def git_usage(self):
--commit-msg - Use a custom message instead of the default one
--rebuild-reason - Use a custom reason for rebuilding
--check-script - Script/command to be run when checking repositories
--gitlab - Use GitLab for filling merge requests instead of direct pushing to dist-git
"""
return action_help

Expand Down
Loading

0 comments on commit 2963e06

Please sign in to comment.