prompt: You will be provided with a partial code base and an issue statement explaining a problem to resolve.
  <issue>
  [Bug]: Maven sign and upload should be done inside a docker container
  ### Describe the bug
  
  We should be using a docker container to run jenkinsjob. 
  
  https://github.com/opensearch-project/opensearch-infra/blob/main/jenkins/jobs/OpenSearch_CI/release_ci/opensearch_maven_release/Jenkinsfile#L3-L5
  
  Also, should this file be a part of `opensearch-build`?
  
  ### To reproduce
  
  Docker container is not used - 
  
  https://github.com/opensearch-project/opensearch-infra/blob/main/jenkins/jobs/OpenSearch_CI/release_ci/opensearch_maven_release/Jenkinsfile#L3-L5
  
  ### Expected behavior
  
  _No response_
  
  ### Screenshots
  
  If applicable, add screenshots to help explain your problem.
  
  ### Host / Environment
  
  _No response_
  
  ### Additional context
  
  _No response_
  
  ### Relevant log output
  
  _No response_
  
  </issue>
  <code>
  [start of src/run_sign.py]
  1 #!/usr/bin/env python
  2 
  3 # SPDX-License-Identifier: Apache-2.0
  4 #
  5 # The OpenSearch Contributors require contributions made to
  6 # this file be licensed under the Apache-2.0 license or a
  7 # compatible open source license.
  8 
  9 import argparse
  10 import logging
  11 import sys
  12 from pathlib import Path
  13 
  14 from sign_workflow.sign_artifacts import SignArtifacts
  15 from sign_workflow.signer import Signer
  16 from system import console
  17 
  18 ACCEPTED_SIGNATURE_FILE_TYPES = [".sig"]
  19 
  20 
  21 def main():
  22     parser = argparse.ArgumentParser(description="Sign artifacts")
  23     parser.add_argument("target", type=Path, help="Path to local manifest file or artifact directory.")
  24     parser.add_argument("--component", nargs="?", help="Component name")
  25     parser.add_argument("--type", nargs="?", help="Artifact type")
  26     parser.add_argument("--sigtype", choices=ACCEPTED_SIGNATURE_FILE_TYPES, help="Type of Signature file", default=".asc")
  27     parser.add_argument(
  28         "-v",
  29         "--verbose",
  30         help="Show more verbose output.",
  31         action="store_const",
  32         default=logging.INFO,
  33         const=logging.DEBUG,
  34         dest="logging_level",
  35     )
  36     args = parser.parse_args()
  37 
  38     console.configure(level=args.logging_level)
  39 
  40     sign = SignArtifacts.from_path(path=args.target,
  41                                    component=args.component,
  42                                    artifact_type=args.type,
  43                                    signature_type=args.sigtype,
  44                                    signer=Signer())
  45 
  46     sign.sign()
  47 
  48 
  49 if __name__ == "__main__":
  50     sys.exit(main())
  51
  [end of src/run_sign.py]
  </code>
  
  I need you to solve this issue by generating a single patch file that I can apply directly to this repository using git apply. Please respond with a single patch file in the following format.
  <patch>
  diff --git a/file.py b/file.py
  --- a/file.py
  +++ b/file.py
  @@ -1,27 +1,35 @@
   def euclidean(a, b):
  -    while b:
  -        a, b = b, a % b
  -    return a
  +    if b == 0:
  +        return a
  +    return euclidean(b, a % b)
   
   
   def bresenham(x0, y0, x1, y1):
       points = []
       dx = abs(x1 - x0)
       dy = abs(y1 - y0)
  -    sx = 1 if x0 < x1 else -1
  -    sy = 1 if y0 < y1 else -1
  -    err = dx - dy
  +    x, y = x0, y0
  +    sx = -1 if x0 > x1 else 1
  +    sy = -1 if y0 > y1 else 1
   
  -    while True:
  -        points.append((x0, y0))
  -        if x0 == x1 and y0 == y1:
  -            break
  -        e2 = 2 * err
  -        if e2 > -dy:
  -            err -= dy
  -            x0 += sx
  -        if e2 < dx:
  -            err += dx
  -            y0 += sy
  +    if dx > dy:
  +        err = dx / 2.0
  +        while x != x1:
  +            points.append((x, y))
  +            err -= dy
  +            if err < 0:
  +                y += sy
  +                err += dx
  +            x += sx
  +    else:
  +        err = dy / 2.0
  +        while y != y1:
  +            points.append((x, y))
  +            err -= dx
  +            if err < 0:
  +                x += sx
  +                err += dy
  +            y += sy
  +
  +    points.append((x, y))
       return points
  
  </patch>
