From aee4f08abff062e44474dc577c9d41a39a3fb981 Mon Sep 17 00:00:00 2001 From: Julien Bouquillon Date: Tue, 6 Feb 2024 09:48:41 +0100 Subject: [PATCH] chore: add sample updownio-init action (#88) --- .github/workflows/scans.yml | 5 ++-- dashlord.yml | 6 ++++- schema.json | 48 +++++++++++++------------------------ 3 files changed, 24 insertions(+), 35 deletions(-) diff --git a/.github/workflows/scans.yml b/.github/workflows/scans.yml index cfd1b4d792a..646d0ae5d36 100644 --- a/.github/workflows/scans.yml +++ b/.github/workflows/scans.yml @@ -52,10 +52,11 @@ jobs: with: url: ${{ github.event.inputs.url }} tool: ${{ github.event.inputs.tool }} + # to create missing entries in updown.io + - id: updown-init + uses: "SocialGouv/dashlord-actions/updown-init@v1" env: - # to create missing entries in updown.io UPDOWNIO_API_KEY: ${{ secrets.UPDOWNIO_API_KEY }} - scans: runs-on: ubuntu-latest name: Scan diff --git a/dashlord.yml b/dashlord.yml index 894fe0cb7f5..547bb933e76 100644 --- a/dashlord.yml +++ b/dashlord.yml @@ -4,7 +4,7 @@ entity: Votre entité footer: Powered by SocialGouv marianne: false tools: - 404: true + "404": true screenshot: true nmap: true zap: true @@ -22,6 +22,10 @@ tools: ecoindex: true dsfr: true betagouv: true +updownioStatusPage: https://updown.io/status_pages +updownioRecipients: + - email:123456 + - email:789987 urls: - url: https://www.fabrique.social.gouv.fr repositories: diff --git a/schema.json b/schema.json index f71f59137f2..aba33b06192 100644 --- a/schema.json +++ b/schema.json @@ -153,15 +153,10 @@ "direction": { "type": "string", "default": "horizontal", - "enum": [ - "horizontal", - "vertical" - ] + "enum": ["horizontal", "vertical"] } }, - "required": [ - "src" - ] + "required": ["src"] } ] }, @@ -169,15 +164,20 @@ "type": "string" } }, - "required": [ - "logo", - "name" - ] + "required": ["logo", "name"] }, "updownioStatusPage": { "type": "string", "description": "URL de la page de status updown.io" }, + "updownioRecipients": { + "description": "Notifications pour les nouvelles alertes updown.io (action updown-init)", + "type": "array", + "items": { + "type": "string", + "examples": ["email:987634908723", "slack_compatible:0979867"] + } + }, "tools": { "$ref": "#/definitions/tools" }, @@ -208,10 +208,7 @@ "pages": { "type": "array", "description": "Additionnal URLs to scan with LightHouse", - "examples": [ - "/actu", - "/partners" - ], + "examples": ["/actu", "/partners"], "items": { "type": "string" } @@ -219,10 +216,7 @@ "repositories": { "type": "array", "description": "Repositories no GitHub", - "examples": [ - "SocialGouv/www", - "SocialGouv/template" - ], + "examples": ["SocialGouv/www", "SocialGouv/template"], "items": { "type": "string" } @@ -230,9 +224,7 @@ "docker": { "type": "array", "description": "Docker images to scan", - "examples": [ - "ghcr.io/socialgouv/www/app" - ], + "examples": ["ghcr.io/socialgouv/www/app"], "items": { "type": "string" } @@ -241,17 +233,9 @@ "$ref": "#/definitions/tools" } }, - "required": [ - "url" - ] + "required": ["url"] } } }, - "required": [ - "title", - "description", - "entity", - "tools", - "urls" - ] + "required": ["title", "description", "entity", "tools", "urls"] }