GitHub Actions y CI/CD · CLI cifrada

Protege despliegues a producción.
Con Face ID en tu iPhone.

Añade un paso de la CLI de NotiBuddy en GitHub Actions para recibir aprobaciones cifradas y alertas de compilación en tu iPhone — sin bots de Slack ni cuentas.

iOS 17+ y watchOS 10+ · Plan Gratis incluido · Referencia completa de configuración

Captura en modo oscuro de una aprobación de despliegue protegida con Face ID en NotiBuddy.
Cada respuesta se firma en tu móvil y el workflow la verifica antes de continuar.

Recomendado · 30 segundos

Configuración rápida: pega esto en tu agente de código

Tu agente leerá /github-actions.md, te guiará para crear una clave dedicada de CI y añadirá una puerta fail-closed.

Tu agente leerá las instrucciones detalladas en notibuddy.app/github-actions.md (Markdown sin formato, en inglés).

O añade el paso de GitHub Actions manualmente

Enlaza una clave dedicada para CI una vez, guarda su JSON en un Secret de un Environment protegido (NOTIBUDDY_CI_DESTINATION) y añade esta puerta con Face ID:

.github/workflows/deploy.yml
- name: Set up Node.js
  uses: actions/setup-node@v4
  with:
    node-version: '20'

- name: Request Face ID deploy approval
  shell: bash
  timeout-minutes: 15
  env:
    NOTIBUDDY_DEST_JSON: ${{ secrets.NOTIBUDDY_CI_DESTINATION }}
    APPROVE_OPTION: Approve
    DECLINE_OPTION: Reject
    TIMEOUT_SECONDS: '600'
    REF_NAME: ${{ github.ref_name }}
    COMMIT_SHA: ${{ github.sha }}
    REPO_NAME: ${{ github.repository }}
    ACTOR: ${{ github.actor }}
    RUN_URL: ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}
  run: |
    set -euo pipefail
    if [ -z "$NOTIBUDDY_DEST_JSON" ]; then
      echo "::error::Missing NOTIBUDDY_CI_DESTINATION secret."
      exit 1
    fi

    umask 077
    export NOTIBUDDY_HOME="${RUNNER_TEMP:-/tmp}/notibuddy-$$"
    NB_PREFIX="${RUNNER_TEMP:-/tmp}/notibuddy-cli-$$"
    trap 'rm -rf "$NOTIBUDDY_HOME" "$NB_PREFIX"' EXIT

    mkdir -p "$NOTIBUDDY_HOME/destinations" "$NB_PREFIX"
    printf '%s' "$NOTIBUDDY_DEST_JSON" > "$NOTIBUDDY_HOME/destinations/ci.json"
    npm --prefix "$NB_PREFIX" install --no-save --silent notibuddy@^0.4.0 >/dev/null

    "$NB_PREFIX/node_modules/.bin/nb" gate "Deploy ${REF_NAME}?" \
      --to ci \
      --sender "GitHub Actions" \
      --message "${REPO_NAME} · ${COMMIT_SHA:0:7} by ${ACTOR} · ${RUN_URL}" \
      --approve "${APPROVE_OPTION}" \
      --reject "${DECLINE_OPTION}" \
      --requires-auth \
      --timeout "${TIMEOUT_SECONDS}"
Opcional: aviso inmediato si falla un workflow (sin espera)

Usa nb notify sin --options para lanzar una notificación cifrada unidireccional al instante:

- name: Notify iPhone on workflow failure
  if: failure()
  shell: bash
  env:
    NOTIBUDDY_DEST_JSON: ${{ secrets.NOTIBUDDY_CI_DESTINATION }}
    REF_NAME: ${{ github.ref_name }}
    REPO_NAME: ${{ github.repository }}
    RUN_URL: ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}
  run: |
    set -euo pipefail
    umask 077
    export NOTIBUDDY_HOME="${RUNNER_TEMP:-/tmp}/notibuddy-$$"
    NB_PREFIX="${RUNNER_TEMP:-/tmp}/notibuddy-cli-$$"
    trap 'rm -rf "$NOTIBUDDY_HOME" "$NB_PREFIX"' EXIT
    mkdir -p "$NOTIBUDDY_HOME/destinations" "$NB_PREFIX"
    printf '%s' "$NOTIBUDDY_DEST_JSON" > "$NOTIBUDDY_HOME/destinations/ci.json"
    npm --prefix "$NB_PREFIX" install --no-save --silent notibuddy@^0.4.0 >/dev/null
    "$NB_PREFIX/node_modules/.bin/nb" notify "CI failed on ${REF_NAME}" \
      --to ci \
      --sender "GitHub Actions" \
      --message "${REPO_NAME} · ${RUN_URL}"

Actívalo en 3 pasos

1

Enlaza una clave dedicada de CI

Crea una conexión aparte con npx -y notibuddy@^0.4.0 pair --to ci --label "GitHub Actions" y comprueba con doctor --to ci.

2

Guarda ci.json en un Environment Secret

Guarda ~/.notibuddy/destinations/ci.json como NOTIBUDDY_CI_DESTINATION en un Environment protegido.

3

Fallo cerrado con nb gate

nb gate espera sobre un único ID firmado hasta --timeout y devuelve 0 solo con aprobación verificada y Face ID.

Casos clave para DevOps

Pantallas de despliegue

Paneles nativos con Face ID

Usa nb notify --screen para mostrar KPIs canary, listas previas y detalles del commit antes de promover.

Terraform y BD

Controla cambios de infraestructura

Envía el resumen del plan o el diff de esquema antes de ejecutar terraform apply.

Avisos instantáneos

Notificaciones de éxito o fallo

Omite --options para recibir un aviso cifrado en cuanto acabe o falle un pipeline.