Skip to content

Latest commit

 

History

History
32 lines (25 loc) · 479 Bytes

File metadata and controls

32 lines (25 loc) · 479 Bytes

Ping

Simple ping action / script using curl.

Bash

chmod +x ./ping.sh
./ping.sh www.google.com 10 "echo 'ping failed'"

Docker

docker build -t ping .
docker run ping www.google.com 10 "echo 'ping failed'"

GitHub Action

jobs:
  test:
    runs-on: ubuntu-latest
    steps:
      - name: Ping
        uses: matiasg19/ping@main
        with:
          url: wwww.google.com
          attempts: 10
          on-fail: "echo 'ping failed'"