[ci skip] update .claude commands and skills: migrate to /remote skill, remove old executor
This commit is contained in:
parent
4cf8dc8ca1
commit
f41bea0ede
11 changed files with 19 additions and 183 deletions
|
|
@ -1,12 +1,9 @@
|
|||
# Kubectl Command
|
||||
|
||||
Run kubectl commands on the cluster via the remote executor.
|
||||
Run kubectl commands on the cluster via the `/remote` skill.
|
||||
|
||||
Use the remote executor relay:
|
||||
```bash
|
||||
echo "kubectl $ARGUMENTS" > /System/Volumes/Data/mnt/code/infra/.claude/cmd_input.txt
|
||||
sleep 2 && cat /System/Volumes/Data/mnt/code/infra/.claude/cmd_status.txt
|
||||
cat /System/Volumes/Data/mnt/code/infra/.claude/cmd_output.txt
|
||||
```
|
||||
/remote kubectl $ARGUMENTS
|
||||
```
|
||||
|
||||
Examples:
|
||||
|
|
|
|||
|
|
@ -3,9 +3,7 @@
|
|||
List all Kubernetes services deployed in this infrastructure.
|
||||
|
||||
```bash
|
||||
ls -1 /System/Volumes/Data/mnt/code/infra/modules/kubernetes/
|
||||
ls -1 modules/kubernetes/
|
||||
```
|
||||
|
||||
Provide a summary of the services, grouped by category if possible (media, monitoring, productivity, etc.).
|
||||
|
||||
Note: This command runs locally since it only reads the filesystem.
|
||||
|
|
|
|||
|
|
@ -1,13 +1,9 @@
|
|||
# Terraform Apply
|
||||
|
||||
Run terraform apply to deploy infrastructure changes via the remote executor.
|
||||
Run terraform apply to deploy infrastructure changes via the `/remote` skill.
|
||||
|
||||
Use the remote executor relay:
|
||||
```bash
|
||||
echo "terraform apply -target=module.kubernetes_cluster.module.<service> -auto-approve" > /System/Volumes/Data/mnt/code/infra/.claude/cmd_input.txt
|
||||
sleep 2 && cat /System/Volumes/Data/mnt/code/infra/.claude/cmd_status.txt
|
||||
# Wait for done:N status, then read output
|
||||
cat /System/Volumes/Data/mnt/code/infra/.claude/cmd_output.txt
|
||||
```
|
||||
/remote terraform apply -target=module.kubernetes_cluster.module.<service> -auto-approve
|
||||
```
|
||||
|
||||
ALWAYS use -target to speed up execution. Monitor the output and report any errors or successful completions.
|
||||
|
|
|
|||
|
|
@ -1,13 +1,9 @@
|
|||
# Terraform Plan
|
||||
|
||||
Run terraform plan to preview infrastructure changes via the remote executor.
|
||||
Run terraform plan to preview infrastructure changes via the `/remote` skill.
|
||||
|
||||
Use the remote executor relay:
|
||||
```bash
|
||||
echo "terraform plan -target=module.kubernetes_cluster.module.<service>" > /System/Volumes/Data/mnt/code/infra/.claude/cmd_input.txt
|
||||
sleep 2 && cat /System/Volumes/Data/mnt/code/infra/.claude/cmd_status.txt
|
||||
# Wait for done:N status, then read output
|
||||
cat /System/Volumes/Data/mnt/code/infra/.claude/cmd_output.txt
|
||||
```
|
||||
/remote terraform plan -target=module.kubernetes_cluster.module.<service>
|
||||
```
|
||||
|
||||
ALWAYS use -target to speed up execution. Summarize the planned changes, highlighting any resources being destroyed or recreated.
|
||||
|
|
|
|||
|
|
@ -1 +0,0 @@
|
|||
1769818605-3230-4984
|
||||
|
|
@ -1 +0,0 @@
|
|||
Subproject commit 7d7f5915f90db26e1a3fc52db6ac2e68d6d705a2
|
||||
|
|
@ -27,7 +27,6 @@ Need to control smart home devices, check sensor states, or run automations via
|
|||
- User asks about smart home devices
|
||||
|
||||
## Prerequisites
|
||||
- Remote executor must be running (Python commands require remote execution)
|
||||
- The `~/.venvs/claude` virtualenv must have `requests` package installed
|
||||
- Environment variables `HOME_ASSISTANT_URL` and `HOME_ASSISTANT_TOKEN` must be set in the venv activation script
|
||||
|
||||
|
|
@ -39,10 +38,10 @@ Need to control smart home devices, check sensor states, or run automations via
|
|||
```
|
||||
|
||||
### Execution Pattern (CRITICAL)
|
||||
Always use the remote executor with venv activation to get environment variables:
|
||||
Always activate the venv to get environment variables, then run via `/remote` skill:
|
||||
|
||||
```bash
|
||||
source ~/.venvs/claude/bin/activate && cd /home/wizard/code/infra && python .claude/home-assistant.py [command] [options]
|
||||
/remote source ~/.venvs/claude/bin/activate && cd /home/wizard/code/infra && python .claude/home-assistant.py [command] [options]
|
||||
```
|
||||
|
||||
### Available Commands
|
||||
|
|
@ -130,24 +129,12 @@ python .claude/home-assistant.py notify "Motion detected" --title "Security Aler
|
|||
python .claude/home-assistant.py notify "Hello" --target notify.mobile_app
|
||||
```
|
||||
|
||||
## Complete Example via Remote Executor
|
||||
## Complete Example
|
||||
|
||||
To turn on the living room light:
|
||||
|
||||
1. Write command to remote executor:
|
||||
```bash
|
||||
# Using Write tool to write to cmd_input.txt:
|
||||
source ~/.venvs/claude/bin/activate && cd /home/wizard/code/infra && python .claude/home-assistant.py on light.living_room
|
||||
```
|
||||
|
||||
2. Wait and check status:
|
||||
```bash
|
||||
sleep 2 && cat /System/Volumes/Data/mnt/wizard/code/infra/.claude/cmd_status.txt
|
||||
```
|
||||
|
||||
3. Read output:
|
||||
```bash
|
||||
cat /System/Volumes/Data/mnt/wizard/code/infra/.claude/cmd_output.txt
|
||||
/remote source ~/.venvs/claude/bin/activate && cd /home/wizard/code/infra && python .claude/home-assistant.py on light.living_room
|
||||
```
|
||||
|
||||
## Common Entity Domains
|
||||
|
|
|
|||
|
|
@ -23,7 +23,6 @@ Need to create, query, or manage calendar events in the user's Nextcloud calenda
|
|||
- Default calendar is always Nextcloud unless otherwise specified
|
||||
|
||||
## Prerequisites
|
||||
- Remote executor must be running (Python commands require remote execution)
|
||||
- The `~/.venvs/claude` virtualenv must have `caldav` and `icalendar` packages installed
|
||||
- Environment variables `NEXTCLOUD_USER` and `NEXTCLOUD_APP_PASSWORD` must be set in the venv activation script
|
||||
|
||||
|
|
@ -35,10 +34,10 @@ Need to create, query, or manage calendar events in the user's Nextcloud calenda
|
|||
```
|
||||
|
||||
### Execution Pattern (CRITICAL)
|
||||
Always use the remote executor with venv activation to get environment variables:
|
||||
Always activate the venv to get environment variables, then run via `/remote` skill:
|
||||
|
||||
```bash
|
||||
source ~/.venvs/claude/bin/activate && cd /home/wizard/code/infra && python .claude/calendar-query.py [command] [options]
|
||||
/remote source ~/.venvs/claude/bin/activate && cd /home/wizard/code/infra && python .claude/calendar-query.py [command] [options]
|
||||
```
|
||||
|
||||
### Available Commands
|
||||
|
|
@ -99,23 +98,12 @@ python .claude/calendar-query.py today --json
|
|||
python .claude/calendar-query.py week
|
||||
```
|
||||
|
||||
## Complete Example via Remote Executor
|
||||
## Complete Example
|
||||
|
||||
To create an event "Team offsite" from March 20-22, 2026:
|
||||
|
||||
1. Write command to remote executor:
|
||||
```bash
|
||||
echo 'source ~/.venvs/claude/bin/activate && cd /home/wizard/code/infra && python .claude/calendar-query.py create --title "Team offsite" --start "2026-03-20" --end "2026-03-23" --all-day' > /System/Volumes/Data/mnt/wizard/code/infra/.claude/cmd_input.txt
|
||||
```
|
||||
|
||||
2. Wait and check status:
|
||||
```bash
|
||||
sleep 3 && cat /System/Volumes/Data/mnt/wizard/code/infra/.claude/cmd_status.txt
|
||||
```
|
||||
|
||||
3. Read output:
|
||||
```bash
|
||||
cat /System/Volumes/Data/mnt/wizard/code/infra/.claude/cmd_output.txt
|
||||
/remote source ~/.venvs/claude/bin/activate && cd /home/wizard/code/infra && python .claude/calendar-query.py create --title "Team offsite" --start "2026-03-20" --end "2026-03-23" --all-day
|
||||
```
|
||||
|
||||
## Important Notes
|
||||
|
|
|
|||
|
|
@ -284,7 +284,7 @@ smtp_password = var.mailserver_accounts["info@viktorbarzin.me"]
|
|||
### 6. Apply Terraform
|
||||
|
||||
```bash
|
||||
# Via remote executor
|
||||
# Via /remote skill
|
||||
terraform init
|
||||
terraform apply -target=module.kubernetes_cluster.module.<service> -auto-approve
|
||||
```
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue