xiaohongshu
xiaohongshu
Conventions for service configuration and environment variables: naming, precedence, validation at startup, secrets handling, environment detection, and documentation patterns
Full skill instructions
มาตรฐานการจัดการ configuration และ environment variables ทุก service: naming, validation, defaults, และ secret handling ที่ทำให้ deploy ข้าม environments ได้อย่างมั่นใจ
<APP>_<CATEGORY>_<NAME> (ทั้งหมด UPPER_SNAKE_CASE)URL/URI ใช้ suffix เดียวกัน (APP_REDIS_URL), boolean ใช้ true|falseTOKEN, KEY (ต้องบอกบริบท เช่น APP_STRIPE_SECRET_KEY)กำหนดลำดับความสำคัญชัดเจน และ document ไว้ในทุก service:
.env.production) (เฉพาะ local/staging ที่อนุญาต).env (เฉพาะ local)required vs optional ชัดเจน.env.example (ให้ใส่เป็นค่าว่าง + comment ว่า “from secret manager”)APP_ENV=development|staging|production|testNODE_ENV เพียงอย่างเดียว (ใช้ร่วมได้ แต่ให้มี source-of-truth)APP_ENV.env.example ที่ครบ keys และมีคำอธิบายสั้น ๆAPP_HTTP_PORT=3000 (min/max ถ้ามี)import { z } from "zod";
const schema = z.object({
APP_ENV: z.enum(["development", "staging", "production", "test"]).default("development"),
APP_HTTP_PORT: z.coerce.number().int().min(1).max(65535).default(3000),
APP_DATABASE_URL: z.string().url(),
});
export type AppConfig = z.infer<typeof schema>;
export function loadConfig(env: Record<string, string | undefined> = process.env): AppConfig {
const result = schema.safeParse(env);
if (!result.success) {
throw new Error(`Invalid config: ${result.error.message}`);
}
return result.data;
}
# Format: <APP>_<CATEGORY>_<NAME>
# Database
APP_DB_HOST=localhost
APP_DB_PORT=5432
APP_DB_NAME=myapp
# External Services
APP_REDIS_URL=redis://localhost:6379
APP_STRIPE_API_URL=https://api.stripe.com
# Feature Flags
APP_FEATURE_NEW_CHECKOUT=true
# Secrets (loaded from secret manager)
APP_SECRET_DB_PASSWORD= # from Vault/AWS SM
APP_SECRET_API_KEY= # from Vault/AWS SM
Priority (highest to lowest):
1. Secret Manager (Vault, AWS SM)
2. Environment Variables
3. Environment-specific file (.env.production)
4. Default .env file
5. Code defaults
NODE_ENV แบบคาดเดายากxiaohongshu
technical spec
product ux expert
database patterns
Conduct multi-agent task orchestration and workflow coordination.
Initialize project with Conductor artifacts (product definition,
Expert in web animations, transitions, and motion design using Framer Motion and CSS
Creates Mermaid and ASCII diagrams for flowcharts, architecture, ERDs, state machines, mindmaps, and more. Use when user mentions diagram, flowchart, mermaid, ASCII diagram, text diagram, terminal diagram, visualize, C4, mindmap, architecture diagram, sequence diagram, ERD, or needs visual docume...
PostgreSQL bindings for H3 hexagonal grid system. Use when working with H3 cells in Postgres, including spatial indexing, geometry/geography integration, and raster analysis.
Context-Driven Development skill for projects using Conductor. Use this skill when you detect a `conductor/` directory in the project, when working on tasks defined in a `plan.md` file, or when the user asks about tracks, specs, or plans. Automatically applies TDD workflow, tracks task completion...
Display project status, active tracks, and next actions
Official Stakpak application containerization standard operating procedure, a step-by-step guidline to properly dockerize applications. This is a rule book curated by the Stakpak Team.
Generate, edit, and beat-sync AI video with leading models in one workspace.
The world's fastest calendar for remote work
Transform Your Design with AI Designer by ImgCreator.ai
Revolutionizing Video Production with AI-Powered Creativity
Extend an image past the frame and let AI fill the new aspect ratio.
Discover your celebrity doppelgänger with StarByFace!
ChainClarity explains 700+ crypto whitepapers in plain English, with layered summaries, comparisons, research tools, alerts, and a $4.99 Pro plan.
Opus.ai: Revolutionize Your Web Experience