Skip to content

Commit 0e2d5d2

Browse files
committed
oppdatert jenkinsfile - bruker priv-docker.systemfabrikken.org:5000/base/golang-jenkins-bygg:go-1.7.3 for bygging da vi må jenkins lagt til som bruker
1 parent bb218a7 commit 0e2d5d2

File tree

3 files changed

+5
-7
lines changed

3 files changed

+5
-7
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,3 +4,4 @@
44
*-stamp
55
.idea
66
*.iml
7+
/build

Jenkinsfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,9 @@ node {
55
}
66

77
stage('kompiler og bygg distribusjon'){
8-
def byggimage = docker.image("golang:1.7.3")
8+
def byggimage = docker.image("priv-docker.systemfabrikken.org:5000/base/golang-jenkins-bygg:go-1.7.3'")
99
byggimage.inside("--name='$env.BUILD_TAG'") {
10-
sh 'go get -d'
10+
sh 'go get -d -v'
1111
sh 'go build -v -o build/prometheus-postgres-exporter'
1212
}
1313
archive 'build/prometheus-postgres-exporter'

README.md

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,8 @@ Supported Postgres versions: 9.1 and up.
55

66
## Building and running
77

8-
make
9-
export DATA_SOURCE_NAME="postgres://postgres:password@localhost/?sslmode=disable"
10-
./postgres_exporter <flags>
11-
12-
Or without make on a mac: `bash -c 'GO_ENABLED=0 GOOS=linux go build .' `
8+
On a mac: `bash -c 'GO_ENABLED=0 GOOS=linux go build .' `
9+
Or using build container: `docker run --rm -v "$PWD":/usr/src/prometheus-postgres-exporter -w /usr/src/prometheus-postgres-exporter golang:1.7.3 bash -c 'go get -d; go build -v -o build/prometheus-postgres-exporter'`
1310

1411
See the [github.com/lib/pq](http://github.com/lib/pq) module for other ways to format the connection string.
1512

0 commit comments

Comments
 (0)