diff --git a/.github/actions/package-macos/action.yaml b/.github/actions/package-macos/action.yaml index 5c0649b17..c8ebfd795 100644 --- a/.github/actions/package-macos/action.yaml +++ b/.github/actions/package-macos/action.yaml @@ -1,8 +1,5 @@ name: 'Create MacOS package' inputs: - profile: # emqx, emqx-enterprise - required: true - type: string otp: # 24.2.1-1, 23.3.4.9-3 required: true type: string @@ -49,7 +46,7 @@ runs: kerl update releases kerl build ${{ inputs.otp }} kerl install ${{ inputs.otp }} $HOME/.kerl/${{ inputs.otp }} - - name: build ${{ inputs.profile }} + - name: build env: AUTO_INSTALL_BUILD_DEPS: 1 APPLE_SIGN_BINARIES: 1 @@ -64,12 +61,12 @@ runs: . $HOME/.kerl/${{ inputs.otp }}/activate make ensure-rebar3 sudo cp rebar3 /usr/local/bin/rebar3 - make ${{ inputs.profile }}-zip - - name: test ${{ inputs.profile }} + make ${EMQX_NAME}-zip + - name: test shell: bash run: | - pkg_name=$(basename _packages/${{ inputs.profile }}/${{ inputs.profile }}-*.zip) - unzip -q _packages/${{ inputs.profile }}/$pkg_name + pkg_name=$(basename _packages/${EMQX_NAME}/${EMQX_NAME}-*.zip) + unzip -q _packages/${EMQX_NAME}/$pkg_name gsed -i '/emqx_telemetry/d' ./emqx/data/loaded_plugins ./emqx/bin/emqx start || cat emqx/log/erlang.log.1 ready='no' diff --git a/.github/workflows/build_packages.yaml b/.github/workflows/build_packages.yaml index f2024fb5b..c64af4f93 100644 --- a/.github/workflows/build_packages.yaml +++ b/.github/workflows/build_packages.yaml @@ -120,11 +120,8 @@ jobs: strategy: matrix: - profile: ${{fromJSON(needs.prepare.outputs.profiles)}} otp: - 23.3.4.9-3 - exclude: - - profile: emqx-edge os: - macos-11 runs-on: ${{ matrix.os }} @@ -139,9 +136,12 @@ jobs: ln -s . source unzip -q source.zip rm source source.zip + - id: detect-profiles + uses: ./.github/actions/detect-profiles + with: + ci_git_token: ${{ secrets.CI_GIT_TOKEN }} - uses: ./.github/actions/package-macos with: - profile: ${{ matrix.profile }} otp: ${{ matrix.otp }} os: ${{ matrix.os }} apple_id_password: ${{ secrets.APPLE_ID_PASSWORD }} @@ -150,8 +150,8 @@ jobs: apple_developer_id_bundle_password: ${{ secrets.APPLE_DEVELOPER_ID_BUNDLE_PASSWORD }} - uses: actions/upload-artifact@v1 with: - name: ${{ matrix.profile }}-${{ matrix.otp }} - path: _packages/${{ matrix.profile }}/. + name: ${EMQX_NAME}-${{ matrix.otp }} + path: _packages/${EMQX_NAME}/. linux: runs-on: ubuntu-20.04 diff --git a/.github/workflows/build_slim_packages.yaml b/.github/workflows/build_slim_packages.yaml index c0bba8c96..a13c11f11 100644 --- a/.github/workflows/build_slim_packages.yaml +++ b/.github/workflows/build_slim_packages.yaml @@ -11,10 +11,10 @@ jobs: strategy: matrix: otp: - - erl23.3.4.9-3 + - erl23.3.4.9-3 os: - - ubuntu20.04 - - centos7 + - ubuntu20.04 + - centos7 runs-on: - aws-amd64 - ubuntu-20.04 @@ -65,8 +65,6 @@ jobs: mac: strategy: matrix: - profile: - - emqx otp: - 23.3.4.9-3 os: @@ -79,7 +77,6 @@ jobs: ci_git_token: ${{ secrets.CI_GIT_TOKEN }} - uses: ./.github/actions/package-macos with: - profile: ${{ matrix.profile }} otp: ${{ matrix.otp }} os: ${{ matrix.os }} apple_id_password: ${{ secrets.APPLE_ID_PASSWORD }}