tailscale / tailscale/caddy-tailscale

Unable to build with xcaddy when paired with caddy-maxmind-geolocation.

Open
#75 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

likely-fixed
Dominant language
Go
Stars
978
Forks
96
PR merge metrics
No merged PRs in 30d

Description

I seems to be unable to build caddy-tailscale with caddy-maxmind-geolocation.
Building them separately works fine but if I build them together the build fails with:

26.54 2024/09/06 11:55:23 [INFO] exec (timeout=0s): /usr/local/go/bin/go build -o /usr/bin/caddy -ldflags -w -s -trimpath -tags nobadger 
56.30 # tailscale.com/net/tstun
56.30 /go/pkg/mod/tailscale.com@v1.68.2/net/tstun/wrap.go:965:17: res.packet.IsNil undefined (type *stack.PacketBuffer has no field or method IsNil)
59.87 2024/09/06 11:55:56 [INFO] Skipping cleanup as requested; leaving folder intact: /tmp/buildenv_2024-09-06-1154.204774573
59.87 2024/09/06 11:55:56 [FATAL] exit status 1
------
failed to solve: process "/bin/sh -c xcaddy build     --with github.com/tailscale/caddy-tailscale     --with github.com/porech/caddy-maxmind-geolocation" did not complete successfully: exit code: 1

This is my Dockerfile:

FROM caddy:2.8.4-builder AS builder
RUN xcaddy build \
    --with github.com/tailscale/caddy-tailscale \
    --with github.com/porech/caddy-maxmind-geolocation
FROM caddy:2.8.4
COPY --from=builder /usr/bin/caddy /usr/bin/caddy

Maybe I'm doing something wrong here?

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the shown Dockerfile and reproduce the combined xcaddy build using caddy:2.8.4-builder. Read the reported failure in tailscale.com/net/tstun/wrap.go at line 965 and compare it with the separate builds. Done means the Docker build succeeds when caddy-tailscale and caddy-maxmind-geolocation are included together.

Written by the indexing model from the issue text.

Assessment

Tech stack
docker, go
Domain
build-system
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.