Skip to content

Commit

Permalink
This is a PR
Browse files Browse the repository at this point in the history
  • Loading branch information
Viktor Farcic committed Feb 11, 2020
1 parent b98eb33 commit 22de5ca
Show file tree
Hide file tree
Showing 6 changed files with 13 additions and 5 deletions.
2 changes: 1 addition & 1 deletion charts/go-demo-6/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ ifeq ($(OS),Darwin)
sed -i "" -e "s/tag:.*/tag: $(VERSION)/" values.yaml
else ifeq ($(OS),Linux)
sed -i -e "s/version:.*/version: $(VERSION)/" Chart.yaml
sed -i -e "s|repository:.*|repository: $(DOCKER_REGISTRY)\/devops-26\/$(NAME)|" values.yaml
sed -i -e "s|repository:.*|repository: $(DOCKER_REGISTRY)\/devops-27\/$(NAME)|" values.yaml
sed -i -e "s/tag:.*/tag: $(VERSION)/" values.yaml
else
echo "platfrom $(OS) not supported to tag with"
Expand Down
2 changes: 1 addition & 1 deletion charts/preview/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ ifeq ($(OS),Darwin)
else ifeq ($(OS),Linux)
sed -i -e "s/version:.*/version: $(PREVIEW_VERSION)/" Chart.yaml
sed -i -e "s/version:.*/version: $(PREVIEW_VERSION)/" ../*/Chart.yaml
sed -i -e "s|repository:.*|repository: $(DOCKER_REGISTRY)\/devops-26\/go-demo-6|" values.yaml
sed -i -e "s|repository:.*|repository: $(DOCKER_REGISTRY)\/devops-27\/go-demo-6|" values.yaml
sed -i -e "s/tag:.*/tag: $(PREVIEW_VERSION)/" values.yaml
else
echo "platfrom $(OS) not supported to release from"
Expand Down
8 changes: 8 additions & 0 deletions charts/preview/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,3 +21,11 @@ preview:
tag:
pullPolicy: IfNotPresent
probePath: /demo/hello?health=true


db:
enabled: false

preview-db:
persistence:
enabled: false
2 changes: 1 addition & 1 deletion main.go
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ func HelloServer(w http.ResponseWriter, req *http.Request) {
delayNum, _ := strconv.Atoi(delay)
sleep(time.Duration(delayNum) * time.Millisecond)
}
io.WriteString(w, "hello, devpod with tests!\n")
io.WriteString(w, "hello, PR!\n")
}

func RandomErrorServer(w http.ResponseWriter, req *http.Request) {
Expand Down
2 changes: 1 addition & 1 deletion main_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ func (s *MainTestSuite) Test_HelloServer_WritesHelloWorld() {

HelloServer(w, req)

w.AssertCalled(s.T(), "Write", []byte("hello, devpod with tests!\n"))
w.AssertCalled(s.T(), "Write", []byte("hello, PR!\n"))
}

func (s *MainTestSuite) Test_HelloServer_Waits_WhenDelayIsPresent() {
Expand Down
2 changes: 1 addition & 1 deletion skaffold.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ apiVersion: skaffold/v1beta2
kind: Config
build:
artifacts:
- image: devops-26/go-demo-6
- image: devops-27/go-demo-6
context: .
docker: {}
tagPolicy:
Expand Down

0 comments on commit 22de5ca

Please sign in to comment.