Skip to content

Commit

Permalink
PullRequest: 2 add aci
Browse files Browse the repository at this point in the history
Merge branch aci of [email protected]:Arc/kuberay.git into master
https://code.alipay.com/Arc/kuberay/pull_requests/2

Signed-off-by: 五花 <[email protected]>


* add aci

* fix aci

* fix aci

* fix aci

* fix aci

* fix aci

* fix aci

* fix aci

* fix aci

* fix aci

* fix aci

* fix aci

* fix aci

* fix aci

* fix aci

* fix aci

* fix aci

* fix aci

* fix aci

* fix aci

* fix aci

* fix aci

* fix aci

* fix aci

* fix aci

* fix aci

* fix aci

* fix aci

* test aci

* test

* test

* fix comment
  • Loading branch information
壮酱 authored and chenk008 committed Mar 8, 2022
1 parent d358916 commit 05cf36e
Show file tree
Hide file tree
Showing 3 changed files with 117 additions and 53 deletions.
33 changes: 33 additions & 0 deletions .aci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
version: "1.5"

stages:
- 代码检查

静态扫描:
stage: 代码检查
plugin: CMD
pluginConfig:
encoding: UTF-8
taskKind: CMD_GOLANGCI_LINT

构建Namespaced Controller镜像:
stage: 代码检查
plugin: ANT-BUILD
passEnv: true
pluginConfig:
image: reg.docker.alibaba-inc.com/antsigma/golang-dev:1.13.12
inputs:
params:
- name: DOCKERFILE
value: ./ray-operator/Dockerfile.manager
- name: DIRECTORY
value: ./ray-operator
outputs:
### TODO(user): modify to your image repo addr
### TODO(user): 镜像推送时,如遇到授权问题,请将账号admin.for.antb 添加授权并设置为读写权限之上;
### more info: https://yuque.antfin-inc.com/docs/share/786cf0fb-e070-4484-b7a8-979991f23af9#bc90917b
- name: "ray-operator-manager"
namespace: ray_deploy
repository: reg.docker.alibaba-inc.com
type: image
desc: "manager image of ray-operator"
31 changes: 31 additions & 0 deletions ray-operator/Dockerfile.manager
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
# cat Dockerfile_ant
# Build the manager binary
FROM reg.docker.alibaba-inc.com/antsigma/golang-dev:1.13.12 as builder

WORKDIR /go/src/github.com/ray-project/kuberay/ray-operator
# Copy the Go Modules manifests
COPY go.mod go.mod
COPY go.sum go.sum
# cache deps before building and copying source so that we don't need to re-download as much
# and so that source changes don't invalidate our downloaded layer
#RUN go mod download

# Copy the go source
COPY main.go main.go
COPY api/ api/
COPY controllers/ controllers/
COPY vendor/ vendor/

# Build
RUN CGO_ENABLED=0 GOOS=linux GOARCH=amd64 GO111MODULE=off go build -a -o manager main.go

# Use distroless as minimal base image to package the manager binary
# Refer to https://github.com/GoogleContainerTools/distroless for more details
FROM reg.docker.alibaba-inc.com/alibase/alios7u2-min
WORKDIR /
COPY --from=builder /go/src/github.com/ray-project/kuberay/ray-operator/manager .
USER 65532:65532

ENTRYPOINT ["/manager"]


Loading

0 comments on commit 05cf36e

Please sign in to comment.