Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: update libcurl in docs pipeline #22203

Merged
merged 3 commits into from
Dec 21, 2022
Merged

fix: update libcurl in docs pipeline #22203

merged 3 commits into from
Dec 21, 2022

Conversation

jolheiser
Copy link
Member

@jolheiser jolheiser commented Dec 21, 2022

Our docs pipeline has been failing recently, and running the image locally without -s shows

libcurl

Adding curl-dev appears to fix the issue.

hugo-curl


Per @silverwind instead we can just update libcurl to make them match.

Signed-off-by: jolheiser <john.olheiser@gmail.com>
@jolheiser jolheiser added topic/build PR changes how Gitea is built, i.e. regarding Docker or the Makefile outdated/backport/v1.18 This PR should be backported to Gitea 1.18 labels Dec 21, 2022
@jolheiser jolheiser marked this pull request as ready for review December 21, 2022 18:14
@silverwind
Copy link
Member

Why?

@GiteaBot GiteaBot added the lgtm/need 2 This PR needs two approvals by maintainers to be considered for merging. label Dec 21, 2022
@jolheiser
Copy link
Member Author

jolheiser commented Dec 21, 2022

Why?

Otherwise curl -L fails with unknown option was passed to libcurl

Our docs pipeline started to fail recently when plugins/hugo published a new version.

If there is a better way, I am open to it.

EDIT: I updated my PR description for clarification, as discussion happened in Discord.

@GiteaBot GiteaBot added lgtm/need 1 This PR needs approval from one additional maintainer to be merged. and removed lgtm/need 2 This PR needs two approvals by maintainers to be considered for merging. labels Dec 21, 2022
@silverwind
Copy link
Member

Huh, looks like curl is seriously broken inside that container. Must be some global config or something, not sure. Do you know where the source Dockerfile for this image lives?

$ docker run -it --entrypoint /bin/sh plugins/hugo
/ # apk add --no-cache curl > /dev/null
/ # curl https://gohugo.io/
curl: (48) An unknown option was passed in to libcurl

@jolheiser
Copy link
Member Author

jolheiser commented Dec 21, 2022

It comes from https://github.com/drone-plugins/drone-hugo/blob/master/docker/Dockerfile.linux.arm64

Of note, the image it uses as a base, plugins/base:linux-arm64 seems to work fine, so something in the drone-hugo docker seems to be affecting it.

@silverwind
Copy link
Member

silverwind commented Dec 21, 2022

Issue is curl and libcurl do not match inside the image. Cause unknown, that Dockerfile does not deal with curl. Some layer before might have installed the old libcurl version.

/ # curl -V
curl 7.87.0 (x86_64-alpine-linux-musl) libcurl/7.86.0 OpenSSL/3.0.7 zlib/1.2.13 brotli/1.0.9 nghttp2/1.51.0
Release-Date: 2022-12-21
Protocols: dict file ftp ftps gopher gophers http https imap imaps mqtt pop3 pop3s rtsp smb smbs smtp smtps telnet tftp ws wss
Features: alt-svc AsynchDNS brotli HSTS HTTP2 HTTPS-proxy IPv6 Largefile libz NTLM NTLM_WB SSL threadsafe TLS-SRP UnixSockets
WARNING: curl and libcurl versions do not match. Functionality may be affected.

.drone.yml Outdated Show resolved Hide resolved
Co-authored-by: silverwind <me@silverwind.io>
@silverwind
Copy link
Member

Opened drone-plugins/drone-hugo#36 to track upstream.

@jolheiser jolheiser changed the title fix: add curl-dev to docs pipeline fix: update libcurl in docs pipeline Dec 21, 2022
@GiteaBot GiteaBot added lgtm/done This PR has enough approvals to get merged. There are no important open reservations anymore. and removed lgtm/need 1 This PR needs approval from one additional maintainer to be merged. labels Dec 21, 2022
.drone.yml Outdated Show resolved Hide resolved
Co-authored-by: silverwind <me@silverwind.io>
@jolheiser jolheiser added the backport/done All backports for this PR have been created label Dec 21, 2022
jolheiser added a commit that referenced this pull request Dec 21, 2022
Backport #22203

Signed-off-by: jolheiser <john.olheiser@gmail.com>
Co-authored-by: silverwind <me@silverwind.io>
@jolheiser jolheiser added the skip-changelog This PR is irrelevant for the (next) changelog, for example bug fixes for unreleased features. label Dec 21, 2022
@jolheiser
Copy link
Member Author

🎺 🤖

@jolheiser jolheiser merged commit 9914b21 into go-gitea:main Dec 21, 2022
@jolheiser jolheiser deleted the docs branch December 21, 2022 19:45
jolheiser added a commit that referenced this pull request Dec 21, 2022
Backport #22203

Signed-off-by: jolheiser <john.olheiser@gmail.com>
@silverwind
Copy link
Member

BTW we should probably just run hugo in a regular go image using the same syntax we use for other go tools. That way we don't need to rely on obscure images like that one.

go run github.com/gohugoio/hugo@v0.108.0 --help

@silverwind
Copy link
Member

#22206 for that.

zjjhot added a commit to zjjhot/gitea that referenced this pull request Dec 23, 2022
* giteaoffical/main: (32 commits)
  Hide file borders on sticky diff box (go-gitea#22217)
  Test views of LFS files (go-gitea#22196)
  update docs latest to 1.17.4
  Frontport 1.17.4 changelog (go-gitea#22216)
  Remove test session cache to reduce possible concurrent problem (go-gitea#22199)
  Upgrade hugo to 0.82 (go-gitea#22209)
  Fix container layer display overflow (go-gitea#22208)
  Run hugo via `go run` and lock its version (go-gitea#22206)
  Update bleve and zapx to fix unaligned atomic (go-gitea#22031)
  Allow empty assignees on pull request edit (go-gitea#22150)
  Add Feed for Releases and Tags (go-gitea#21696)
  fix: update libcurl in docs pipeline (go-gitea#22203)
  Fixed colour transparency regex matching in project board sorting (go-gitea#22091) (go-gitea#22092)
  Mobile fix for Project view: Add delay to Sortable.js on mobile, to ensure scrolling is possible. (go-gitea#22152)
  Normalize NuGet package version on upload (go-gitea#22186)
  Attempt to fix TestExportUserGPGKeys (go-gitea#22159)
  Specify ID in `TestAPITeam` (go-gitea#22192)
  Repair LFS web rendering. (go-gitea#22195)
  Fix misc whitespace issues in install docs (go-gitea#22189)
  Update JS dependencies and eslint (go-gitea#22190)
  ...
@go-gitea go-gitea locked and limited conversation to collaborators May 3, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
backport/done All backports for this PR have been created lgtm/done This PR has enough approvals to get merged. There are no important open reservations anymore. outdated/backport/v1.18 This PR should be backported to Gitea 1.18 skip-changelog This PR is irrelevant for the (next) changelog, for example bug fixes for unreleased features. topic/build PR changes how Gitea is built, i.e. regarding Docker or the Makefile
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants