-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathstatus_complete.sh
More file actions
executable file
·103 lines (86 loc) · 3.5 KB
/
status_complete.sh
File metadata and controls
executable file
·103 lines (86 loc) · 3.5 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
#!/bin/bash
echo "🏥 FHIR Nursing Learning Analytics - Status dos Serviços"
echo "======================================================="
echo ""
# Cores
GREEN='\033[0;32m'
RED='\033[0;31m'
YELLOW='\033[1;33m'
NC='\033[0m' # No Color
check_service() {
local name=$1
local url=$2
local description=$3
if curl -s --max-time 3 "$url" > /dev/null 2>&1; then
echo -e "✅ ${GREEN}$name${NC} - $description"
echo " 📍 $url"
else
echo -e "❌ ${RED}$name${NC} - $description"
echo " 📍 $url (INDISPONÍVEL)"
fi
echo ""
}
check_docker_service() {
local container=$1
local name=$2
local description=$3
if docker ps --format "table {{.Names}}" | grep -q "^$container$" 2>/dev/null; then
echo -e "✅ ${GREEN}$name${NC} - $description"
echo " 🐳 Container: $container"
else
echo -e "❌ ${RED}$name${NC} - $description"
echo " 🐳 Container: $container (NÃO RODANDO)"
fi
echo ""
}
echo "🏥 APLICAÇÕES PRINCIPAIS:"
echo "========================"
check_service "FHIR Nursing API" "http://localhost:8000/health" "API FHIR para enfermagem"
check_service "Swagger UI (FHIR)" "http://localhost:8000/docs" "Documentação interativa da API FHIR"
check_service "OpenEDX LMS" "http://localhost/" "Sistema de Aprendizagem OpenEDX"
echo "📊 OBSERVABILIDADE:"
echo "=================="
check_service "Grafana" "http://localhost:3000" "Dashboards e visualizações"
check_service "Prometheus" "http://localhost:9090" "Coleta de métricas"
check_service "Jaeger" "http://localhost:16686" "Tracing distribuído"
check_service "Loki" "http://localhost:3100" "Sistema de logs"
check_service "AlertManager" "http://localhost:9093" "Gerenciamento de alertas"
check_service "cAdvisor" "http://localhost:8080" "Métricas de containers"
echo "🤖 SERVIÇOS DE IA:"
echo "=================="
if command -v ollama &> /dev/null; then
echo -e "✅ ${GREEN}Ollama${NC} - Servidor de modelos de IA local"
echo " 📍 http://localhost:11434"
echo " 🧠 Modelos disponíveis:"
ollama list | tail -n +2 | while read line; do
echo " - $line"
done
else
echo -e "❌ ${RED}Ollama${NC} - Servidor de modelos de IA local"
echo " 📍 http://localhost:11434 (NÃO INSTALADO)"
fi
echo ""
check_docker_service "fhir-clinical-agent" "Clinical Agent" "Agente de monitoramento clínico"
check_docker_service "fhir-competency-agent" "Competency Agent" "Agente de avaliação de competências"
echo "💾 ARMAZENAMENTO:"
echo "================"
check_docker_service "fhir-redis" "Redis" "Cache e sessões"
check_docker_service "tutor_local-mysql-1" "MySQL (OpenEDX)" "Banco de dados OpenEDX"
check_docker_service "tutor_local-mongodb-1" "MongoDB (OpenEDX)" "Banco NoSQL OpenEDX"
echo "🌐 URLS PRINCIPAIS DE ACESSO:"
echo "============================="
echo "• 🏥 API FHIR: http://localhost:8000"
echo "• 📖 Swagger FHIR: http://localhost:8000/docs"
echo "• 🎓 OpenEDX: http://localhost"
echo "• 📊 Grafana: http://localhost:3000 (admin/fhir-admin-2025)"
echo "• 📈 Prometheus: http://localhost:9090"
echo "• 🔍 Jaeger: http://localhost:16686"
echo ""
if [ "$1" == "--containers" ]; then
echo "🐳 CONTAINERS ATIVOS:"
echo "===================="
docker ps --format "table {{.Names}}\t{{.Status}}\t{{.Ports}}" | head -1
docker ps --format "table {{.Names}}\t{{.Status}}\t{{.Ports}}" | tail -n +2 | sort
echo ""
fi
echo "💡 Para mais detalhes: ./status.sh --containers"