Revert "build cache for cross build packages"
This commit is contained in:
parent
727dec14c7
commit
6fc7057fd3
|
@ -164,27 +164,6 @@ jobs:
|
||||||
kerl update releases
|
kerl update releases
|
||||||
kerl build ${{ matrix.otp }}
|
kerl build ${{ matrix.otp }}
|
||||||
kerl install ${{ matrix.otp }} $HOME/.kerl/${{ matrix.otp }}
|
kerl install ${{ matrix.otp }} $HOME/.kerl/${{ matrix.otp }}
|
||||||
|
|
||||||
- name: Get deps git refs for cache
|
|
||||||
id: deps-refs
|
|
||||||
run: |
|
|
||||||
cd source
|
|
||||||
. $HOME/.kerl/${{ matrix.otp }}/activate
|
|
||||||
make ensure-rebar3
|
|
||||||
sudo cp rebar3 /usr/local/bin/rebar3
|
|
||||||
scripts/get-dep-refs.sh
|
|
||||||
make clean-all
|
|
||||||
- name: load rocksdb cache
|
|
||||||
uses: actions/cache@v2
|
|
||||||
with:
|
|
||||||
path: source/_build/default/lib/rocksdb/
|
|
||||||
key: ${{ matrix.os }}-${{ matrix.otp }}-${{ matrix.arch }}-${{ steps.deps-refs.outputs.DEP_ROCKSDB_REF }}
|
|
||||||
- name: load quicer cache
|
|
||||||
uses: actions/cache@v2
|
|
||||||
with:
|
|
||||||
path: source/_build/default/lib/quicer/
|
|
||||||
key: ${{ matrix.os }}-${{ matrix.otp }}-${{ matrix.arch }}-${{ steps.deps-refs.outputs.DEP_QUICER_REF }}
|
|
||||||
|
|
||||||
- name: build
|
- name: build
|
||||||
working-directory: source
|
working-directory: source
|
||||||
run: |
|
run: |
|
||||||
|
@ -281,22 +260,6 @@ jobs:
|
||||||
path: .
|
path: .
|
||||||
- name: unzip source code
|
- name: unzip source code
|
||||||
run: unzip -q source.zip
|
run: unzip -q source.zip
|
||||||
- name: Get deps git refs for cache
|
|
||||||
id: deps-refs
|
|
||||||
run: |
|
|
||||||
cd source
|
|
||||||
scripts/get-dep-refs.sh
|
|
||||||
make clean-all
|
|
||||||
- name: load rocksdb cache
|
|
||||||
uses: actions/cache@v2
|
|
||||||
with:
|
|
||||||
path: source/_build/default/lib/rocksdb/
|
|
||||||
key: ${{ matrix.os }}-${{ matrix.otp }}-${{ matrix.arch }}-${{ steps.deps-refs.outputs.DEP_ROCKSDB_REF }}
|
|
||||||
- name: load quicer cache
|
|
||||||
uses: actions/cache@v2
|
|
||||||
with:
|
|
||||||
path: source/_build/default/lib/quicer/
|
|
||||||
key: ${{ matrix.os }}-${{ matrix.otp }}-${{ matrix.arch }}-${{ steps.deps-refs.outputs.DEP_QUICER_REF }}
|
|
||||||
- name: downloads old emqx zip packages
|
- name: downloads old emqx zip packages
|
||||||
env:
|
env:
|
||||||
OTP_VSN: ${{ matrix.otp }}
|
OTP_VSN: ${{ matrix.otp }}
|
||||||
|
@ -378,9 +341,6 @@ jobs:
|
||||||
# NOTE: for docker, only support latest otp version, not a matrix
|
# NOTE: for docker, only support latest otp version, not a matrix
|
||||||
otp:
|
otp:
|
||||||
- 24.1.5-3 # update to latest
|
- 24.1.5-3 # update to latest
|
||||||
arch:
|
|
||||||
- amd64
|
|
||||||
- arm64
|
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/download-artifact@v2
|
- uses: actions/download-artifact@v2
|
||||||
|
@ -412,33 +372,12 @@ jobs:
|
||||||
with:
|
with:
|
||||||
username: ${{ secrets.DOCKER_HUB_USER }}
|
username: ${{ secrets.DOCKER_HUB_USER }}
|
||||||
password: ${{ secrets.DOCKER_HUB_TOKEN }}
|
password: ${{ secrets.DOCKER_HUB_TOKEN }}
|
||||||
|
|
||||||
- name: Get deps git refs for cache
|
|
||||||
id: deps-refs
|
|
||||||
run: |
|
|
||||||
cd source
|
|
||||||
make ensure-rebar3
|
|
||||||
sudo cp rebar3 /usr/local/bin/rebar3
|
|
||||||
scripts/get-dep-refs.sh
|
|
||||||
make clean-all
|
|
||||||
|
|
||||||
- name: load rocksdb cache
|
|
||||||
uses: actions/cache@v2
|
|
||||||
with:
|
|
||||||
path: source/_build/default/lib/rocksdb/
|
|
||||||
key: alpine3.14-${{ matrix.otp }}-${{ matrix.arch }}-${{ steps.deps-refs.outputs.DEP_ROCKSDB_REF }}
|
|
||||||
- name: load quicer cache
|
|
||||||
uses: actions/cache@v2
|
|
||||||
with:
|
|
||||||
path: source/_build/default/lib/quicer/
|
|
||||||
key: alpine3.14-${{ matrix.otp }}-${{ matrix.arch }}-${{ steps.deps-refs.outputs.DEP_QUICER_REF }}
|
|
||||||
|
|
||||||
- uses: docker/build-push-action@v2
|
- uses: docker/build-push-action@v2
|
||||||
with:
|
with:
|
||||||
push: ${{ github.event_name == 'release' && !github.event.release.prerelease }}
|
push: ${{ github.event_name == 'release' && !github.event.release.prerelease }}
|
||||||
pull: true
|
pull: true
|
||||||
no-cache: true
|
no-cache: true
|
||||||
platforms: linux/${{ matrix.arch }}
|
platforms: linux/amd64,linux/arm64
|
||||||
tags: ${{ steps.meta.outputs.tags }}
|
tags: ${{ steps.meta.outputs.tags }}
|
||||||
labels: ${{ steps.meta.outputs.labels }}
|
labels: ${{ steps.meta.outputs.labels }}
|
||||||
build-args: |
|
build-args: |
|
||||||
|
|
|
@ -51,7 +51,11 @@ jobs:
|
||||||
- name: Get deps git refs for cache
|
- name: Get deps git refs for cache
|
||||||
id: deps-refs
|
id: deps-refs
|
||||||
run: |
|
run: |
|
||||||
scripts/get-dep-refs.sh
|
rebar3 get-deps
|
||||||
|
RocksDBRef=$(erl -noshell -eval '{ok,Raw}=file:consult("rebar.lock"), {_Vsn, Deps}=hd(Raw), {_, {git, _Url, {ref, Ref}},_} = lists:keyfind(<<"rocksdb">>,1, Deps), io:format("~s",[Ref]), init:stop().')
|
||||||
|
echo "::set-output name=DEP_ROCKSDB_REF::${RocksDBRef}"
|
||||||
|
QuicerRef=$(erl -noshell -eval '{ok,Raw}=file:consult("rebar.lock"), {_Vsn, Deps}=hd(Raw), {_, {git, _Url, {ref, Ref}},_} = lists:keyfind(<<"quicer">>,1, Deps), io:format("~s",[Ref]), init:stop().')
|
||||||
|
echo "::set-output name=DEP_QUICER_REF::${QuicerRef}"
|
||||||
make clean-all
|
make clean-all
|
||||||
- name: load rocksdb cache
|
- name: load rocksdb cache
|
||||||
uses: actions/cache@v2
|
uses: actions/cache@v2
|
||||||
|
@ -123,7 +127,11 @@ jobs:
|
||||||
. $HOME/.kerl/${{ matrix.otp }}/activate
|
. $HOME/.kerl/${{ matrix.otp }}/activate
|
||||||
make ensure-rebar3
|
make ensure-rebar3
|
||||||
sudo cp rebar3 /usr/local/bin/rebar3
|
sudo cp rebar3 /usr/local/bin/rebar3
|
||||||
scripts/get-dep-refs.sh
|
rebar3 get-deps
|
||||||
|
RocksDBRef=$(erl -noshell -eval '{ok,Raw}=file:consult("rebar.lock"), {_Vsn, Deps}=hd(Raw), {_, {git, _Url, {ref, Ref}},_} = lists:keyfind(<<"rocksdb">>,1, Deps), io:format("~s",[Ref]), init:stop().')
|
||||||
|
echo "::set-output name=DEP_ROCKSDB_REF::${RocksDBRef}"
|
||||||
|
QuicerRef=$(erl -noshell -eval '{ok,Raw}=file:consult("rebar.lock"), {_Vsn, Deps}=hd(Raw), {_, {git, _Url, {ref, Ref}},_} = lists:keyfind(<<"quicer">>,1, Deps), io:format("~s",[Ref]), init:stop().')
|
||||||
|
echo "::set-output name=DEP_QUICER_REF::${QuicerRef}"
|
||||||
make clean-all
|
make clean-all
|
||||||
- name: load rocksdb cache
|
- name: load rocksdb cache
|
||||||
uses: actions/cache@v2
|
uses: actions/cache@v2
|
||||||
|
|
|
@ -1,11 +0,0 @@
|
||||||
#!/usr/bin/env bash
|
|
||||||
set -euo pipefail
|
|
||||||
get_ref() {
|
|
||||||
local APP=$1
|
|
||||||
#echo "{ok,Raw}=file:consult(\"rebar.lock\"), {_Vsn, Deps}=hd(Raw), {_, {git, _Url, {ref, Ref}},_} = lists:keyfind(<<\"${APP}\">>,1, Deps), io:format(\"~s\",[Ref]), init:stop()."
|
|
||||||
erl -noshell -eval "{ok,Raw}=file:consult(\"rebar.lock\"), {_Vsn, Deps}=hd(Raw), {_, {git, _Url, {ref, Ref}},_} = lists:keyfind(<<\"${APP}\">>,1, Deps), io:format(\"~s\",[Ref]), init:stop()."
|
|
||||||
}
|
|
||||||
|
|
||||||
rebar3 get-deps
|
|
||||||
echo "::set-output name=DEP_ROCKSDB_REF::$(get_ref rocksdb)"
|
|
||||||
echo "::set-output name=DEP_QUICER_REF::$(get_ref quicer)"
|
|
Loading…
Reference in New Issue