From 1654759865a312007f369111b988ebcaa91f8005 Mon Sep 17 00:00:00 2001 From: Clark Boylan Date: Wed, 15 Mar 2023 11:16:20 -0700 Subject: [PATCH] Update gitea to 1.19.3 Gitea 1.19 is here. Release notes can be found at: https://github.com/go-gitea/gitea/blob/v1.19.3/CHANGELOG.md I've highlighted the breaking changes entries in this commit message with notes on whether or not this affects us. * 1.19.0 * Add loading yaml label template files (#22976) (#23232) * I think this is for auto applying labels to PRs? Shouldn't affect us. * Make issue and code search support camel case for Bleve (#22829) * We don't rely on code search in gitea yet, but this seems like a good addition. * Repositories: by default disable all units except code and pulls on forks (#22541) * We don't allow forks so this shouldn't affect us. * Support template for merge message description (#22248) * We don't do merging via gitea so this shouldn't affect us. * Remove ONLY_SHOW_RELEVANT_REPOS setting (#21962) * We don't set this flag in our app.ini config file. * Implement actions (#21937) * They are disabled by default, but I've explicitly disabled them as we use Zuul. * Remove deprecated DSA host key from Docker Container (#21522) * Our installatins were all created prior to this update which generated DSA keys. We can go and manually clean them up with gitea disabled if we like. * Improve valid user name check (#20136) * As long as our CI job is able to create the necessary accounts we should be fine. * 1.19.1 * Rename actions unit to repo.actions and add docs for it (#23733) (#23881) * app.ini.j2 updated to use repo.actions to disable the repo unit. * 1.19.2 * No breaking changes listed. * 1.19.3 * No breaking changes listed. In addition to the breaking changes upstream has updated to golang 1.20 and nodejs 18. We update our image to match. In 1.19.0 and 1.19.1 org listing required authentication which was a new change/regression in [0] gitea. I have updated the logo update role to drop authentication details to make it clear this API should be publicly accessible. In earlier patchsets I was forcing basic auth due to another bug [1] which is not correct as we expect this API to be public. Updating the role this way makes that more clear. Finally the usual template updates are applied to keep our forked templates in line with upstream. There were no template changes between 1.19.0, 1.19.1, 1.19.2, and 1.19.3 according to git diff. [0] https://github.com/go-gitea/gitea/issues/24159 [1] https://github.com/go-gitea/gitea/issues/24160 Change-Id: I5570deaf505a27c8c90c58896de990a4d2d44530 --- docker/gitea/Dockerfile | 6 +- .../custom/templates/base/head_navbar.tmpl | 74 +++++++++---------- .../gitea/custom/templates/repo/header.tmpl | 58 ++++++++------- .../roles/gitea-set-org-logos/tasks/main.yaml | 3 - playbooks/roles/gitea/templates/app.ini.j2 | 5 +- 5 files changed, 74 insertions(+), 72 deletions(-) diff --git a/docker/gitea/Dockerfile b/docker/gitea/Dockerfile index 36a8f28151..3c9165b15e 100644 --- a/docker/gitea/Dockerfile +++ b/docker/gitea/Dockerfile @@ -25,17 +25,17 @@ ################################### #Build stage -FROM docker.io/library/golang:1.19-bullseye AS build-env +FROM docker.io/library/golang:1.20-bullseye AS build-env LABEL maintainer="infra-root@openstack.org" -ARG GITEA_VERSION="v1.18.5" +ARG GITEA_VERSION="v1.19.3" ENV TAGS "bindata $TAGS" #Build deps RUN apt-get update && apt-get -y install build-essential git apt-transport-https curl gnupg2 \ && curl -sS https://deb.nodesource.com/gpgkey/nodesource.gpg.key | apt-key add - \ - && echo "deb https://deb.nodesource.com/node_16.x bullseye main" | tee /etc/apt/sources.list.d/nodesource.list \ + && echo "deb https://deb.nodesource.com/node_18.x bullseye main" | tee /etc/apt/sources.list.d/nodesource.list \ && apt-get update \ && apt-get -q --option "Dpkg::Options::=--force-confold" --assume-yes install nodejs \ && mkdir -p ${GOPATH}/src/code.gitea.io/gitea diff --git a/docker/gitea/custom/templates/base/head_navbar.tmpl b/docker/gitea/custom/templates/base/head_navbar.tmpl index d21e57a7f0..879abde516 100644 --- a/docker/gitea/custom/templates/base/head_navbar.tmpl +++ b/docker/gitea/custom/templates/base/head_navbar.tmpl @@ -1,24 +1,26 @@ -