Skip to content
Snippets Groups Projects
Select Git revision
  • 647cfd4f2b8614ba393dcf7e02856678bf47cc7e
  • master default protected
  • develop
  • feature/virtual
  • feature/slides
  • feature/poetry
6 results

thinkpad.md

Blame
  • Dockerfile NaN GiB
    FROM debian:bullseye AS build
    RUN apt-get -q update \
      && DEBIAN_FRONTEND=noninteractive apt-get install -qy --no-install-recommends \
      build-essential \
      pkg-config \
      git \
      ca-certificates \
      golang-go \
      && rm -rf /var/lib/apt/lists/*
    
    ENV GOPATH=/go
    WORKDIR $GOPATH
    RUN git clone https://github.com/OperatorFoundation/shapeshifter-dispatcher /shapeshifter-dispatcher && cd /shapeshifter-dispatcher && go build
    RUN strip /shapeshifter-dispatcher/shapeshifter-dispatcher
    RUN go get -u github.com/kumina/openvpn_exporter
    RUN strip $GOPATH/bin/openvpn_exporter
    
    FROM registry.git.autistici.org/ai3/docker/s6-base
    RUN apt-get -q update \
      && DEBIAN_FRONTEND=noninteractive apt-get install -qy --no-install-recommends \
      libcap2-bin \
      netcat-openbsd \
      iptables \
      iproute2 \
      knot-resolver \
      knot-resolver-module-http \
      openvpn \
      && rm -rf /var/lib/apt/lists/*
    
    COPY --from=build /shapeshifter-dispatcher/shapeshifter-dispatcher /usr/local/bin/shapeshifter-dispatcher
    COPY --from=build /go/bin/openvpn_exporter /usr/local/bin/openvpn_exporter
    
    RUN setcap cap_net_admin,cap_net_bind_service+ep /usr/sbin/openvpn
    RUN setcap cap_net_admin+ep /bin/ip
    RUN setcap cap_net_bind_service+ep /usr/sbin/kresd
    RUN update-alternatives --set iptables /usr/sbin/iptables-legacy
    
    # S6 configuration
    COPY conf/ /etc/