Test secrets in workflow [Do not merge] #30
Workflow file for this run
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
name: pull_request | |
on: | |
pull_request: | |
branches: | |
- 'master' | |
concurrency: | |
group: ${{ github.head_ref }} | |
cancel-in-progress: true | |
defaults: | |
run: | |
shell: bash | |
jobs: | |
build_and_upload: | |
runs-on: | |
- self-hosted | |
- ${{ matrix.arch }} | |
strategy: | |
fail-fast: false | |
matrix: | |
os: | |
- centos7 | |
- centos8 | |
#- ubuntu1604 | |
#- ubuntu1804 | |
- ubuntu2004 | |
- ubuntu2204 | |
#- ubuntu2304 | |
compiler: | |
- 9.3.0 | |
- '' | |
arch: | |
- x64 | |
- arm64 | |
exclude: | |
- os: centos7 | |
compiler: '' | |
- os: ubuntu2204 | |
compiler: '9.3.0' | |
- os: ubuntu2304 | |
compiler: '9.3.0' | |
container: | |
image: vesoft/third-party-build:${{ matrix.os }} | |
steps: | |
- uses: webiny/[email protected] | |
with: | |
run: sh -c "find . -mindepth 1 -delete" | |
- uses: actions/checkout@v3 | |
- name: Set up environment | |
if: matrix.compiler != '' | |
run: | | |
export URL=https://raw.githubusercontent.com/vesoft-inc/nebula-gears/master/install | |
bash <(curl -Ls $URL) | |
install-gcc --version=${{ matrix.compiler }} | |
echo "COMPILER_VERSION=${{ matrix.compiler }}" >> $GITHUB_ENV | |
- name: Pre-Build | |
env: | |
URL: ${{ secrets.MINIO_ENDPOINT }} | |
KEY: ${{ secrets.MINIO_KEY }} | |
SECRET: ${{ secrets.MINIO_SECRET }} | |
run: | | |
echo "test echo ${{ env.URL }}" | |
echo "test echo ${{ env.KEY }}" | |
echo "test echo ${{ env.SECRET }}" | |
echo "path=$(pwd)" >> $GITHUB_ENV | |
cd .. | |
if [ -d "build" ]; then | |
find build -maxdepth 1 -mindepth 1 ! -name '*.tgz' -exec rm -rf {} + | |
else | |
mkdir build | |
fi | |
sync | |
- name: Build | |
run: | | |
if [[ -n "${{ matrix.compiler }}" ]]; then | |
export TOOLSET_GCC_DIR=/opt/vesoft/toolset/gcc/${{ matrix.compiler }} | |
export CC=${TOOLSET_GCC_DIR}/bin/gcc | |
export CXX=${TOOLSET_GCC_DIR}/bin/g++ | |
export PATH=${TOOLSET_GCC_DIR}/bin:${PATH} | |
export LD_LIBRARY_PATH=${TOOLSET_GCC_DIR}/lib64:$LD_LIBRARY_PATH | |
fi | |
#build_package=1 ${{ env.path }}/build.sh | |
mkdir packages | |
dd if=/dev/zero of=./packages/$(date +%Y-%m-%d-%H-%M-%S).bin bs=4M count=1 | |
working-directory: ../build/ | |
- uses: vesoft-inc/.github/actions/setup-minio@master | |
with: | |
minio_url: ${{ secrets.MINIO_ENDPOINT }} | |
access_key: ${{ secrets.MINIO_KEY }} | |
secret_key: ${{ secrets.MINIO_SECRET }} | |
- name: Copy dir to MinIO | |
run: mc cp -r ../build/packages/ minio/pr-build/third-party/5.0/ |