Atualizar .github/workflows/teste-shell.yml
This commit is contained in:
@@ -0,0 +1,50 @@
|
||||
name: Teste Shell Runner
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- main
|
||||
|
||||
jobs:
|
||||
shell-test:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- name: ✅ Verificar sistema
|
||||
run: |
|
||||
echo "=== Runner funcionando! ==="
|
||||
echo "Data: $(date)"
|
||||
echo "Hostname: $(hostname)"
|
||||
uname -a
|
||||
|
||||
- name: 📦 Verificar ferramentas disponíveis
|
||||
run: |
|
||||
echo "=== Ferramentas ==="
|
||||
bash --version
|
||||
python3 --version
|
||||
curl --version | head -1
|
||||
|
||||
- name: 🌐 Testar conectividade externa
|
||||
run: |
|
||||
echo "=== Ping externo ==="
|
||||
curl -s https://ifconfig.me && echo ""
|
||||
echo "Conectividade OK!"
|
||||
|
||||
- name: 📝 Criar e executar script shell inline
|
||||
run: |
|
||||
cat > /tmp/meu-script.sh << 'EOF'
|
||||
#!/bin/bash
|
||||
echo "=== Script a correr dentro do runner ==="
|
||||
echo "Utilizador: $(whoami)"
|
||||
echo "Directório: $(pwd)"
|
||||
echo "Memória disponível:"
|
||||
free -h
|
||||
echo "Espaço em disco:"
|
||||
df -h /
|
||||
EOF
|
||||
|
||||
chmod +x /tmp/meu-script.sh
|
||||
bash /tmp/meu-script.sh
|
||||
|
||||
- name: 🎉 Teste concluído
|
||||
run: echo "Todos os steps passaram com sucesso!"
|
||||
Reference in New Issue
Block a user