Иногда бывает ситуация когда dev-сервер по какой-либо причине не закрылся и висит в процессах, занимая порт.
Это может быть из-за падения IDE или просто сам забыл погасить и закрыл терминал.
Для таких случаев я набросал простую функцию с командой:
kill_on_port() {
port=$(lsof -t -i:$1)
echo "KILL PROCESS:" $port
sudo kill -9 $port
}
alias killonport="kill_on_port $@"
Код поместить в ~/.bashrc и рестартнуть систему.
Если во время старта dev-сервера получаете ошибку что порт уже занят, просто выполните команду, подставив свой порт.
Bash
kill_on_port 8000
Скорее всего бесполезно, если другой процесс назначен на перезапуск вашего dev-сервера в случае падения.
Имя команды можете изменить на любое другое.
#linux
#DEGO/USDT analysis :
#DEGO is currently in a downtrend, trading below its 200 EMA and encountering resistance. This suggests a potential continuation of the downtrend, for short entry opportunity wait for pullback.
TF : 4h
Entry : $1.537
Target : $1.270
SL : $1.712
#DEGO/USDT analysis :
#DEGO is currently in an uptrend, consistently reaching new highs while trading above the support zone. Following a strong impulsive move, the price has undergone a correction phase. It is now anticipated to bounce from this level and continue rising, aiming to test previous highs. For a long entry, wait for a breakout above the $1.996 level.
TF : 4H
Entry : $1.996
Target : $2.490
SL : $1.757
#DEGO/USDT analysis :
#DEGO is currently in an uptrend, forming higher highs and higher lows above the 200 EMA. The price is presently consolidating above the support zone and is expected to bounce from there to sustain its bullish momentum and test the previous swing high.
TF : 1h
Entry : $1.640
Target : $1.696
SL : $1.608
🚀🚀100% Huge Profit on #DEGO/USDT as it has hit all the profit target - The trade has been closed
👁🗨Contact @primemod to enter the premium group & make daily gains