mirror of
https://github.com/openimsdk/open-im-server.git
synced 2026-05-10 20:15:59 +08:00
fix: delete batch build all file (#561)
* fix: delete batch build all file Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add cicd sacript feature Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * fix: docker scripts Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add openim fix scripts Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: fix scripts show Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * cicd: add ci workflow Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * cicd: add ci workflow Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * cicd: add ci workflow Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * cicd: add ci workflow Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * cicd: add ci workflow Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * cicd: add ci workflow Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: about the distribution of the strategy Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: github release fix Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: build bing file: Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add openim server Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add more cicd auto Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add test file Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add test file Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add test file Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add test file Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add test file Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add test file Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add test file Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add test file Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add test file Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add test file Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add test file Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add test file Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add test file Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add test file Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add test file Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add test file Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add test file Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add before module Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add copyright dispose Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add tools user Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: More support Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: signing commit Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add release Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add release Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add cicd actions Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add test login Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add release copyright Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add release copyright Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add release copyright Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * fix: go release quest Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * cide: add ca Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * fix: cicd action about lock issue Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * fix: cicd action about lock issue Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add comment remark Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * fix: cicd about gosec Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * fix: cicd about gosec Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> --------- Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com>
This commit is contained in:
@@ -13,21 +13,96 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
echo "docker-compose ps..........................."
|
||||
cd ..
|
||||
# Include shell font styles and some basic information
|
||||
SCRIPTS_ROOT=$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)
|
||||
OPENIM_ROOT=$(dirname "${BASH_SOURCE[0]}")/..
|
||||
|
||||
if command -v docker-compose &> /dev/null
|
||||
then
|
||||
source "$SCRIPTS_ROOT/style_info.sh"
|
||||
|
||||
echo -e "${GREEN_PREFIX}=========> Check docker-compose status ${COLOR_SUFFIX} \n"
|
||||
|
||||
trap 'onCtrlC' INT
|
||||
|
||||
function onCtrlC() {
|
||||
kill -9 "${do_sth_pid}" "${progress_pid}" "${countdown_pid}"
|
||||
echo
|
||||
echo 'Ctrl+C is captured'
|
||||
exit 1
|
||||
}
|
||||
|
||||
cd "$OPENIM_ROOT"
|
||||
|
||||
if command -v docker-compose &> /dev/null; then
|
||||
docker-compose ps
|
||||
else
|
||||
docker compose ps
|
||||
fi
|
||||
|
||||
progress() {
|
||||
local _main_pid="$1"
|
||||
local _length=20
|
||||
local _ratio=1
|
||||
local _colors=("31" "32" "33" "34" "35" "36" "37")
|
||||
local _wave=("▁" "▂" "▃" "▄" "▅" "▆" "▇" "█" "▇" "▆" "▅" "▄" "▃" "▂")
|
||||
|
||||
while pgrep -P "$_main_pid" &> /dev/null; do
|
||||
local _mark='>'
|
||||
local _progress_bar=
|
||||
for ((i = 1; i <= _length; i++)); do
|
||||
if ((i > _ratio)); then
|
||||
_mark='-'
|
||||
fi
|
||||
_progress_bar="${_progress_bar}${_mark}"
|
||||
done
|
||||
|
||||
cd scripts
|
||||
echo "check OpenIM................................"
|
||||
local _color_idx=$((_ratio % ${#_colors[@]}))
|
||||
local _color_prefix="\033[${_colors[_color_idx]}m"
|
||||
local _reset_suffix="\033[0m"
|
||||
|
||||
sleep 30
|
||||
./check_all.sh
|
||||
local _wave_idx=$((_ratio % ${#_wave[@]}))
|
||||
local _wave_progress=${_wave[_wave_idx]}
|
||||
|
||||
printf "Progress: ${_color_prefix}${_progress_bar}${_reset_suffix} ${_wave_progress} Countdown: %2ds \r" "$_countdown"
|
||||
((_ratio++))
|
||||
((_ratio > _length)) && _ratio=1
|
||||
sleep 0.1
|
||||
done
|
||||
}
|
||||
|
||||
countdown() {
|
||||
local _duration="$1"
|
||||
|
||||
for ((i = _duration; i >= 1; i--)); do
|
||||
printf "\rCountdown: %2ds \r" "$i"
|
||||
sleep 1
|
||||
done
|
||||
printf "\rCountdown: %2ds \r" "$_duration"
|
||||
}
|
||||
|
||||
do_sth() {
|
||||
echo "++++++++++++++++++++++++"
|
||||
progress $$ &
|
||||
local _progress_pid=$!
|
||||
local _countdown=30
|
||||
|
||||
countdown "$_countdown" &
|
||||
local _countdown_pid=$!
|
||||
|
||||
sleep 30
|
||||
|
||||
kill "$_progress_pid" "$_countdown_pid"
|
||||
|
||||
"${SCRIPTS_ROOT}/check_all.sh"
|
||||
echo -e "${PURPLE_PREFIX}=========> Check docker-compose status ${COLOR_SUFFIX} \n"
|
||||
}
|
||||
|
||||
set -e
|
||||
|
||||
do_sth &
|
||||
do_sth_pid=$(jobs -p | tail -1)
|
||||
|
||||
progress "${do_sth_pid}" &
|
||||
progress_pid=$(jobs -p | tail -1)
|
||||
|
||||
wait "${do_sth_pid}"
|
||||
printf "Progress: done \n"
|
||||
|
||||
Reference in New Issue
Block a user