lablup / lablup/backend.ai

Support macOS in pyinfra deploy scripts for local development

Open
#10,737 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
670
Forks
183
Avg merge
15h 13m
Merged PRs (30d)
368

Description

## Summary

The pyinfra deploy scripts currently assume a Linux target (systemd, Linux-specific commands). When running locally on macOS via `@local` connector, subprocess execution fails because Linux commands are not available.

## Background

During BA-5562 (inventory migration), we verified that the pyinfra inventory system works correctly — deploy scripts successfully read all `host.data` attributes. However, the actual deployment fails on macOS because `create_directories`, systemd operations, etc. assume Linux.

## Requirements

- Deploy scripts should detect the platform and use macOS-compatible alternatives
- Or provide a macOS-specific deploy mode that skips Linux-only operations (systemd service creation, etc.)
- Focus on the dev workflow: config generation and service setup should work on macOS

## Acceptance Criteria

- `pyinfra --dry inventory_local.py deploy/cores/appproxy/coordinator/deploy.py` succeeds on macOS
- Core config generation works on macOS (toml files, directories)
- Systemd-specific steps are gracefully skipped on macOS

JIRA Issue: BA-5563

Contributor guide

Open the contributing guide

Research direction

Start with inventory_local.py and deploy/cores/appproxy/coordinator/deploy.py, then run the stated pyinfra dry-run on macOS to identify Linux-only failures. Check the deploy steps involved in config generation, directory creation, and systemd operations; done means TOML files and directories are created, systemd-specific steps are skipped gracefully, and the dry-run succeeds.

Written by the indexing model from the issue text.

Assessment

Tech stack
macos, python
Domain
devops, infrastructure
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
55/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.