Skip to content

Commit 3283763

Browse files
committed
DEVOPS-272 add Jenkinsfile, Makefile
1 parent 07eba4d commit 3283763

File tree

2 files changed

+43
-0
lines changed

2 files changed

+43
-0
lines changed

Jenkinsfile

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
label = "${UUID.randomUUID().toString()}"
2+
git_project = "spark-ui-proxy"
3+
git_project_user = "v3io"
4+
git_project_upstream_user = "v3io"
5+
git_deploy_user = "iguazio-prod-git-user"
6+
git_deploy_user_token = "iguazio-prod-git-user-token"
7+
git_deploy_user_private_key = "iguazio-prod-git-user-private-key"
8+
9+
podTemplate(label: "${git_project}-${label}", inheritFrom: "jnlp-docker-golang") {
10+
node("${git_project}-${label}") {
11+
pipelinex = library(identifier: 'pipelinex@refs', retriever: modernSCM(
12+
[$class : 'GitSCMSource',
13+
credentialsId: git_deploy_user_private_key,
14+
remote : "git@github.com:iguazio/pipelinex.git"])).com.iguazio.pipelinex
15+
common.notify_slack {
16+
withCredentials([
17+
string(credentialsId: git_deploy_user_token, variable: 'GIT_TOKEN')
18+
]) {
19+
github.release(git_deploy_user, git_project, git_project_user, git_project_upstream_user, true, GIT_TOKEN) {
20+
stage("build ${git_project} in dood") {
21+
container('docker-cmd') {
22+
dir("${github.BUILD_FOLDER}/src/github.com/${git_project_upstream_user}/${git_project}") {
23+
common.shellc("SPARK_UI_PROXY_TAG=${github.DOCKER_TAG_VERSION} SPARK_UI_PROXY_REPOSITORY='' make build")
24+
}
25+
}
26+
}
27+
28+
stage('push') {
29+
container('docker-cmd') {
30+
dockerx.images_push_multi_registries(["${git_project}:${github.DOCKER_TAG_VERSION}"], [pipelinex.DockerRepo.ARTIFACTORY_IGUAZIO, pipelinex.DockerRepo.DOCKER_HUB, pipelinex.DockerRepo.QUAY_IO])
31+
}
32+
}
33+
}
34+
}
35+
}
36+
}
37+
}

Makefile

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
SPARK_UI_PROXY_TAG ?= latest
2+
SPARK_UI_PROXY_REPOSITORY ?= v3io/
3+
4+
.PHONY: build
5+
build:
6+
docker build --tag=$(SPARK_UI_PROXY_REPOSITORY)spark-ui-proxy:$(SPARK_UI_PROXY_TAG) .

0 commit comments

Comments
 (0)