Skip to content

Commit

Permalink
Update go version and container (#4)
Browse files Browse the repository at this point in the history
  • Loading branch information
niu789 authored Jan 11, 2023
1 parent c79ed95 commit a05ffe1
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 7 deletions.
6 changes: 2 additions & 4 deletions .envrc
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
watch_file .tool-versions

use asdf
asdf_has golang || asdf plugin-add golang
asdf install

layout go
asdf install | sed '/is already installed/d'
use asdf
2 changes: 1 addition & 1 deletion .tool-versions
Original file line number Diff line number Diff line change
@@ -1 +1 @@
golang 1.17.2
golang 1.19.4
4 changes: 3 additions & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM golang:1.17-alpine as builder
FROM golang:1.19-alpine as builder

RUN apk update && apk add \
git \
Expand All @@ -13,6 +13,8 @@ RUN CGO_ENABLED=0 GOOS=linux go build -a -installsuffix cgo -ldflags="-w -s" -o

FROM alpine:3

RUN apk -U --no-cache upgrade

COPY --from=builder /go/bin/docker_state_exporter /go/bin/docker_state_exporter

EXPOSE 8080
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ TODO: Allow for polling interval customization.
```bash
git clone https://github.com/AdaptiveConsulting/docker_state_exporter
cd docker_state_exporter
docker build .
docker build . -t docker_state_exporter_test
```

### Run
Expand Down

0 comments on commit a05ffe1

Please sign in to comment.