setting-up-astro-project — Claude Code skill: Astro and Airflow setup
A skill that walks the agent through creating an Airflow project with the Astro CLI: folder layout, dependencies, connections and variables.
npx skills add astronomer/agents --skill setting-up-astro-project -a claude-codeWhat setting-up-astro-project does
The skill kicks in when you ask the agent to scaffold a new Airflow project or make sense of an existing one. It knows astro dev init and explains what the command produces: dags/, include/, plugins/, tests/, Dockerfile, packages.txt, requirements.txt and airflow_settings.yaml.
Dependencies go into requirements.txt for Python packages and packages.txt for OS-level ones. For a private index or custom scripts, the skill edits the Dockerfile on top of the Astro Runtime image. After any change it reminds you to run astro dev restart. Connections, variables and pools live in airflow_settings.yaml and load when the environment starts; you can also move them with astro dev object export and astro dev object import.
To catch DAG errors without booting the whole environment, run astro dev parse. The skill advises against passing --airflow-version or --runtime-version unless you need a specific pin: plain astro dev init picks the current Astro Runtime, while a version recalled from model memory may be stale. If you are not on Astro, it points you to the Apache Airflow Docker Compose quickstart for local dev and the Helm chart for production.
What it helps with
- scaffold a new Airflow project with the Astro CLI
- add Python and OS-level dependencies to a project
- declare connections, variables and pools in one file
- move environment settings between machines
- check DAGs for errors before starting the environment
Example prompts for the agent
- create a new Airflow project with astro dev init and show me the folder structure
- add the Snowflake provider and pandas to requirements.txt, then restart the environment
- set up the my_postgres connection and the env variable in airflow_settings.yaml
How to install setting-up-astro-project
1Skills CLI (Vercel)
npx skills add astronomer/agents --skill setting-up-astro-project -a claude-code2Manually: put the files in place
~/.claude/skills/setting-up-astro-project/SKILL.mdCopy the whole skill folder; for one project use .claude/skills/setting-up-astro-project/
1Skills CLI (Vercel)
npx skills add astronomer/agents --skill setting-up-astro-project -a codex2Manually: put the files in place
.agents/skills/setting-up-astro-project/SKILL.mdFor all projects use ~/.agents/skills/
1Skills CLI (Vercel)
npx skills add astronomer/agents --skill setting-up-astro-project -a cursor2Manually: put the files in place
.cursor/skills/setting-up-astro-project/SKILL.mdCursor also reads .agents/skills/ and .claude/skills/
1GitHub CLI
gh skill install astronomer/agents setting-up-astro-project2Manually: put the files in place
.github/skills/setting-up-astro-project/SKILL.md1Skills CLI (Vercel)
npx skills add astronomer/agents --skill setting-up-astro-project -a gemini-cli2Platform CLI
gemini skills install https://github.com/astronomer/agents --path skills/setting-up-astro-projectManually: put the files in place
.devin/skills/setting-up-astro-project/SKILL.mdThe legacy .windsurf/skills/ path still works
Skills CLI (Vercel)
npx skills add astronomer/agents --skill setting-up-astro-project -a opencodeClaude.ai
Zip the folder and upload it in Settings → Capabilities → Skills
Step by step, with commands for each platform: How to install skills in Claude Code: five ways
Questions about setting-up-astro-project
How do I install setting-up-astro-project in Claude?
Run npx skills add astronomer/agents --skill setting-up-astro-project -a claude-code. The skill file then lands at ~/.claude/skills/setting-up-astro-project/SKILL.md.
What does setting-up-astro-project do?
It guides the agent through initializing and configuring an Airflow project on Astro: creating the structure, adding dependencies, declaring connections and variables, and validating DAGs with astro dev parse.
Should I pass an Airflow version when creating a project?
The skill advises against --airflow-version and --runtime-version unless you want a specific pin. Without them astro dev init resolves to the current Astro Runtime, and you can read the installed version from the generated Dockerfile afterwards.
Source text
SKILL.md · Apache-2.0
---
name: setting-up-astro-project
description: Initialize and configure Astro/Airflow projects. Use when the user wants to create a new project, set up dependencies, configure connections/variables, or understand project structure. For running the local environment, see managing-astro-local-env.
---
# Astro Project Setup
This skill helps you initialize and configure Airflow projects using the Astro CLI.
> **To run the local environment**, see the **managing-astro-local-env** skill.
> **To write DAGs**, see the **authoring-dags** skill.
> **Open-source alternative:** If the user isn't on Astro, guide them to Apache Airflow's Docker Compose quickstart for local dev and the Helm chart for production. For deployment strategies, use the `deploying-airflow` skill.
---
## Initialize a New Project
```bash
astro dev init
```
> **Don't pass `--airflow-version` or `--runtime-version` unless the user explicitly asks for a specific pin.** Plain `astro dev init` resolves to the latest Astro Runtime — that's the right default. Specifying a version risks pinning to a stale value from training data. If the user wants to know what was installed, read the generated `Dockerfile` afterward instead of guessing.
Creates this structure:
```
project/
├── dags/ # DAG files
├── include/ # SQL, configs, supporting files
├── plugins/ # Custom Airflow plugins
├── tests/ # Unit tests
├── Dockerfile # Image customization
├── packages.txt # OS-level packages
├── requirements.txt # Python packages
└── airflow_settings.yaml # Connections, variables, pools
```
---
## Adding Dependencies
### Python Packages (requirements.txt)
```
apache-airflow-providers-snowflake==5.3.0
pandas==2.1.0
requests>=2.28.0
```
### OS Packages (packages.txt)
```
gcc
libpq-dev
```
### Custom Dockerfile
For complex setups (private PyPI, custom scripts):
```dockerfile
FROM quay.io/astronomer/astro-runtime:12.4.0
RUN pip install --extra-index-url https://pypi.example.com/simple my-package
```
**After modifying dependencies:** Run `astro dev restart`
---
## Configuring Connections & Variables
### airflow_settings.yaml
Loaded automatically on environment start:
```yaml
airflow:
connections:
- conn_id: my_postgres
conn_type: postgres
host: host.docker.internal
port: 5432
login: user
password: pass
schema: mydb
variables:
- variable_name: env
variable_value: dev
pools:
- pool_name: limited_pool
pool_slot: 5
```
### Export/Import
```bash
# Export from running environment
astro dev object export --connections --file connections.yaml
# Import to environment
astro dev object import --connections --file connections.yaml
```
---
## Validate Before Running
Parse DAGs to catch errors without starting the full environment:
```bash
astro dev parse
```
---
## Related Skills
- **managing-astro-local-env**: Start, stop, and troubleshoot the local environment
- **authoring-dags**: Write and validate DAGs (uses MCP tools)
- **testing-dags**: Test DAGs (uses MCP tools)
- **deploying-airflow**: Deploy DAGs to production (Astro, Docker Compose, Kubernetes)
© astronomer · Apache-2.0 · astronomer/agents