FS#79342 - [skaffold] `failed: executing lifecycle: http: invalid Host header`

Attached to Project: Arch Linux
Opened by Eric Wang (enihcam) - Thursday, 10 August 2023, 03:08 GMT
Last edited by Toolybird (Toolybird) - Saturday, 07 October 2023, 00:34 GMT
Task Type Bug Report
Category Packages: Extra
Status Closed
Assigned To No-one
Architecture All
Severity High
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

Description:
skaffold in archlinux version is unable to connect to a docker registry, whereas its official pre-built binary version can.

```
$ skaffold dev
Generating tags...
- demo/helloApp -> demo/helloApp:latest
Checking cache...
- demo/helloApp: Not found. Building
Starting build...
Building [demo/helloApp]...
base: Pulling from paketo-buildpacks/builder
Digest: sha256:214012ca29b99a53ec653a27f4e91a5df3ea3b1a9ce8d7926a918ce7d06c18e0
Status: Image is up to date for gcr.io/paketo-buildpacks/builder:base
base-cnb: Pulling from paketo-buildpacks/run
Digest: sha256:1af9935d8987fd52b2266d288200c9482d1dd5529860bbf5bc2d248de1cb1a38
Status: Image is up to date for gcr.io/paketo-buildpacks/run:base-cnb
Cleaning up...
- No resources found
build [demo/helloApp] failed: executing lifecycle: http: invalid Host header
```

Additional info:
* package version(s)
> 2.6.3-1

* config and/or log files etc.
> n/a

* link to upstream bug report, if any
https://github.com/docker/cli/issues/4437
https://github.com/moby/moby/issues/45935
https://github.com/golang/go/issues/60374

Steps to reproduce:
`pacman -S skaffold`
in a skaffold project, try `skaffold dev`.

change to official binary that works:
```
curl -Lo skaffold https://storage.googleapis.com/skaffold/releases/latest/skaffold-linux-amd64
install skaffold /usr/bin/
skaffold dev
```
This task depends upon

Closed by  Toolybird (Toolybird)
Saturday, 07 October 2023, 00:34 GMT
Reason for closing:  No response
Comment by Eric Wang (enihcam) - Thursday, 10 August 2023, 03:09 GMT
ah, we have the official binary version:

https://aur.archlinux.org/packages/skaffold-bin

problem 'solved'!
Comment by Toolybird (Toolybird) - Thursday, 10 August 2023, 06:17 GMT
IIUC it needs a recompile with a fixed "go" pkg? AFAICT the fix [1] hasn't made it to a release tag yet?

[1] https://github.com/golang/go/commit/b9153f6ef338baee5fe02a867c8fbc83a8b29dd1
Comment by Eric Wang (enihcam) - Thursday, 10 August 2023, 11:28 GMT
I didn't see anything unusual from their build pipe, or maybe you want to compare their build files with PKGBUILD as well?

https://github.com/GoogleContainerTools/skaffold/blob/main/Makefile
https://github.com/GoogleContainerTools/skaffold/blob/main/.github/workflows/integration-linux.yml
Comment by loqs (loqs) - Thursday, 10 August 2023, 15:17 GMT
@enihcam have you tried rebuilding skaffold using go that was patched with the commit Toolybird linked to rule that out? If not would it help if I provided such a build?

Loading...