Door deze site te gebruiken, u gaat akkoord met de Privacybeleid.
Accepteren
OndernemingOndernemingOnderneming
  • THUIS
  • IT-PRO
  • Technisch
  • Microsoft
    • Azuur
    • Configmgr/sccm
    • DPM
    • Orkestrator
    • Hyper-V
    • Microsoft Edge Insider
    • MSI
    • Kantoor 365
    • Kantoor insider
    • PowerBI
    • Skypen
    • SQL-server
    • Teams
  • VENSTERS
    • Windows-beheercentrum
    • Windows-client
    • Windows-server
  • SCCM-queryverzamelingslijst
Lezing: Marking Azure DevOps Builds as Failed Using Command Line
Lettergrootte wijzigenAa
OndernemingOnderneming
Lettergrootte wijzigenAa
  • THUIS
  • IT-PRO
  • Technisch
  • Microsoft
  • VENSTERS
  • SCCM-queryverzamelingslijst
Zoekopdracht
  • THUIS
  • IT-PRO
  • Technisch
  • Microsoft
    • Azuur
    • Configmgr/sccm
    • DPM
    • Orkestrator
    • Hyper-V
    • Microsoft Edge Insider
    • MSI
    • Kantoor 365
    • Kantoor insider
    • PowerBI
    • Skypen
    • SQL-server
    • Teams
  • VENSTERS
    • Windows-beheercentrum
    • Windows-client
    • Windows-server
  • SCCM-queryverzamelingslijst
Azure DevOps

Marking Azure DevOps Builds as Failed Using Command Line

Gepubliceerd: Februari 18, 2024
2 Min. gelezen
DEEL

Marking Azure DevOps Builds as Failed Using Command Line.

In Azure DevOps, you can use the command-line interface (CLI) to manage and automate your build pipeline. Sometimes, you may want to mark a build as failed using the CLI.

To mark a build as failed using the Azure DevOps CLI, you can use the following command:

az pipelines runs update --id <run-id> --state Failed

In this command, <run-id> is the ID of the build run that you want to mark as failed. You can find the run ID by navigating to the build summary page in the Azure DevOps portal.

Once you’ve run the command, the build will be marked as failed and any subsequent tasks in the build pipeline will be skipped.

You can also add a reason for the failure by including the --reason parameter, like this:

az pipelines runs update --id <run-id> --state Failed --reason "Build failed due to errors in script"

In dit voorbeeld, the reason for the failure is “Build failed due to errors in script”. This message will be displayed in the build summary page in the Azure DevOps portal.

In conclusion, using the Azure DevOps CLI, you can mark a build as failed with just a few simple commands. This can be useful in cases where you need to manually trigger a build failure or if there are errors in the build pipeline that you want to highlight.

GETAGD:Azure DevOpsBasMicrosoft AzurePowershell
Vorig artikel Configuration Manager Queryverzamelingslijst Configuration Manager SCCM Huidige filiaalbuildnummers
Volgend artikel Securing Your Linux Server: How to Check TLS/SSL Certificate Expiration Dates
1 Opmerking 1 Opmerking
  • M zegt:
    april 8, 2025 bij 2:57 ben

    This does not work. There is no command `update` for az pipeline runs.

    Antwoord

Laat een antwoord achter Antwoord annuleren

Uw e-mailadres wordt niet gepubliceerd. Verplichte velden zijn gemarkeerd *

Deze site gebruikt Akismet om spam te verminderen. Ontdek hoe uw reactiegegevens worden verwerkt.

Vertaling

English中文(简体)DanskNederlandsFrançaisDeutschItaliano한국어PolskiPortuguêsRomânăEspañolУкраїнська
door Transposh - Vertaalplugin voor Wordpress

Populaire berichten

Systeemvereisten voor Windows Server 2016
Windows-server
Configuration Manager Queryverzamelingslijst
Configuration Manager Queryverzamelingslijst
ConfiguratieMgr
Gestructureerde/beheerde navigatie ingeschakeld op moderne pagina's in klassieke teamsites
Technologie
SCCM Kan DP-locaties niet ophalen als de verwachte versie van MP
ConfiguratieMgr

Recente berichten

Fail2ban installeren en configureren voor SSH-bescherming op Ubuntu 24.04
Linux
FirewallD inschakelen en configureren op AlmaLinux
Linux
Gebruikers aanmaken en SSH-sleutel instellen in AlmaLinux
Linux
Hoe het wachtwoord op AlmaLinux opnieuw in te stellen
Linux

© 2023 Onderneming

Ga naar mobiele versie
Welkom terug!

Log in op uw account

Gebruikersnaam of e-mailadres
Wachtwoord

Wachtwoord vergeten?