Deployment and Makefile update

This commit is contained in:
Jakub Mikusek 2019-01-18 16:27:14 +01:00
parent c0ffeaebf8
commit 832cbf4aec
2 changed files with 7 additions and 10 deletions

View File

@ -149,12 +149,10 @@ e2e: build docker-build ## Runs e2e tests
cat deploy/role.yaml >> deploy/namespace-init.yaml
cat deploy/role_binding.yaml >> deploy/namespace-init.yaml
cat deploy/operator.yaml >> deploy/namespace-init.yaml
sed -i 's|REPLACE_IMAGE|$(REPO):$(GITCOMMIT)|g' deploy/namespace-init.yaml
sed -i 's|\(image:\).*|\1 $(REPO):$(GITCOMMIT)|g' deploy/namespace-init.yaml
ifeq ($(ENVIRONMENT),minikube)
sed -i 's|imagePullPolicy: IfNotPresent|imagePullPolicy: Never|g' deploy/namespace-init.yaml
sed -i 's|REPLACE_ARGS|args: ["--minikube"]|g' deploy/namespace-init.yaml
else
sed -i 's|REPLACE_ARGS||g' deploy/namespace-init.yaml
sed -i 's|\(imagePullPolicy\): IfNotPresent|\1: Never|g' deploy/namespace-init.yaml
sed -i 's|\(args:\).*|\1\ ["--minikube"\]|' deploy/namespace-init.yaml
endif
@RUNNING_TESTS=1 go test -parallel=1 "./test/e2e/" -tags "$(BUILDTAGS) cgo" -v -timeout 30m \
@ -331,7 +329,8 @@ bump-version: ## Bump the version in the version file. Set BUMP to [ patch | maj
echo $(NEW_VERSION) > VERSION.txt
@echo "Updating version from $(VERSION) to $(NEW_VERSION) in README.md"
sed -i s/$(VERSION)/$(NEW_VERSION)/g README.md
git add VERSION.txt README.md
sed -i s/$(VERSION)/$(NEW_VERSION)/g deploy/operator.yaml
git add VERSION.txt README.md deploy/operator.yaml
git commit -vaem "Bump version to $(NEW_VERSION)"
@echo "Run make tag to create and push the tag for new version $(NEW_VERSION)"

View File

@ -16,15 +16,13 @@ spec:
serviceAccountName: jenkins-operator
containers:
- name: jenkins-operator
# replace this with the built or official image
# image: virtuslab/jenkins-operator:latest
image: REPLACE_IMAGE
image: virtuslab/jenkins-operator:v0.0.3
ports:
- containerPort: 60000
name: metrics
command:
- jenkins-operator
REPLACE_ARGS
args: []
imagePullPolicy: IfNotPresent
env:
- name: WATCH_NAMESPACE