Иногда бывает ситуация когда 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
#BNX/USDT analysis :
#BNX has experienced a significant drop of approximately 74% from its peak and has found support at a previously respected support zone. The price is currently forming a double bottom reversal pattern at this critical level. It is expected that the price will bounce back from this zone and continue to rise, targeting previous highs.
TF : 1D
Entry : $0.5600
Target : $1.6045
SL : $0.4026
#BNX 30m indicator strategy
👨✈️
GG-Shøt caught the trend at 0.26 - the rest is history /// 😘^^
+4159% max profit (10x lev)
+8318% max profit (20x lev)
The chart speaks for itself.
Others watch
🕺 We execute.
#BNX result
All target achieved in just 6 days ✅
One more huge quick profit 25%🤑💰🤑
👉 Still thinking? The more you wait more you lose profit
☎️ Contact @MichaelStrategiesVip for membership and grab next breakout signal
#BNX result
3 nd target achieved in just 6 house ✅✅✅
One more huge quick profit 18.6%🤑💰🤑
👉 Still thinking? The more you wait more you lose profit
☎️ Contact @MichaelStrategiesVip for membership and grab next breakout signal