साइन इन करें
HI▾
भाषा
डाउनलोड
बीटा यह भाषा बीटा में है: इसका अनुवाद और जाँच AI ने की है, और अभी तक किसी मूल भाषी ने इसकी समीक्षा नहीं की है। इस पेज का अभी अनुवाद नहीं हुआ है, इसलिए इसे अंग्रेज़ी में दिखाया गया है।
डॉक्स › रोज़मर्रा का उपयोग

DevOps इंजीनियरों के लिए रोज़ाना इस्तेमाल

पाइपलाइन, रनर, एनवायरनमेंट, वेरिएबल, मर्ज गेट और रिलीज़।

Pipelines

  • A pipeline lives in .mcdock/pipeline.yml in the repository, so it is reviewed like code.
  • Use stages and jobs, branch filters, manual jobs, timeouts and job variables.
  • Every run shows live logs, keeps artifacts, and reads JUnit test reports, so failed tests show on the pull request.
stages: [build, test, deploy]
jobs:
  build:
    stage: build
    runs-on: [windows]            # runner labels
    script:
      - dotnet build -c Release
    artifacts: [bin/Release/**]
  tests:
    stage: test
    script:
      - dotnet test --logger "junit;LogFilePath=results.xml"
    junit: [**/results.xml]
  deploy-production:
    stage: deploy
    environment: production
    branches: [main]
    when: manual
    script:
      - ./deploy.ps1 -Server $env:PROD_SERVER

Job settings: stage, runs-on, shell, script, branches, tags: true, when (on_success, manual, always), environment, junit, artifacts, timeout (minutes, default 60), variables and allow-failure.

Runners

  • A runner is the same mcdock.exe, run as a runner on any Windows or Linux machine. It connects outbound to the server, so you don't open any firewall ports to it.
  • Jobs run in PowerShell on Windows, and also in cmd, pwsh, bash or sh. Give each runner only the tools and rights its jobs need.
  • Check Admin → Runners each day. When a runner is offline, its jobs wait. To add a runner, give it a name and labels such as windows, dotnet, then run mcdock.exe runner --url <server> --token <token> on the build machine.

Environments and approvals

  • Create test, staging and production environments. For each one, set the allowed branches and its approvers.
  • Turn on the two-person rule for production, so the person who starts a deployment can't approve it.
  • Keep secrets in repository → Environments → CI/CD variables. Masked values show as [MASKED] in logs, protected variables only reach protected branches, and an environment scope limits a secret to that deployment.

Merge gates

  • On the protected branch, add mcdock/pipeline as a required status check, require the CODEOWNERS approvals, and dismiss stale approvals.
  • Merge when ready merges by itself once everything passes. This keeps the main branch green without anyone watching.

Every day

  • Look at the failed runs and fix flaky tests. Don't just press Retry.
  • Watch the build times. Cache dependencies on the runners and split slow jobs.
  • Use webhooks and the REST API, with scoped and expiring tokens, to connect your other tools.

Releases

  • Tag a version, let the pipeline build it, and publish it under Releases with notes and artifacts.

अपडेट 21/11/2026 · कुछ छूट गया? यहाँ पूछें: कम्युनिटी.