Skip to content

Commit

Permalink
Merge pull request #40 from spidernet-io/pr/welan/crd
Browse files Browse the repository at this point in the history
ew
  • Loading branch information
weizhoublue authored Oct 20, 2022
2 parents 4523d56 + 095766a commit 5111553
Show file tree
Hide file tree
Showing 5 changed files with 15 additions and 3 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/build-image-base.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ jobs:
echo "use re $ref , by workflow_dispatch"
echo "RUN_event_ref=${ref}" >> $GITHUB_ENV
echo "RUN_PUSH=true" >> $GITHUB_ENV
if ${{ github.event_name == 'pull_request_target' }} ; then
elif ${{ github.event_name == 'pull_request_target' }} ; then
#trigger by pr
echo "use sha ${{ github.event.pull_request.head.sha }} , by pr"
echo "RUN_event_ref=${{ github.event.pull_request.head.sha }}" >> $GITHUB_ENV
Expand Down
12 changes: 11 additions & 1 deletion .github/workflows/build-image-ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,20 @@ on:
permissions: write-all

jobs:
call-by:
call-by-workflow:
uses: ./.github/workflows/call-release-image.yaml
if: ${{ inputs.ref != '' }}
with:
ref: ${{ inputs.ref }}
push: "false"
race: "1"
secrets: inherit

call-by-pr:
uses: ./.github/workflows/call-release-image.yaml
if: ${{ github.event_name == 'pull_request_target' }}
with:
ref: ${{ github.event.pull_request.head.sha }}
push: "false"
race: "1"
secrets: inherit
1 change: 1 addition & 0 deletions images/agent/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -52,4 +52,5 @@ ENV ENV_VERSION=${VERSION}

COPY --from=builder /tmp/install/${TARGETOS}/${TARGETARCH}/bin/* /usr/bin/

#====modify====
CMD ["/usr/bin/agent"]
1 change: 0 additions & 1 deletion images/controller-base/build-gops.sh
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,5 @@ for arch in amd64 arm64 ; do
GOARCH="${arch}" CGO_ENABLED=0 go build -ldflags "-s -w" -o "/out/linux/${arch}/bin/gops" github.com/google/gops
done


x86_64-linux-gnu-strip /out/linux/amd64/bin/gops
aarch64-linux-gnu-strip /out/linux/arm64/bin/gops
2 changes: 2 additions & 0 deletions images/controller/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -52,4 +52,6 @@ ENV ENV_VERSION=${VERSION}

COPY --from=builder /tmp/install/${TARGETOS}/${TARGETARCH}/bin/* /usr/bin/

#====modify====
CMD ["/usr/bin/controller"]

0 comments on commit 5111553

Please sign in to comment.