feat(installer): embed AlphaServer inside AlphaClient.app for one-click .dmg#6
Open
imhyunho99 wants to merge 1 commit into
Open
feat(installer): embed AlphaServer inside AlphaClient.app for one-click .dmg#6imhyunho99 wants to merge 1 commit into
imhyunho99 wants to merge 1 commit into
Conversation
…ck .dmg
DMG에서 AlphaClient.app 만 끌어다 놓으면 끝나도록 서버 바이너리를
.app 번들 안(Contents/Frameworks/AlphaServer/)에 같이 넣는다. 이전엔
사용자가 AlphaServer 폴더를 별도로 /Applications/AlphaServer/ 등에
복사해야 자동 기동이 동작하던 절반의 자동화 상태였다.
핵심 변경:
- AlphaClient.spec: dist/AlphaServer/를 datas로 임베드. 빌드 순서가
깨지면(서버 안 빌드된 채 client만 빌드) SystemExit으로 빠르게 실패.
onefile→onedir 전환 — onefile + .app 번들은 PyInstaller v7에서 에러가
되고, 200MB+ 서버를 매 실행마다 _MEIPASS로 풀어내는 비용도 사라진다.
- alpha/server_launcher.py: macOS .app 임베드 경로(Contents/Frameworks,
Contents/Resources) 우선 탐색. 기존 형제 디렉터리/시스템 경로 폴백 유지.
- scripts/build_macos_installer.sh:
· DMG 안에 별도 AlphaServer 폴더 더 이상 두지 않음 (.app만 노출)
· README.txt 안내를 "더블클릭하면 끝"으로 단순화
· hdiutil unmount가 .DS_Store 경합으로 종종 실패하므로 detach 후
최대 3회 재시도. SKIP_BUILD=1 환경변수로 패키징 단계만 반복 가능.
- .github/workflows/release.yml: Windows zip 스테이징도 별도 AlphaServer
복사 제거 (스펙이 임베드하므로 자동으로 포함됨).
- tests/test_unit.py: PyInstaller .app 레이아웃 흉내내서 임베드 경로가
시스템 경로보다 먼저 발견되는지 검증 (19/19 통과).
Harness 정리:
- CLAUDE.md 추가 — 프로젝트 컨텍스트(빌드 순서, 명령, 매매 안전장치
invariant)를 모든 Claude Code 세션이 자동으로 받도록.
- .claude/settings.json 추가 — pytest/pyinstaller/gh/git 같은 일상
명령을 allowlist에 넣어 권한 프롬프트를 줄임. force push, 공개 release
삭제 등은 deny에 명시.
로컬 검증:
- pytest tests/test_unit.py: 19/19 통과
- VERSION=3.1.3-dev ./scripts/build_macos_installer.sh
- dist/Alpha-3.1.3-dev-macOS.dmg (123MB) 생성 + 마운트 후 Frameworks/
AlphaServer/AlphaServer 임베드 + 실행 권한 확인 완료.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Why
v3.1.2의 "GUI 시작 시 AlphaServer 자동 기동"은 사용자가 AlphaServer 폴더를 별도로 `/Applications/AlphaServer/` 등에 복사해야만 동작하던 절반의 자동화였다. PR 본문에 "자동"이라고 적혀있었지만, 실제 사용자 시나리오에서는 "AlphaServer 바이너리를 찾지 못했습니다" 다이얼로그가 떴다. 이제 사용자는 .dmg 더블클릭 → AlphaClient.app 드래그 → 더블클릭만 하면 끝.
변경 파일
Test plan
🤖 Generated with Claude Code