Skip to content

Commit

Permalink
chore(dockerfile): use registry.suse.com/bci/golang:1.22 base image
Browse files Browse the repository at this point in the history
- use registry.suse.com/bci/golang:1.22 base image
- update docker version

Signed-off-by: Derek Su <[email protected]>
  • Loading branch information
derekbit committed Jul 1, 2024
1 parent 0ac17c6 commit 12cd29b
Showing 1 changed file with 3 additions and 11 deletions.
14 changes: 3 additions & 11 deletions Dockerfile.dapper
Original file line number Diff line number Diff line change
@@ -1,24 +1,16 @@
FROM ubuntu:18.04
FROM registry.suse.com/bci/golang:1.22

ARG DAPPER_HOST_ARCH=amd64
ARG http_proxy
ARG https_proxy
ENV HOST_ARCH=${DAPPER_HOST_ARCH} ARCH=${DAPPER_HOST_ARCH}

RUN apt-get update && \
apt-get install -y gcc ca-certificates git wget curl vim less file nfs-common && \
rm -f /bin/sh && ln -s /bin/bash /bin/sh

ENV DOCKER_URL_amd64=https://get.docker.com/builds/Linux/x86_64/docker-1.10.3 \
DOCKER_URL_arm64=https://github.com/rancher/docker/releases/download/v1.10.3-ros1/docker-1.10.3_arm \
DOCKER_URL=DOCKER_URL_${ARCH}

RUN wget -O - ${!DOCKER_URL} > /usr/bin/docker && chmod +x /usr/bin/docker
RUN zypper -n install gcc ca-certificates git wget curl vim less file nfs-client awk docker && \
rm -rf /var/cache/zypp/*

ENV GOLANG_ARCH_amd64=amd64 GOLANG_ARCH_arm64=arm64 GOLANG_ARCH=GOLANG_ARCH_${ARCH} \
GOPATH=/go PATH=/go/bin:/usr/local/go/bin:${PATH} SHELL=/bin/bash

RUN wget -O - https://storage.googleapis.com/golang/go1.21.3.linux-${!GOLANG_ARCH}.tar.gz | tar -xzf - -C /usr/local
RUN curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(go env GOPATH)/bin v1.55.2

ENV DAPPER_SOURCE /go/src/github.com/longhorn/backupstore
Expand Down

0 comments on commit 12cd29b

Please sign in to comment.