# Entrypoint

> Generates entrypoint.sh script for Docker container runtime environment variable injection. Replaces placeholder values in built assets with actual environment variables at container startup.

- Skill: `majiayu000/entrypoint` (Agent Skill, multi-file: 2 files)
- Install (CLI): `npx skillmds@latest add majiayu000/entrypoint`
- Raw SKILL.md: https://api.skillmd.com/api/skills/majiayu000/entrypoint/raw
- Safety review: pending (external: skill-scanner PASS, skillspector PASS)
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: DevOps & Infra
- Author: majiayu000 (https://skillmd.com/u/majiayu000)
- Updated: 2026-09-09
- Page: https://skillmd.com/skills/majiayu000/entrypoint

---


# Entrypoint Script Skill

## Purpose
Generate entrypoint.sh script for Docker container runtime environment variable injection.

## Output
Create the file: `entrypoint.sh`

## Example File
See: `examples.md` in this directory for complete examples and detailed explanations.


## Notes
- Enables runtime environment variable injection into built JavaScript files
- Uses `envsubst` to replace placeholders with actual environment variable values
- Processes all app*.js files in nginx html directory
- Sets errexit and nounset for safer script execution
- Starts nginx in foreground mode for Docker container
- Requires gettext-base package for envsubst command
- Must be executable (chmod +x entrypoint.sh)

