Automation Scripting for Operations Questions

Writing scripts and tooling to automate operational and delivery tasks: shell and Python scripting, glue automation, toil reduction, and operational efficiency. Covers automating repetitive infrastructure and deployment work and building internal tooling that raises operational leverage. The concern is task-level automation and scripting, distinct from full pipeline or infrastructure-as-code frameworks.

HardTechnical
85 practiced

Provide concise Python pseudocode implementing a saga-style multi-step orchestration coordinator. Each step must implement 'execute' and 'compensate' methods; the coordinator should persist progress, retry idempotently on transient failures, and execute compensating actions if a fatal step fails. Show how you would store state and resume after restarts.

MediumTechnical
72 practiced

Implement a Python helper 'run_cli(cmd: List[str], timeout: int, log_file: str)' that runs an external CLI safely: it should enforce a timeout, stream stdout and stderr to a rotating log file, return the exit code, and ensure no zombie processes remain if the parent crashes or is killed. Show key code and explain how you guarantee resource cleanup on termination.

MediumSystem Design
93 practiced

Design monitoring and alerting for a fleet of scheduled automation jobs. What health metrics would you collect to know a job is actually healthy, what alerting thresholds would you set to avoid paging noise, how would escalation and runbook integration work, and where might automated remediation be safe to attempt for transient failures?

MediumTechnical
77 practiced

You are building automation that calls an external payment API. Describe a robust error-handling strategy: include timeouts, retries with exponential backoff and jitter, idempotency keys for non-idempotent endpoints, circuit-breaker logic, alerting thresholds, and how to surface incidents to operators without causing noise.

HardTechnical
69 practiced

You must migrate hundreds of ad-hoc Bash automation scripts to a centralized automation platform. Draft a migration plan covering discovery and inventory, risk-based prioritization, refactoring strategy (how to translate bash into reusable modules), testing, packaging, rollout strategy, rollback plan, documentation, training, and success metrics.

Unlock Full Question Bank

Get access to all Automation Scripting for Operations interview questions and detailed answers.

Sign in to Continue

Join thousands of developers preparing for their dream job.