golden_diff: diff --git a/src/run_sign.py b/src/run_sign.py
  --- a/src/run_sign.py
  +++ b/src/run_sign.py
  @@ -24,6 +24,7 @@
       parser.add_argument("--component", nargs="?", help="Component name")
       parser.add_argument("--type", nargs="?", help="Artifact type")
       parser.add_argument("--sigtype", choices=ACCEPTED_SIGNATURE_FILE_TYPES, help="Type of Signature file", default=".asc")
  +    parser.add_argument("--platform", nargs="?", help="The distribution platform", default="linux")
       parser.add_argument(
           "-v",
           "--verbose",
  
verification_info: {"golden_diff": "diff --git a/src/run_sign.py b/src/run_sign.py\n--- a/src/run_sign.py\n+++ b/src/run_sign.py\n@@ -24,6 +24,7 @@\n     parser.add_argument(\"--component\", nargs=\"?\", help=\"Component name\")\n     parser.add_argument(\"--type\", nargs=\"?\", help=\"Artifact type\")\n     parser.add_argument(\"--sigtype\", choices=ACCEPTED_SIGNATURE_FILE_TYPES, help=\"Type of Signature file\", default=\".asc\")\n+    parser.add_argument(\"--platform\", nargs=\"?\", help=\"The distribution platform\", default=\"linux\")\n     parser.add_argument(\n         \"-v\",\n         \"--verbose\",\n", "issue": "[Bug]: Maven sign and upload should be done inside a docker container\n### Describe the bug\n\nWe should be using a docker container to run jenkinsjob. \r\n\r\nhttps://github.com/opensearch-project/opensearch-infra/blob/main/jenkins/jobs/OpenSearch_CI/release_ci/opensearch_maven_release/Jenkinsfile#L3-L5\r\n\r\nAlso, should this file be a part of `opensearch-build`?\n\n### To reproduce\n\nDocker container is not used - \r\n\r\nhttps://github.com/opensearch-project/opensearch-infra/blob/main/jenkins/jobs/OpenSearch_CI/release_ci/opensearch_maven_release/Jenkinsfile#L3-L5\n\n### Expected behavior\n\n_No response_\n\n### Screenshots\n\nIf applicable, add screenshots to help explain your problem.\n\n### Host / Environment\n\n_No response_\n\n### Additional context\n\n_No response_\n\n### Relevant log output\n\n_No response_\n", "before_files": [{"content": "#!/usr/bin/env python\n\n# SPDX-License-Identifier: Apache-2.0\n#\n# The OpenSearch Contributors require contributions made to\n# this file be licensed under the Apache-2.0 license or a\n# compatible open source license.\n\nimport argparse\nimport logging\nimport sys\nfrom pathlib import Path\n\nfrom sign_workflow.sign_artifacts import SignArtifacts\nfrom sign_workflow.signer import Signer\nfrom system import console\n\nACCEPTED_SIGNATURE_FILE_TYPES = [\".sig\"]\n\n\ndef main():\n    parser = argparse.ArgumentParser(description=\"Sign artifacts\")\n    parser.add_argument(\"target\", type=Path, help=\"Path to local manifest file or artifact directory.\")\n    parser.add_argument(\"--component\", nargs=\"?\", help=\"Component name\")\n    parser.add_argument(\"--type\", nargs=\"?\", help=\"Artifact type\")\n    parser.add_argument(\"--sigtype\", choices=ACCEPTED_SIGNATURE_FILE_TYPES, help=\"Type of Signature file\", default=\".asc\")\n    parser.add_argument(\n        \"-v\",\n        \"--verbose\",\n        help=\"Show more verbose output.\",\n        action=\"store_const\",\n        default=logging.INFO,\n        const=logging.DEBUG,\n        dest=\"logging_level\",\n    )\n    args = parser.parse_args()\n\n    console.configure(level=args.logging_level)\n\n    sign = SignArtifacts.from_path(path=args.target,\n                                   component=args.component,\n                                   artifact_type=args.type,\n                                   signature_type=args.sigtype,\n                                   signer=Signer())\n\n    sign.sign()\n\n\nif __name__ == \"__main__\":\n    sys.exit(main())\n", "path": "src/run_sign.py"}]}