Skip to content

Commit

Permalink
enha: integration testing
Browse files Browse the repository at this point in the history
  • Loading branch information
veezhang committed May 19, 2023
1 parent 9f55c86 commit f598566
Show file tree
Hide file tree
Showing 44 changed files with 1,277 additions and 142 deletions.
16 changes: 10 additions & 6 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ on:
branches:
- 'master'
tags:
- 'v*'
- 'v[0-9]+.[0-9]+.[0-9]+*'

permissions:
contents: write
Expand All @@ -27,27 +27,31 @@ jobs:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- uses: actions/setup-go@v3
- uses: actions/setup-go@v4
with:
go-version: 1.19
cache: true
- run: |
go env -w GOFLAGS=-buildvcs=false
git config --global --add safe.directory $(pwd)
- run: |
curl -L "https://github.com/docker/compose/releases/download/1.29.2/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose
chmod +x /usr/local/bin/docker-compose
- run: make lint
- run: make test
- run: make test-it # integration-testing
- uses: codecov/codecov-action@v2
- uses: docker/login-action@v1
if: success() && startsWith(github.ref, 'refs/tags/')
with:
registry: ${{ secrets.HARBOR_REGISTRY }}
username: ${{ secrets.HARBOR_USERNAME }}
password: ${{ secrets.HARBOR_PASSWORD }}
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
- uses: goreleaser/goreleaser-action@v2
if: success() && startsWith(github.ref, 'refs/tags/')
with:
version: latest
distribution: goreleaser
args: release --rm-dist
env:
GORELEASER_CURRENT_TAG: ${{ github.ref_name }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
DOCKER_IMAGE_REPO: vesoft/
38 changes: 28 additions & 10 deletions .goreleaser.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -41,17 +41,17 @@ archives:
386: i386
amd64: x86_64
files:
- README.md
- none* # https://goreleaser.com/customization/archive/?h=archives#packaging-only-the-binaries
format_overrides:
- goos: windows
format: zip

dockers:
- &dockers
image_templates:
- "reg.vesoft-inc.com/vesoft-ent/{{ .ProjectName }}:{{ .Version }}-amd64"
- "{{ .Env.DOCKER_IMAGE_REPO }}{{ .ProjectName }}:{{ .Tag }}-amd64"
use: buildx
dockerfile: Dockerfile.goreleaser
dockerfile: Dockerfile
build_flag_templates:
- "--platform=linux/amd64"
- "--pull"
Expand All @@ -64,7 +64,7 @@ dockers:
- "--label=org.opencontainers.image.revision={{ .FullCommit }}"
- <<: *dockers
image_templates:
- "reg.vesoft-inc.com/vesoft-ent/{{ .ProjectName }}:{{ .Version }}-armv7"
- "{{ .Env.DOCKER_IMAGE_REPO }}{{ .ProjectName }}:{{ .Tag }}-armv7"
goarch: arm
goarm: 7
build_flag_templates:
Expand All @@ -79,7 +79,7 @@ dockers:
- "--label=org.opencontainers.image.revision={{ .FullCommit }}"
- <<: *dockers
image_templates:
- "reg.vesoft-inc.com/vesoft-ent/{{ .ProjectName }}:{{ .Version }}-arm64v8"
- "{{ .Env.DOCKER_IMAGE_REPO }}{{ .ProjectName }}:{{ .Tag }}-arm64v8"
goarch: arm64
build_flag_templates:
- "--platform=linux/arm64/v8"
Expand All @@ -93,13 +93,31 @@ dockers:
- "--label=org.opencontainers.image.revision={{ .FullCommit }}"
docker_manifests:
- &docker_manifests
name_template: "reg.vesoft-inc.com/vesoft-ent/{{ .ProjectName }}:latest"
name_template: "{{ .Env.DOCKER_IMAGE_REPO }}{{ .ProjectName }}:{{ .Tag }}"
image_templates:
- "reg.vesoft-inc.com/vesoft-ent/{{ .ProjectName }}:{{ .Version }}-amd64"
- "reg.vesoft-inc.com/vesoft-ent/{{ .ProjectName }}:{{ .Version }}-armv7"
- "reg.vesoft-inc.com/vesoft-ent/{{ .ProjectName }}:{{ .Version }}-arm64v8"
- "{{ .Env.DOCKER_IMAGE_REPO }}{{ .ProjectName }}:{{ .Tag }}-amd64"
- "{{ .Env.DOCKER_IMAGE_REPO }}{{ .ProjectName }}:{{ .Tag }}-armv7"
- "{{ .Env.DOCKER_IMAGE_REPO }}{{ .ProjectName }}:{{ .Tag }}-arm64v8"
- <<: *docker_manifests
name_template: "reg.vesoft-inc.com/vesoft-ent/{{ .ProjectName }}:{{ .Version }}"
name_template: "{{ .Env.DOCKER_IMAGE_REPO }}{{ .ProjectName }}:v{{ .Major }}"
skip_push: auto
image_templates:
- "{{ .Env.DOCKER_IMAGE_REPO }}{{ .ProjectName }}:{{ .Tag }}-amd64"
- "{{ .Env.DOCKER_IMAGE_REPO }}{{ .ProjectName }}:{{ .Tag }}-armv7"
- "{{ .Env.DOCKER_IMAGE_REPO }}{{ .ProjectName }}:{{ .Tag }}-arm64v8"
- <<: *docker_manifests
name_template: "{{ .Env.DOCKER_IMAGE_REPO }}{{ .ProjectName }}:v{{ .Major }}.{{ .Minor }}"
skip_push: auto
image_templates:
- "{{ .Env.DOCKER_IMAGE_REPO }}{{ .ProjectName }}:{{ .Tag }}-amd64"
- "{{ .Env.DOCKER_IMAGE_REPO }}{{ .ProjectName }}:{{ .Tag }}-armv7"
- "{{ .Env.DOCKER_IMAGE_REPO }}{{ .ProjectName }}:{{ .Tag }}-arm64v8"
- <<: *docker_manifests
name_template: "{{ .Env.DOCKER_IMAGE_REPO }}{{ .ProjectName }}:latest"
image_templates:
- "{{ .Env.DOCKER_IMAGE_REPO }}{{ .ProjectName }}:{{ .Tag }}-amd64"
- "{{ .Env.DOCKER_IMAGE_REPO }}{{ .ProjectName }}:{{ .Tag }}-armv7"
- "{{ .Env.DOCKER_IMAGE_REPO }}{{ .ProjectName }}:{{ .Tag }}-arm64v8"

nfpms:
- file_name_template: '{{ .ConventionalFileName }}'
Expand Down
23 changes: 3 additions & 20 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,24 +1,7 @@
FROM reg.vesoft-inc.com/ci/golang:1.18-alpine AS builder

LABEL stage=gobuilder

ENV CGO_ENABLED 0
ENV GOOS linux
WORKDIR /build/zero

ADD go.mod .
ADD go.sum .
COPY pkg pkg
COPY cmd cmd
RUN go mod download

RUN go build -ldflags="-s -w" -o /usr/bin/nebula-importer ./cmd/nebula-importer

FROM reg.vesoft-inc.com/ci/alpine
FROM reg.vesoft-inc.com/proxy/library/alpine

RUN apk update --no-cache && apk add --no-cache ca-certificates tzdata
ENV TZ Asia/Shanghai

COPY --from=builder /usr/bin/nebula-importer /usr/bin/nebula-importer
ADD nebula-importer /usr/local/bin/nebula-importer

ENTRYPOINT ["/usr/bin/nebula-importer"]
ENTRYPOINT ["/usr/local/bin/nebula-importer"]
3 changes: 3 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,9 @@ build:
test:
go test -gcflags=all="-l" -race -coverprofile=coverage.txt -covermode=atomic ./pkg/...

test-it: # integration-testing
docker-compose -f integration-testing/docker-compose.yaml up --build --exit-code-from importer

docker-build:
docker build -t "${DOCKER_REPO}/nebula-importer:${IMAGE_TAG}" -f Dockerfile .

Expand Down
46 changes: 30 additions & 16 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,17 @@ $ go install github.com/vesoft-inc/nebula-importer/cmd/nebula-importer@latest
### From docker

```shell
$ docker pull vesoft/nebula-importer
$ docker run -it -v <path-to-config>:/config.yaml --rm vesoft/nebula-importer -c /config.yaml
$ docker pull vesoft/nebula-importer:<version>
$ docker run --rm -ti \
--network=host \
-v <config_file>:<config_file> \
-v <data_dir>:<data_dir> \
vesoft/nebula-importer:<version>
--config <config_file>

# config_file: the absolute path to the configuration file.
# data_dir: the absolute path to the data directory, ignore if not a local file.
# version: the version of Nebula Importer.
```

### From Source Code
Expand Down Expand Up @@ -100,14 +109,19 @@ client:
hooks:
before:
- statements:
- statements1
- statements2
wait: 10s
- UPDATE CONFIGS storage:wal_ttl=3600;
- UPDATE CONFIGS storage:rocksdb_column_family_options = { disable_auto_compactions = true };
- statements:
- statements3
- |
DROP SPACE IF EXISTS basic_int_examples;
CREATE SPACE IF NOT EXISTS basic_int_examples(partition_num=5, replica_factor=1, vid_type=int);
USE basic_int_examples;
wait: 10s
after:
- statements:
- statements4
- |
UPDATE CONFIGS storage:wal_ttl=86400;
UPDATE CONFIGS storage:rocksdb_column_family_options = { disable_auto_compactions = false };
```

* `manager.spaceName`: **Required**. Specifies which space the data is imported into.
Expand All @@ -132,7 +146,7 @@ log:
- logs/nebula-importer.log
```

* `log.level`: **Optional**. Specifies the log level. The default value is `INFO`.
* `log.level`: **Optional**. Specifies the log level, optional values is `DEBUG`, `INFO`, `WARN`, `ERROR`, `PANIC` or `FATAL`. The default value is `INFO`.
* `log.console`: **Optional**. Specifies whether to print logs to the console. The default value is `true`.
* `log.files`: **Optional**. Specifies which files to print logs to.

Expand Down Expand Up @@ -168,16 +182,16 @@ s3:
region: <region>
bucket: <bucket>
key: <key>
accessKey: <accessKey>
secretKey: <secretKey>
accessKeyID: <Access Key ID>
accessKeySecret: <Access Key Secret>
```

* `endpoint`: **Optional**. The endpoint of s3 service, can be omitted if using aws s3.
* `region`: **Required**. The region of s3 service.
* `bucket`: **Required**. The bucket of file in s3 service.
* `key`: **Required**. The object key of file in s3 service.
* `accessKey`: **Optional**. The access key of s3 service. If it is public data, no need to configure.
* `secretKey`: **Optional**. The secret key of s3 service. If it is public data, no need to configure.
* `accessKeyID`: **Optional**. The `Access Key ID` of s3 service. If it is public data, no need to configure.
* `accessKeySecret`: **Optional**. The `Access Key Secret` of s3 service. If it is public data, no need to configure.

#### oss

Expand All @@ -188,15 +202,15 @@ oss:
endpoint: <endpoint>
bucket: <bucket>
key: <key>
accessKey: <accessKey>
secretKey: <secretKey>
accessKeyID: <Access Key ID>
accessKeySecret: <Access Key Secret>
```

* `endpoint`: **Required**. The endpoint of oss service.
* `bucket`: **Required**. The bucket of file in oss service.
* `key`: **Required**. The object key of file in oss service.
* `accessKey`: **Required**. The access key of oss service.
* `secretKey`: **Required**. The secret key of oss service.
* `accessKeyID`: **Required**. The `Access Key ID` of oss service.
* `accessKeySecret`: **Required**. The `Access Key Secret` of oss service.

#### ftp

Expand Down
8 changes: 4 additions & 4 deletions docs/configuration-reference.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,13 +36,13 @@
| sources[].s3.region | The region of s3 service. | - |
| sources[].s3.bucket | The bucket of file in s3 service. | - |
| sources[].s3.key | The object key of file in s3 service. | - |
| sources[].s3.accessKey | The access key of s3 service. | - |
| sources[].s3.secretKey | The secret key of s3 service. | - |
| sources[].s3.accessKeyID | The `Access Key ID` of s3 service. | - |
| sources[].s3.accessKeySecret | The `Access Key Secret` of s3 service. | - |
| sources[].oss.endpoint | The endpoint of oss service. | - |
| sources[].oss.bucket | The bucket of file in oss service. | - |
| sources[].oss.key | The object key of file in oss service. | - |
| sources[].oss.accessKey | The access key of oss service. | - |
| sources[].oss.secretKey | The secret key of oss service. | - |
| sources[].oss.accessKeyID | The `Access Key ID` of oss service. | - |
| sources[].oss.accessKeySecret | The `Access Key Secret` of oss service. | - |
| sources[].ftp.host | The host of ftp service. | - |
| sources[].ftp.host | The port of ftp service. | - |
| sources[].ftp.user | The user of ftp service. | - |
Expand Down
8 changes: 4 additions & 4 deletions examples/oss/oss.v3.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -32,10 +32,10 @@ log:
sources:
- oss:
endpoint: https://oss-cn-hangzhou.aliyuncs.com
bucket: bucketName
key: objectKey
accessKey: accessKey
secretKey: secretKey
bucket: bucket-name
key: object-key
accessKeyID: "Access Key ID"
accessKeySecret: "Access Key Secret"
csv:
delimiter: "\t"
tags:
Expand Down
8 changes: 4 additions & 4 deletions examples/s3/s3.v3.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,8 @@ sources:
region: us-east-1
bucket: gdelt-open-data
key: events/20190918.export.csv
# accessKey: ""
# secretKey: ""
# accessKeyID: ""
# accessKeySecret: ""
csv:
delimiter: "\t"
tags:
Expand All @@ -52,8 +52,8 @@ sources:
region: us-east-1
bucket: gdelt-open-data
key: events/20190918.export.csv
accessKey: "accessKey"
secretKey: "secretKey"
accessKeyID: "Access Key ID"
accessKeySecret: "Access Key Secret"
csv:
delimiter: "\t"
tags:
Expand Down
8 changes: 4 additions & 4 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ require (
github.com/spf13/afero v1.9.3
github.com/spf13/cobra v1.6.1
github.com/valyala/bytebufferpool v1.0.0
github.com/vesoft-inc/nebula-go/v3 v3.3.1
github.com/vesoft-inc/nebula-go/v3 v3.5.0
go.uber.org/zap v1.23.0
golang.org/x/crypto v0.5.0
gopkg.in/yaml.v3 v3.0.1
Expand All @@ -47,9 +47,9 @@ require (
github.com/spf13/pflag v1.0.5 // indirect
go.uber.org/atomic v1.7.0 // indirect
go.uber.org/multierr v1.6.0 // indirect
golang.org/x/net v0.5.0 // indirect
golang.org/x/sys v0.4.0 // indirect
golang.org/x/text v0.6.0 // indirect
golang.org/x/net v0.10.0 // indirect
golang.org/x/sys v0.8.0 // indirect
golang.org/x/text v0.9.0 // indirect
golang.org/x/time v0.3.0 // indirect
google.golang.org/protobuf v1.28.1 // indirect
gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c // indirect
Expand Down
18 changes: 9 additions & 9 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -226,8 +226,8 @@ github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/
github.com/stretchr/testify v1.8.1 h1:w7B6lhMri9wdJUVmEZPGGhZzrYTPvgJArz7wNPgYKsk=
github.com/valyala/bytebufferpool v1.0.0 h1:GqA5TC/0021Y/b9FG4Oi9Mr3q7XYx6KllzawFIhcdPw=
github.com/valyala/bytebufferpool v1.0.0/go.mod h1:6bBcMArwyJ5K/AmCkWv1jt77kVWyCJ6HpOuEn7z0Csc=
github.com/vesoft-inc/nebula-go/v3 v3.3.1 h1:5DxUxswEQvK9gkK6Y/X4fhX+bmIeHIJrn+b2q7tE3HM=
github.com/vesoft-inc/nebula-go/v3 v3.3.1/go.mod h1:+sXv05jYQBARdTbTcIEsWVXCnF/6ttOlDK35xQ6m54s=
github.com/vesoft-inc/nebula-go/v3 v3.5.0 h1:2ZSkoBxtIfs15AXJXqrAPDPd0Z9HrzKR7YKXPqlJcR0=
github.com/vesoft-inc/nebula-go/v3 v3.5.0/go.mod h1:+sXv05jYQBARdTbTcIEsWVXCnF/6ttOlDK35xQ6m54s=
github.com/yuin/goldmark v1.1.25/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74=
github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74=
github.com/yuin/goldmark v1.1.32/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74=
Expand Down Expand Up @@ -329,8 +329,8 @@ golang.org/x/net v0.0.0-20210405180319-a5a99cb37ef4/go.mod h1:p54w0d4576C0XHj96b
golang.org/x/net v0.0.0-20211112202133-69e39bad7dc2/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
golang.org/x/net v0.0.0-20220722155237-a158d28d115b/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c=
golang.org/x/net v0.1.0/go.mod h1:Cx3nUiGt4eDBEyega/BKRp+/AlGL8hYe7U9odMt2Cco=
golang.org/x/net v0.5.0 h1:GyT4nK/YDHSqa1c4753ouYCDajOYKTja9Xb/OHtgvSw=
golang.org/x/net v0.5.0/go.mod h1:DivGGAXEgPSlEBzxGzZI+ZLohi+xUj054jfeKui00ws=
golang.org/x/net v0.10.0 h1:X2//UzNDwYmtCLn7To6G58Wr6f5ahEAQgKNzv9Y951M=
golang.org/x/net v0.10.0/go.mod h1:0qNGK6F8kojg2nk9dLZ2mShWaEBan6FAoqfSigmmuDg=
golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U=
golang.org/x/oauth2 v0.0.0-20190226205417-e64efc72b421/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw=
golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw=
Expand Down Expand Up @@ -393,12 +393,12 @@ golang.org/x/sys v0.0.0-20211216021012-1d35b9e2eb4e/go.mod h1:oPkhp1MJrh7nUepCBc
golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20220722155257-8c9f86f7a55f/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.1.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.4.0 h1:Zr2JFtRQNX3BCZ8YtxRE9hNJYC8J6I1MVbMg6owUp18=
golang.org/x/sys v0.4.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.8.0 h1:EBmGv8NaZBZTWvrbjNoL6HVt+IVy3QDQpJs7VRIw3tU=
golang.org/x/sys v0.8.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo=
golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8=
golang.org/x/term v0.1.0/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8=
golang.org/x/term v0.4.0 h1:O7UWfv5+A2qiuulQk30kVinPoMtoIPeVaKLEgLpVkvg=
golang.org/x/term v0.8.0 h1:n5xxQn2i3PC0yLAbjTpNT85q/Kgzcr2gIoX9OrJUols=
golang.org/x/text v0.0.0-20170915032832-14c0d48ead0c/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
golang.org/x/text v0.3.1-0.20180807135948-17ff2d5776d2/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
Expand All @@ -408,8 +408,8 @@ golang.org/x/text v0.3.4/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ=
golang.org/x/text v0.3.6/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ=
golang.org/x/text v0.3.7/go.mod h1:u+2+/6zg+i71rQMx5EYifcz6MCKuco9NR6JIITiCfzQ=
golang.org/x/text v0.4.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8=
golang.org/x/text v0.6.0 h1:3XmdazWV+ubf7QgHSTWeykHOci5oeekaGJBLkrkaw4k=
golang.org/x/text v0.6.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8=
golang.org/x/text v0.9.0 h1:2sjJmO8cDvYveuX97RDLsxlyUxLl+GHoLxBiRdHllBE=
golang.org/x/text v0.9.0/go.mod h1:e1OnstbJyHTd6l/uOt8jFFHp6TRDWZR/bV3emEE/zU8=
golang.org/x/time v0.0.0-20181108054448-85acf8d2951c/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ=
golang.org/x/time v0.0.0-20190308202827-9d24e82272b4/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ=
golang.org/x/time v0.0.0-20191024005414-555d28b269f0/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ=
Expand Down
16 changes: 16 additions & 0 deletions integration-testing/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
FROM reg.vesoft-inc.com/proxy/library/golang:1.19-alpine

LABEL stage=gobuilder

ENV CGO_ENABLED 0
ENV GOOS linux
WORKDIR /build/zero

RUN go install github.com/vesoft-inc/nebula-console@latest

ADD . .

RUN go mod download
RUN go build -ldflags="-s -w" -o /usr/bin/nebula-importer ./cmd/nebula-importer

ENTRYPOINT ["sh", "-c"]
Loading

0 comments on commit f598566

Please sign in to comment.