planetscale
하는 일
PlanetScale은 MySQL 호환 데이터베이스를 관리하는 서비스입니다. 개발용 브랜치 같은 기능과 무중단 업데이트를 통해 데이터베이스를 안전하게 만들고 수정할 수 있습니다.
사용하는 경우
- ✓업데이트 중에도 멈추지 않는 MySQL 데이터베이스가 필요할 때.
- ✓운영 환경에 올리기 전에 별도 환경에서 데이터베이스 변경을 테스트할 때.
- ✓확장 가능하고 안정적인 데이터베이스가 필요한 애플리케이션을 만들 때.
스킬 링크
https://github.com/sickn33/agentic-awesome-skills/blob/main/plugins/agentic-awesome-skills-claude/skills/planetscale/SKILL.md복사해서 AI(Claude, ChatGPT, Cursor)에 붙여넣고 지침을 따르도록 요청하세요.
사용 방법
가장 쉬운 방법입니다. 메시지를 복사해 AI에 붙여넣으세요. AI가 스킬을 읽고 지침을 따릅니다.
바로 붙여넣을 수 있는 메시지
Claude Code, Codex, Cursor용입니다. 프로젝트 폴더에서 실행하면 스킬이 설치됩니다.
SKILL.md를 다운로드해 에이전트의 스킬 폴더에 넣으세요.
AI에게 요청하는 예시
“‘us-east’ 지역에 ‘my-project’라는 새 데이터베이스를 어떻게 만들 수 있나요?”
매주 새 스킬 5개. 읽는 데 1분.
작동 방식
`pscale` 명령줄 도구를 사용해 PlanetScale과 상호작용합니다. 데이터베이스를 만들고, Git과 비슷한 워크플로로 스키마(데이터베이스 구조)를 관리하며, 변경 사항을 안전하게 배포할 수 있습니다.
기술 내용 (원본 SKILL.md)
작성자의 영어 원문을 GitHub에서 그대로 가져왔습니다.
PlanetScale
Use PlanetScale for serverless MySQL-compatible databases with non-blocking schema change workflows built on Vitess.
When to Use
- You need a managed MySQL-compatible database with zero-downtime migrations.
- Your team wants Git-like branching for schema development.
- You are building a serverless or edge application that benefits from connection pooling.
- You need horizontal sharding without managing Vitess directly.
Prerequisites
- A PlanetScale account (free tier available).
- The
pscaleCLI installed locally. - Node.js 18+ if using Prisma or other ORM integrations.
Install the pscale CLI
# macOS
brew install planetscale/tap/pscale
# Linux (deb)
curl -fsSL https://github.com/planetscale/cli/releases/latest/download/pscale_linux_amd64.deb -o pscale.deb
sudo dpkg -i pscale.deb
# Verify installation
pscale version
# Authenticate
pscale auth login
Create and Manage Databases
# Create a new database
pscale database create my-app --region us-east
# List databases
pscale database list
# Show database info
pscale database show my-app
# Delete a database (destructive)
pscale database delete my-app
Branching Workflow
PlanetScale branches work like Git branches for your database schema. The main branch is the production branch by default.
# Create a development branch from main
pscale branch create my-app add-users-table
# List all branches
pscale branch list my-app
# Open a shell on the branch to apply schema changes
pscale shell my-app add-users-table
Apply Schema Changes on a Branch
-- Inside the pscale shell on the development branch
CREATE TABLE users (
id BIGINT NOT NULL AUTO_INCREMENT PRIMARY KEY,
email VARCHAR(255) NOT NULL,
name VARCHAR(255) NOT NULL,
created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP,
updated_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
UNIQUE KEY idx_users_email (email)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
CREATE TABLE orders (
id BIGINT NOT NULL AUTO_INCREMENT PRIMARY KEY,
user_id BIGINT NOT NULL,
total DECIMAL(10,2) NOT NULL DEFAULT 0.00,
status ENUM('pending','paid','shipped','cancelled') DEFAULT 'pending',
created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP,
KEY idx_orders_user_id (user_id),
KEY idx_orders_status (status)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
PlanetScale does not enforce foreign keys at the database level. Use application-level constraints or Vitess-level routing rules instead.
Deploy Requests
Deploy requests are the pull-request equivalent for database schemas. They show a diff, run linting, and merge non-blocking into production.
# Create a deploy request from branch to main
pscale deploy-request create my-app add-users-table
# List open deploy requests
pscale deploy-request list my-app
# Show diff for a deploy request
pscale deploy-request diff my-app 1
# Deploy (merge) the request
pscale deploy-request deploy my-app 1
# Close without deploying
pscale deploy-request close my-app 1
# Delete the branch after successful deploy
pscale branch delete my-app add-users-table
Connection Strings and Proxying
# Create a password (connection credential) for a branch
pscale password create my-app main production-creds
# Output includes host, username, and password for the connection string:
# mysql://USERNAME:PASSWORD@HOST/my-app?sslmode=verify_identity
# Proxy a branch to localhost for local development (no password needed)
pscale connect my-app add-users-table --port 3306
Environment Variable Pattern
# .env (local development using pscale connect)
DATABASE_URL="mysql://root@127.0.0.1:3306/my-app"
# .env.production (using PlanetScale connection string)
DATABASE_URL="mysql://USERNAME:PASSWORD@us-east.connect.psdb.cloud/my-app?sslaccept=strict"
Prisma Integration
// prisma/schema.prisma
datasource db {
provider = "mysql"
url = env("DATABASE_URL")
relationMode = "prisma" // required — PlanetScale does not support foreign keys
}
model User {
id Int @id @default(autoincrement())
email String @unique
name String
orders Order[]
createdAt DateTime @default(now())
updatedAt DateTime @updatedAt
}
model Order {
id Int @id @default(autoincrement())
userId Int
total Decimal @db.Decimal(10, 2)
…
자주 묻는 질문
PlanetScale의 ‘브랜치’란 무엇인가요?
개발하고 새 기능이나 변경을 테스트하는 데 쓰이는, 데이터베이스의 별도 사본입니다. 메인(운영) 데이터베이스에는 영향을 주지 않습니다.
‘Deploy Request’란 무엇인가요?
브랜치에서 한 변경 사항을 메인 브랜치에 합치는 요청입니다. 데이터베이스용 코드 리뷰와 같아서, 차이점을 보여 주고 안전한 배포를 가능하게 합니다.
PlanetScale을 쓰려면 돈을 내야 하나요?
아니요, 시작할 수 있는 무료 요금제가 있습니다. 더 고급 기능이나 더 큰 용량이 필요할 때만 비용을 냅니다.
상세 정보
작성자의 원본 설명
Operate MySQL-compatible databases on PlanetScale with branching workflows, safe migrations, and production rollouts.
인기도
- GitHub 스타
- 48k
- 순위
- #5452
- 라이선스
- MIT
- 업데이트
- 2026. 10. 15.
댓글
- …
이 저장소의 다른 스킬
00-andruia-consultant
48k에이전트가 AI 프로젝트를 시작하거나 개선할 수 있도록 코드를 분석하고 스페인어로 실행 계획을 세워 줍니다.
007
48k에이전트가 보안 감사와 위협 모델링을 수행해 공격과 취약점으로부터 프로젝트를 보호하도록 돕습니다.
10-andruia-skill-smith
48k에이전트가 AI 도구의 작동 방식을 정의하고 문서를 쓰며 구조를 검증하도록 돕습니다.
20-andruia-niche-intelligence
48k에이전트가 신뢰할 수 있는 자료를 바탕으로 특정 산업의 맥락, 규칙, 사용 패턴, 위험을 정리한 요약을 만들도록 돕습니다.
비슷한 스킬
discrawl
394k에이전트가 저장된 로컬 Discord 메시지 보관본을 검색하고 요약하며, 최신 상태를 확인하고 다이렉트 메시지를 읽도록 돕습니다.
clickhouse-io
280k에이전트가 ClickHouse 데이터베이스의 쿼리와 스키마를 최적화하도록 돕습니다. 고성능 분석 작업의 모범 사례를 적용합니다. 분석 쿼리가 느릴 때 씁니다.
scientific-db-pubmed-database
280k생의학 분야의 과학 논문을 에이전트가 검색하도록 돕습니다. 특정 의학 정보가 필요한 연구에 유용합니다.