mirror of
https://github.com/hanzoai/papers.git
synced 2026-10-22 17:20:17 +00:00
54 lines
1.3 KiB
TeX
54 lines
1.3 KiB
TeX
\section{Developer Experience}
|
|
|
|
\label{sec:dx}
|
|
|
|
\subsection{CLI Interface}
|
|
|
|
The Hanzo CLI provides a streamlined deployment workflow:
|
|
|
|
\begin{lstlisting}[language=bash,caption={Hanzo CLI deployment workflow.}]
|
|
# Initialize project
|
|
hanzo init
|
|
|
|
# Deploy (auto-detects framework)
|
|
hanzo deploy
|
|
|
|
# View logs
|
|
hanzo logs --service web --follow
|
|
|
|
# Scale manually
|
|
hanzo scale web --replicas 4
|
|
|
|
# View cost breakdown
|
|
hanzo cost --period 30d
|
|
|
|
# Manage secrets
|
|
hanzo secrets set API_KEY=sk-...
|
|
|
|
# Open dashboard
|
|
hanzo dashboard
|
|
\end{lstlisting}
|
|
|
|
\subsection{Git-Based Deployment}
|
|
|
|
Pushing to a connected Git repository triggers automatic deployment:
|
|
|
|
\begin{enumerate}[leftmargin=1.4em]
|
|
\item Push triggers webhook.
|
|
\item Build system detects changes, constructs optimized image.
|
|
\item Preview deployment created for pull requests.
|
|
\item Production deployment on merge to main branch.
|
|
\item Automatic rollback if health checks fail within 5 minutes.
|
|
\end{enumerate}
|
|
|
|
\subsection{Preview Environments}
|
|
|
|
Every pull request automatically receives a preview environment with:
|
|
\begin{itemize}[leftmargin=1.1em]
|
|
\item Unique URL (e.g., \texttt{pr-42.my-app.hanzo.dev}).
|
|
\item Isolated database snapshot (copy-on-write from production).
|
|
\item Shared LLM gateway access with sandboxed cost tracking.
|
|
\item Automatic teardown on PR close.
|
|
\end{itemize}
|
|
|