You are viewing a plain text version of this content. The canonical link for it is here.
Posted to gitbox@yetus.apache.org by aw...@apache.org on 2022/11/24 02:59:31 UTC

[yetus] branch main updated: YETUS-1193. Upgrade to Ubuntu Jammy (#297)

This is an automated email from the ASF dual-hosted git repository.

aw pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/yetus.git


The following commit(s) were added to refs/heads/main by this push:
     new 38dc83da YETUS-1193. Upgrade to Ubuntu Jammy (#297)
38dc83da is described below

commit 38dc83da79c54ced7b8e282514eaaa43da6f45c5
Author: Allen Wittenauer <aw...@apache.org>
AuthorDate: Wed Nov 23 18:59:26 2022 -0800

    YETUS-1193. Upgrade to Ubuntu Jammy (#297)
---
 asf-site-src/Dockerfile                            |  4 +--
 asf-site-src/Gemfile.lock                          | 34 +++++++++----------
 precommit/src/main/python/jenkins-admin.py         |  4 +--
 .../src/main/shell/plugins.d/detsecrets_parse.py   | 18 +++++-----
 .../src/main/shell/test-patch-docker/Dockerfile    | 38 ++++++++++------------
 shelldocs/src/main/python/shelldocs.py             |  6 ++--
 6 files changed, 51 insertions(+), 53 deletions(-)

diff --git a/asf-site-src/Dockerfile b/asf-site-src/Dockerfile
index 2471f00b..7b7ea467 100644
--- a/asf-site-src/Dockerfile
+++ b/asf-site-src/Dockerfile
@@ -80,10 +80,10 @@ ENV GEM_HOME ${BUNDLE_PATH}
 # on re-launches
 # hadolint ignore=DL3028
 RUN gem install bundler \
-        middleman:'4.4.2' \
+        middleman:'4.4.3' \
         middleman-livereload \
         middleman-syntax \
-        nokogiri:1.13.3 \
+        nokogiri:1.13.9 \
         sassc:2.4.0 \
         tzinfo-data
 
diff --git a/asf-site-src/Gemfile.lock b/asf-site-src/Gemfile.lock
index ca327a0d..b7c8dc69 100644
--- a/asf-site-src/Gemfile.lock
+++ b/asf-site-src/Gemfile.lock
@@ -9,12 +9,11 @@ GIT
 GEM
   remote: https://rubygems.org/
   specs:
-    activesupport (6.1.7)
+    activesupport (7.0.4)
       concurrent-ruby (~> 1.0, >= 1.0.2)
       i18n (>= 1.6, < 2)
       minitest (>= 5.1)
       tzinfo (~> 2.0)
-      zeitwerk (~> 2.3)
     addressable (2.8.1)
       public_suffix (>= 2.0.2, < 6.0)
     backports (3.23.0)
@@ -23,7 +22,7 @@ GEM
       execjs
     coffee-script-source (1.12.2)
     concurrent-ruby (1.1.10)
-    contracts (0.13.0)
+    contracts (0.17)
     dotenv (2.8.1)
     em-websocket (0.5.3)
       eventmachine (>= 0.12.9)
@@ -50,24 +49,24 @@ GEM
     libv8-node (16.10.0.0)
     libv8-node (16.10.0.0-aarch64-linux)
     libv8-node (16.10.0.0-x86_64-linux)
-    listen (3.0.8)
-      rb-fsevent (~> 0.9, >= 0.9.4)
-      rb-inotify (~> 0.9, >= 0.9.7)
+    listen (3.7.1)
+      rb-fsevent (~> 0.10, >= 0.10.3)
+      rb-inotify (~> 0.9, >= 0.9.10)
     memoist (0.16.2)
-    middleman (4.4.2)
+    middleman (4.4.3)
       coffee-script (~> 2.2)
-      haml (>= 4.0.5)
+      haml (>= 4.0.5, < 6.0)
       kramdown (>= 2.3.0)
-      middleman-cli (= 4.4.2)
-      middleman-core (= 4.4.2)
-    middleman-cli (4.4.2)
+      middleman-cli (= 4.4.3)
+      middleman-core (= 4.4.3)
+    middleman-cli (4.4.3)
       thor (>= 0.17.0, < 2.0)
-    middleman-core (4.4.2)
-      activesupport (>= 6.1, < 7.0)
+    middleman-core (4.4.3)
+      activesupport (>= 6.1, < 7.1)
       addressable (~> 2.4)
       backports (~> 3.6)
       bundler (~> 2.0)
-      contracts (~> 0.13.0)
+      contracts (~> 0.13)
       dotenv
       erubis
       execjs (~> 2.0)
@@ -76,7 +75,7 @@ GEM
       hamster (~> 3.0)
       hashie (~> 3.4)
       i18n (~> 1.6.0)
-      listen (~> 3.0.0)
+      listen (~> 3.0)
       memoist (~> 0.14)
       padrino-helpers (~> 0.15.0)
       parallel
@@ -113,7 +112,7 @@ GEM
     sassc (2.4.0)
       ffi (~> 1.9)
     servolux (0.13.0)
-    temple (0.8.2)
+    temple (0.9.1)
     thor (1.2.1)
     tilt (2.0.11)
     toml (0.3.0)
@@ -123,7 +122,6 @@ GEM
     uglifier (3.2.0)
       execjs (>= 0.3.0, < 3)
     webrick (1.7.0)
-    zeitwerk (2.6.0)
 
 PLATFORMS
   aarch64-linux
@@ -141,4 +139,4 @@ DEPENDENCIES
   wdm (~> 0.1.0)
 
 BUNDLED WITH
-   2.3.10
+   2.3.26
diff --git a/precommit/src/main/python/jenkins-admin.py b/precommit/src/main/python/jenkins-admin.py
index dbe261a2..a235368b 100755
--- a/precommit/src/main/python/jenkins-admin.py
+++ b/precommit/src/main/python/jenkins-admin.py
@@ -40,9 +40,9 @@ def http_get(resource, ignore_error=False, username=None, password=None):
 
     try:
         if username and password:
-            response = requests.get(resource, auth=(username, password))
+            response = requests.get(resource, auth=(username, password), timeout=10)
         else:
-            response = requests.get(resource)
+            response = requests.get(resource, timeout=10)
         response.raise_for_status()
     except requests.exceptions.HTTPError as http_err:
         errstr = str(http_err)
diff --git a/precommit/src/main/shell/plugins.d/detsecrets_parse.py b/precommit/src/main/shell/plugins.d/detsecrets_parse.py
index 38d8cc15..abb29ff1 100755
--- a/precommit/src/main/shell/plugins.d/detsecrets_parse.py
+++ b/precommit/src/main/shell/plugins.d/detsecrets_parse.py
@@ -22,14 +22,14 @@ import sys
 
 hashdict = []
 
-inputfile = sys.argv[1]
-inputpath = pathlib.Path(inputfile).resolve()
+INPUTFILE = sys.argv[1]
+INPUTPATH = pathlib.Path(INPUTFILE).resolve()
 
 if len(sys.argv) == 3:
-    hashfile = sys.argv[2]
-    hashpath = pathlib.Path(hashfile).resolve()
-    if hashpath.exists():
-        with open(hashpath, encoding='utf-8') as filein:
+    HASHFILE = sys.argv[2]
+    HASHPATH = pathlib.Path(HASHFILE).resolve()
+    if HASHPATH.exists():
+        with open(HASHPATH, encoding='utf-8') as filein:
             while True:
                 line = filein.readline()
                 if not line:
@@ -38,11 +38,11 @@ if len(sys.argv) == 3:
                     continue
                 hashdict.append(line.strip())
 
-if not inputpath.exists() or not inputpath.is_file():
-    logging.error('%s does not exist or is not a file.', inputpath)
+if not INPUTPATH.exists() or not INPUTPATH.is_file():
+    logging.error('%s does not exist or is not a file.', INPUTPATH)
     sys.exit(1)
 
-with open(inputfile, encoding='utf-8') as filein:
+with open(INPUTFILE, encoding='utf-8') as filein:
     rawdata = filein.read()
 
 jsondata = json.loads(rawdata)
diff --git a/precommit/src/main/shell/test-patch-docker/Dockerfile b/precommit/src/main/shell/test-patch-docker/Dockerfile
index 6d192b5a..8badeccd 100644
--- a/precommit/src/main/shell/test-patch-docker/Dockerfile
+++ b/precommit/src/main/shell/test-patch-docker/Dockerfile
@@ -22,7 +22,7 @@
 #
 ###############
 
-FROM ubuntu:focal AS yetusbase
+FROM ubuntu:jammy AS yetusbase
 
 ## NOTE to committers: if this gets moved from Xenial to something else, be
 ## sure to also fix the gpg link in asf-site-src as appropriate
@@ -145,7 +145,7 @@ RUN curl -sSL \
 # Install hadolint (dockerfile lint)
 ####
 FROM yetusbase AS yetushadolint
-ARG HADOLINT_VERSION=2.10.0
+ARG HADOLINT_VERSION=2.12.0
 SHELL ["/bin/bash", "-o", "pipefail", "-c"]
 RUN if [[ "$(uname -m)" == "x86_64" ]]; then curl -sSL \
         https://github.com/hadolint/hadolint/releases/download/v$HADOLINT_VERSION/hadolint-Linux-"$(uname -m)" \
@@ -157,7 +157,7 @@ RUN if [[ "$(uname -m)" == "x86_64" ]]; then curl -sSL \
 # Install buf (protobuf lint)
 ####
 FROM yetusbase AS yetusbuf
-ARG BUF_VERSION=1.8.0
+ARG BUF_VERSION=1.9.0
 SHELL ["/bin/bash", "-o", "pipefail", "-c"]
 RUN curl -sSL \
       https://github.com/bufbuild/buf/releases/download/v$BUF_VERSION/buf-Linux-"$(uname -m)".tar.gz \
@@ -169,7 +169,7 @@ RUN curl -sSL \
 # Install bats (TAP-capable unit testing for shell scripts)
 ####
 FROM yetusbase AS yetusbats
-ARG BATS_VERSION=1.8.0
+ARG BATS_VERSION=1.8.2
 SHELL ["/bin/bash", "-o", "pipefail", "-c"]
 RUN git clone --branch v$BATS_VERSION \
       https://github.com/bats-core/bats-core.git \
@@ -208,7 +208,7 @@ RUN git clone \
 # NOTE: go must be installed prior to executing this block!
 ####
 FROM yetusbase as yetusgolangci
-ARG GOLANGCILINT_VERSION=1.50.0
+ARG GOLANGCILINT_VERSION=1.50.1
 SHELL ["/bin/bash", "-o", "pipefail", "-c"]
 RUN curl -sSL \
       https://github.com/golangci/golangci-lint/releases/download/v$GOLANGCILINT_VERSION/golangci-lint-$GOLANGCILINT_VERSION-"$(go env GOOS)"-"$(go env GOARCH)".tar.gz \
@@ -278,7 +278,7 @@ RUN add-apt-repository -y \
    "deb [arch=$(dpkg --print-architecture)] https://download.docker.com/linux/ubuntu \
    $(lsb_release -cs) \
    stable" \
-    && apt-get -q update && apt-get -q install --no-install-recommends -y docker-ce \
+    && apt-get -q update && apt-get -q install --no-install-recommends -y docker-ce docker-compose-plugin \
     && apt-get clean \
     && rm -rf /var/lib/apt/lists/*
 
@@ -286,7 +286,7 @@ RUN add-apt-repository -y \
 # Install maven
 ######
 # hadolint ignore=DL3008,DL3059
-ARG MVN_VERSION=3.8.5
+ARG MVN_VERSION=3.8.6
 ARG MVN_TGZ=apache-maven-$MVN_VERSION-bin.tar.gz
 RUN curl -sSL \
         -o $MVN_TGZ \
@@ -319,14 +319,13 @@ RUN apt-get -q update && apt-get -q install --no-install-recommends -y \
 # Install python3 and pylint3
 # astroid and pylint go hand-in-hand.  Upgrade both at the same time.
 ######
-ARG PY3_ANSIBLE_VERSION=5.5.0
-ARG PY3_ANSIBLELINT_VERSION=6.0.2
-ARG PY3_ASTROID_VERSION=2.11.2
-ARG PY3_CODESPELL_VERSION=2.2.1
-ARG PY3_DETECT_SECRETS=1.2.0
-ARG PY3_DOCKER_COMPOSE=1.29.2
-ARG PY3_PYLINT_VERSION=2.13.4
-ARG PY3_YAMLLINT_VERSION=1.26.3
+ARG PY3_ANSIBLE_VERSION=6.6.0
+ARG PY3_ANSIBLELINT_VERSION=6.8.7
+ARG PY3_ASTROID_VERSION=2.12.13
+ARG PY3_CODESPELL_VERSION=2.2.2
+ARG PY3_DETECT_SECRETS=1.4.0
+ARG PY3_PYLINT_VERSION=2.15.6
+ARG PY3_YAMLLINT_VERSION=1.28.0
 # hadolint ignore=DL3008
 RUN apt-get -q update && apt-get -q install --no-install-recommends -y \
         python3 \
@@ -356,7 +355,6 @@ RUN apt-get -q update && apt-get -q install --no-install-recommends -y \
         astroid==$PY3_ASTROID_VERSION \
         codespell==$PY3_CODESPELL_VERSION \
         detect-secrets==$PY3_DETECT_SECRETS \
-        docker-compose==$PY3_DOCKER_COMPOSE \
         pylint==$PY3_PYLINT_VERSION \
         yamllint==$PY3_YAMLLINT_VERSION \
     && rm -rf /root/.cache \
@@ -367,9 +365,9 @@ RUN apt-get -q update && apt-get -q install --no-install-recommends -y \
 ####
 # Install ruby and associated bits
 ###
-ARG RUBY_BUNDLER_VERSION=2.3.22
+ARG RUBY_BUNDLER_VERSION=2.3.26
 ARG RUBY_RAKE_VERSION=13.0.6
-ARG RUBY_RUBOCOP_VERSION=1.26.1
+ARG RUBY_RUBOCOP_VERSION=1.39
 # hadolint ignore=DL3008
 RUN echo 'gem: --no-rdoc --no-ri' >> /root/.gemrc \
     && apt-get -q update && apt-get -q install --no-install-recommends -y \
@@ -389,8 +387,8 @@ ENV BUNDLE_PATH /var/tmp/.bundler-gems
 ###
 # Install npm and JSHint
 ###
-ARG JSHINT_VERSION=2.13.4
-ARG MARKDOWNLINTCLI_VERSION=0.31.1
+ARG JSHINT_VERSION=2.13.6
+ARG MARKDOWNLINTCLI_VERSION=0.32.2
 ARG JSONLINT_VERSION=1.6.0
 # hadolint ignore=DL3008
 RUN curl -sSL https://deb.nodesource.com/setup_14.x | bash - \
diff --git a/shelldocs/src/main/python/shelldocs.py b/shelldocs/src/main/python/shelldocs.py
index 0b8bfbe3..38a97a18 100755
--- a/shelldocs/src/main/python/shelldocs.py
+++ b/shelldocs/src/main/python/shelldocs.py
@@ -169,7 +169,8 @@ class ProcessFile:
                     return True
             return False
 
-    def _docstrip(self, key, dstr):  #pylint: disable=no-self-use
+    @staticmethod
+    def _docstrip(key, dstr):
         '''remove extra spaces from shelldoc phrase'''
         dstr = re.sub(f"^## @{key} ", "", dstr)
         dstr = dstr.strip()
@@ -223,7 +224,8 @@ class ProcessFile:
             return
         funcdef.returnt.append(self._docstrip('return', text))
 
-    def _process_function(self, funcdef, text=None, linenum=1):  # pylint: disable=no-self-use
+    @staticmethod
+    def _process_function(funcdef, text=None, linenum=1):
         '''set the name of the function'''
         if ProcessFile.FUNCTIONRE.match(text):
             definition = ProcessFile.FUNCTIONRE.match(text).groups()[0]