Skip to content

Commit a742b92

Browse files
authored
Merge pull request #106 from stackhpc/wallaby/libvirt_exporter_fix
prometheus-libvirt-exporter: fix build with newer Go
2 parents ba555b3 + 8a7b07c commit a742b92

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

docker/prometheus/prometheus-libvirt-exporter/Dockerfile.j2

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,8 +33,10 @@ ARG prometheus_libvirt_exporter_path=github.com/AlexZzz/libvirt-exporter
3333
{% block prometheus_libvirt_exporter_install %}
3434
ENV GOPATH=/build
3535
RUN go mod init libvirt-exporter \
36+
&& cd ${GOPATH} \
3637
&& go get -v ${prometheus_libvirt_exporter_path}@${prometheus_libvirt_exporter_version} \
37-
&& mv /build/bin/libvirt-exporter /opt \
38+
&& go build ${prometheus_libvirt_exporter_path} \
39+
&& mv /build/libvirt-exporter /opt \
3840
&& rm -rf /build
3941

4042
{% endblock %}

0 commit comments

Comments
 (0)