mirror of https://github.com/milvus-io/milvus.git
[skip e2e]Try to fix mac build (#18522)
Signed-off-by: Jenny Li <jing.li@zilliz.com>pull/18497/head
parent
4a32c1bb8e
commit
f84d176989
|
@ -34,8 +34,6 @@ jobs:
|
|||
include:
|
||||
- name: Code Checker AMD64 Ubuntu 18.04
|
||||
os: ubuntu-18.04
|
||||
- name: Code Checker MacOS 11
|
||||
os: macos-11
|
||||
env:
|
||||
UBUNTU: 18.04
|
||||
steps:
|
||||
|
@ -55,22 +53,6 @@ jobs:
|
|||
path: .docker/thirdparty
|
||||
key: ubuntu18.04-thirdparty-${{ hashFiles('internal/core/thirdparty/**') }}
|
||||
restore-keys: ubuntu18.04-thirdparty-
|
||||
- name: Mac Cache Third Party
|
||||
if: ${{ matrix.os == 'macos-11' }}
|
||||
uses: actions/cache@v3
|
||||
with:
|
||||
path: |
|
||||
/tmp/thirdparty
|
||||
cmake_build/3rdparty_download/download
|
||||
key: macos-11-thirdparty-${{ hashFiles('internal/core/thirdparty/**') }}
|
||||
restore-keys: macos-11-thirdparty-
|
||||
- name: Mac Cache CCache Volumes
|
||||
if: ${{ matrix.os == 'macos-11' }}
|
||||
uses: actions/cache@v3
|
||||
with:
|
||||
path: /var/tmp/ccache
|
||||
key: macos-11-ccache-${{ hashFiles('internal/core/**') }}
|
||||
restore-keys: macos-11-ccache-
|
||||
- name: Cache Go Mod Volumes
|
||||
if: ${{ matrix.os == 'ubuntu-18.04' }}
|
||||
uses: actions/cache@v3
|
||||
|
@ -78,42 +60,12 @@ jobs:
|
|||
path: .docker/amd64-ubuntu18.04-go-mod
|
||||
key: ubuntu18.04-go-mod-${{ hashFiles('**/go.sum') }}
|
||||
restore-keys: ubuntu18.04-go-mod-
|
||||
- name: Setup Go environment
|
||||
uses: actions/setup-go@v2.2.0
|
||||
if: ${{ matrix.os == 'macos-11' }}
|
||||
with:
|
||||
go-version: '~1.17.1'
|
||||
- name: Mac Cache Go Mod Volumes
|
||||
if: ${{ matrix.os == 'macos-11' }}
|
||||
uses: actions/cache@v3
|
||||
with:
|
||||
path: ~/go/pkg/mod
|
||||
key: macos-11-go-mod-${{ hashFiles('**/go.sum') }}
|
||||
restore-keys: macos-11-go-mod-
|
||||
- name: Code Check
|
||||
if: ${{ matrix.os == 'ubuntu-18.04' }}
|
||||
env:
|
||||
CHECK_BUILDER: "1"
|
||||
run: |
|
||||
./build/builder.sh /bin/bash -c "make check-proto-product && make verifiers"
|
||||
- name: Code Check
|
||||
if: ${{ matrix.os == 'macos-11' }}
|
||||
env:
|
||||
CCACHE_DIR: /var/tmp/ccache
|
||||
CCACHE_COMPILERCHECK: content
|
||||
CCACHE_COMPRESS: 1
|
||||
CCACHE_COMPRESSLEVEL: 5
|
||||
CCACHE_MAXSIZE: 2G
|
||||
CUSTOM_THIRDPARTY_PATH: /tmp/thirdparty
|
||||
run: |
|
||||
if [[ ! -d "/var/tmp/ccache" ]];then
|
||||
mkdir -p /var/tmp/ccache
|
||||
fi
|
||||
brew install boost libomp ninja tbb openblas ccache
|
||||
if [[ ! -d "/usr/local/opt/llvm" ]]; then
|
||||
ln -s /usr/local/opt/llvm@13 /usr/local/opt/llvm
|
||||
fi
|
||||
make install && sh scripts/collect_arrow_dep.sh -f /tmp/thirdparty
|
||||
centos:
|
||||
name: Code Checker CentOS 7
|
||||
# Run in centos docker
|
||||
|
|
|
@ -0,0 +1,73 @@
|
|||
name: Code Checker
|
||||
|
||||
# This workflow is triggered on pushes or pull request to the repository.
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- master
|
||||
pull_request:
|
||||
# file paths to consider in the event. Optional; defaults to all.
|
||||
paths:
|
||||
- 'scripts/**'
|
||||
- 'internal/**'
|
||||
- 'cmd/**'
|
||||
- 'build/**'
|
||||
- '.github/workflows/mac.yaml'
|
||||
- '.env'
|
||||
- docker-compose.yml
|
||||
- Makefile
|
||||
- '!**.md'
|
||||
- '!build/ci/jenkins/**'
|
||||
# FIXME(wxyu): not need to run code check, update the ci-passed rules and remove these two lines
|
||||
- go.mod
|
||||
- go.sum
|
||||
|
||||
jobs:
|
||||
mac:
|
||||
name: Code Checker MacOS 12
|
||||
runs-on: macos-12
|
||||
timeout-minutes: 60
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v2
|
||||
- name: Mac Cache Third Party
|
||||
uses: actions/cache@v3
|
||||
with:
|
||||
path: |
|
||||
/tmp/thirdparty
|
||||
cmake_build/3rdparty_download/download
|
||||
key: macos-thirdparty-${{ hashFiles('internal/core/thirdparty/**') }}
|
||||
restore-keys: macos-thirdparty-
|
||||
- name: Mac Cache CCache Volumes
|
||||
uses: actions/cache@v3
|
||||
with:
|
||||
path: /var/tmp/ccache
|
||||
key: macos-ccache-${{ hashFiles('internal/core/**') }}
|
||||
restore-keys: macos-ccache-
|
||||
- name: Setup Go environment
|
||||
uses: actions/setup-go@v2.2.0
|
||||
with:
|
||||
go-version: '~1.18.1'
|
||||
- name: Mac Cache Go Mod Volumes
|
||||
uses: actions/cache@v3
|
||||
with:
|
||||
path: ~/go/pkg/mod
|
||||
key: macos-go-mod-${{ hashFiles('**/go.sum') }}
|
||||
restore-keys: macos-go-mod-
|
||||
- name: Code Check
|
||||
env:
|
||||
CCACHE_DIR: /var/tmp/ccache
|
||||
CCACHE_COMPILERCHECK: content
|
||||
CCACHE_COMPRESS: 1
|
||||
CCACHE_COMPRESSLEVEL: 5
|
||||
CCACHE_MAXSIZE: 2G
|
||||
CUSTOM_THIRDPARTY_PATH: /tmp/thirdparty
|
||||
run: |
|
||||
if [[ ! -d "/var/tmp/ccache" ]];then
|
||||
mkdir -p /var/tmp/ccache
|
||||
fi
|
||||
brew install boost libomp ninja tbb openblas ccache
|
||||
if [[ ! -d "/usr/local/opt/llvm" ]]; then
|
||||
ln -s /usr/local/opt/llvm@13 /usr/local/opt/llvm
|
||||
fi
|
||||
make milvus && sh scripts/collect_arrow_dep.sh -f /tmp/thirdparty
|
Loading…
Reference in New Issue