-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore: Jmeter build into action (#113)
* build: add jmeter build to workflow * build: move the base image to artifact repo * chore: a simple script for moving the images from old gcr registry to new artifact repo * fix: move the auth file to secret * fix: move the engine agent config into configmap * chore: update some comments to explain the logic * fix: deal with nil config * fix: running image should have ca
- Loading branch information
Showing
13 changed files
with
121 additions
and
56 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,31 +1,18 @@ | ||
ARG jmeter_ver=3.3 | ||
|
||
FROM gcr.io/shibuya-214807/alpine:3.10.2 AS jmeter | ||
FROM asia-northeast1-docker.pkg.dev/shibuya-214807/shibuya/alpine:3.10.2 AS jmeter | ||
ARG jmeter_ver | ||
ENV JMETER_VERSION=$jmeter_ver | ||
RUN wget archive.apache.org/dist/jmeter/binaries/apache-jmeter-${JMETER_VERSION}.zip | ||
RUN unzip -qq apache-jmeter-${JMETER_VERSION} | ||
|
||
FROM gcr.io/shibuya-214807/golang:1.13.6-stretch AS shibuya-agent | ||
WORKDIR /go/src/shibuya | ||
ENV GO111MODULE on | ||
ADD go.mod . | ||
ADD go.sum . | ||
RUN go mod download | ||
|
||
COPY . /go/src/shibuya | ||
RUN GOOS=linux GOARCH=amd64 CGO_ENABLED=0 go build -o /go/bin/shibuya-agent /go/src/shibuya/engines/jmeter | ||
|
||
FROM gcr.io/shibuya-214807/openjdk:8u212-jdk | ||
FROM asia-northeast1-docker.pkg.dev/shibuya-214807/shibuya/openjdk:8u212-jdk | ||
ARG jmeter_ver | ||
ENV JMETER_VERSION=$jmeter_ver | ||
RUN mkdir /test-conf /test-result | ||
COPY --from=jmeter /apache-jmeter-${JMETER_VERSION} /apache-jmeter-${JMETER_VERSION} | ||
COPY --from=shibuya-agent /go/bin/shibuya-agent /usr/local/bin/shibuya-agent | ||
COPY config.json config.json | ||
ADD build/shibuya-agent /usr/local/bin/shibuya-agent | ||
ADD engines/jmeter/shibuya.properties /test-conf/shibuya.properties | ||
ADD engines/jmeter/jmeter.sh /apache-jmeter-${JMETER_VERSION}/bin/jmeter | ||
RUN mkdir /auth | ||
ADD ./shibuya-gcp.json /auth/shibuya-gcp.json | ||
ENV GOOGLE_APPLICATION_CREDENTIALS /auth/shibuya-gcp.json | ||
CMD ["shibuya-agent"] | ||
|
||
CMD ["shibuya-agent"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
#!/bin/bash | ||
|
||
new_registry=asia-northeast1-docker.pkg.dev/shibuya-214807/shibuya | ||
old_registry=gcr.io/shibuya-214807 | ||
|
||
component=$1 | ||
old_image=$old_registry/$component | ||
new_image=$new_registry/$component | ||
docker pull $old_image | ||
docker tag $old_image $new_image | ||
docker push $new_image |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters