Skip to content

Commit

Permalink
scratch and alpine images
Browse files Browse the repository at this point in the history
  • Loading branch information
cjimti committed Aug 26, 2023
1 parent 2f92ccd commit 490d59b
Show file tree
Hide file tree
Showing 3 changed files with 40 additions and 28 deletions.
17 changes: 17 additions & 0 deletions dockerfiles/alpine/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
FROM alpine:3.18.3 as Builder

RUN mkdir -p /www && mkdir -p /files
COPY www/index.html www/index.html
COPY files/README.txt files/README.txt
COPY asws /bin/asws

RUN echo "nobody:x:65534:65534:Nobody:/:" > /etc/passwd

ENV PATH=/bin

WORKDIR /

ENV IP=0.0.0.0

USER nobody
ENTRYPOINT ["/bin/asws"]
File renamed without changes.
51 changes: 23 additions & 28 deletions goreleaser.yml
Original file line number Diff line number Diff line change
Expand Up @@ -65,42 +65,37 @@ dockers:
goarm: ''
ids:
- asws
dockerfile: dockerfiles/amd64/Dockerfile
dockerfile: dockerfiles/scratch/Dockerfile
extra_files:
- www
- files
image_templates:
- "txn2/asws:latest"
- "txn2/asws:{{ .Tag }}"
- "txn2/asws:v{{ .Major }}"
- "txn2/asws:amd64-{{ .Tag }}"
- "txn2/asws:amd64-v{{ .Major }}"
- "txn2/asws:latest_alpine-3"
- "txn2/asws:{{ .Tag }}_alpine-3"
- "txn2/asws:v{{ .Major }}_alpine-3"
- "txn2/asws:amd64-{{ .Tag }}_alpine-3"
- "txn2/asws:amd64-v{{ .Major }}_alpine-3"
- "txn2/asws:latest-scratch"
- "txn2/asws:{{ .Tag }}-scratch"
- "txn2/asws:v{{ .Major }}-scratch"
build_flag_templates:
- "--label=org.label-schema.schema-version=1.0"
- "--label=org.label-schema.version={{.Version}}"
- "--label=org.label-schema.name={{.ProjectName}}"
-
goos: linux
goarch: amd64
goarm: ''
ids:
- asws
dockerfile: dockerfiles/alpine/Dockerfile
extra_files:
- www
- files
image_templates:
- "txn2/asws:latest-alpine"
- "txn2/asws:{{ .Tag }}-alpine"
- "txn2/asws:v{{ .Major }}-alpine-3"
- "txn2/asws:amd64-{{ .Tag }}-alpine-3"
build_flag_templates:
- "--label=org.label-schema.schema-version=1.0"
- "--label=org.label-schema.version={{.Version}}"
- "--label=org.label-schema.name={{.ProjectName}}"
# -
# goos: linux
# goarch: arm
# goarm: 6
# binaries:
# - asws
# dockerfile: dockerfiles/arm/Dockerfile
# builds:
# - asws
# extra_files:
# - www
# - files
# image_templates:
# - "txn2/asws:armhf-latest"
# - "txn2/asws:armhf-{{ .Tag }}"
# - "txn2/asws:armhf-v{{ .Major }}"
# build_flag_templates:
# - "--label=org.label-schema.schema-version=1.0"
# - "--label=org.label-schema.version={{.Version}}"
# - "--label=org.label-schema.name={{.ProjectName}}"

0 comments on commit 490d59b

Please sign in to comment.