Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/jarppe/distroless-go
Minimal Docker HTTP server image in Go
https://github.com/jarppe/distroless-go
Last synced: about 2 months ago
JSON representation
Minimal Docker HTTP server image in Go
- Host: GitHub
- URL: https://github.com/jarppe/distroless-go
- Owner: jarppe
- Created: 2020-11-03T06:36:27.000Z (about 4 years ago)
- Default Branch: main
- Last Pushed: 2020-11-03T06:36:38.000Z (about 4 years ago)
- Last Synced: 2023-03-11T00:52:48.630Z (almost 2 years ago)
- Language: Go
- Size: 1000 Bytes
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Minimal Docker HTTP server image in Go
Purpose of this repo is to answer the question, _how small can minimal HTTP server be?_
## Show me
Build image:
```bash
$ just build
Sending build context to Docker daemon 22.02kB
Step 1/8 : FROM golang:1.15-buster as build-env
---> 4a581cd6feb1
...
```Run image in container:
```bash
$ just run
docker run --rm -p 8080:8080 distroless-go
```Does it work?
```bash
$ http :8080
HTTP/1.1 200 OK
Content-Length: 14
Content-Type: text/html; charset=utf-8
Date: Tue, 03 Nov 2020 06:33:33 GMTHello
```And the answer is...
```bash
$ docker image ls | grep distroless-go
distroless-go latest 1aa313d36a15 5 minutes ago 8.18MB
```