Code Service Defrag
jacob-dietle/context-os
This skill should be used to periodically defragment a multi-app/multi-service codebase — both CODE (duplicate deploy targets, colliding bindings, stale forks) and CONTEXT (parallel spec…
Guide the user through taking AsterMem live — on a cloud server, or on a machine they already own (home NAS, Raspberry Pi, this computer) exposed through Cloudflare Tunnel with no public IP.
The automated check flagged lines worth reading first. See the safety section below.
$ npx skills add Asterove/AsterMem --skill deploy-astermem -a claude-codeProject install by default; add -g for ~/.claude/skills/.
$ gh skill install Asterove/AsterMem deploy-astermem --agent claude-codeProject scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).
$ git clone --depth 1 https://github.com/Asterove/AsterMem.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skill/deploy-astermem .claude/skills/deploy-astermem && rm -rf skills-srcUse ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.
Claude Code skills documentation · loads skills from .claude/skills/
Install the "deploy-astermem" agent skill from https://github.com/Asterove/AsterMem/tree/main/skill/deploy-astermem into .claude/skills/deploy-astermem/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "deploy-astermem", then confirm the skill loads.Claude Code copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$skill-installer install https://github.com/Asterove/AsterMem/tree/main/skill/deploy-astermemType this inside Codex. $skill-installer <name> installs a curated skill from openai/skills. The installer writes to $CODEX_HOME/skills (default ~/.codex/skills). Restart Codex if the skill does not show up.
$ npx skills add Asterove/AsterMem --skill deploy-astermem -a codexProject install goes to .agents/skills/; add -g for ~/.codex/skills/.
$ gh skill install Asterove/AsterMem deploy-astermem --agent codexProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/Asterove/AsterMem.git skills-src && mkdir -p .agents/skills && cp -r skills-src/skill/deploy-astermem .agents/skills/deploy-astermem && rm -rf skills-srcUse ~/.agents/skills/ instead of .agents/skills for a personal install.
Codex skills documentation · loads skills from .agents/skills/
Install the "deploy-astermem" agent skill from https://github.com/Asterove/AsterMem/tree/main/skill/deploy-astermem into .agents/skills/deploy-astermem/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "deploy-astermem", then confirm the skill loads.Codex copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add Asterove/AsterMem --skill deploy-astermem -a cursorProject install goes to .agents/skills/; add -g for ~/.cursor/skills/.
$ gh skill install Asterove/AsterMem deploy-astermem --agent cursorProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/Asterove/AsterMem.git skills-src && mkdir -p .cursor/skills && cp -r skills-src/skill/deploy-astermem .cursor/skills/deploy-astermem && rm -rf skills-srcUse ~/.cursor/skills/ instead of .cursor/skills for a personal install.
Cursor skills documentation · loads skills from .cursor/skills/, .agents/skills/, .claude/skills/, .codex/skills/
Install the "deploy-astermem" agent skill from https://github.com/Asterove/AsterMem/tree/main/skill/deploy-astermem into .cursor/skills/deploy-astermem/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "deploy-astermem", then confirm the skill loads.Cursor copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gemini skills install https://github.com/Asterove/AsterMem.git --path skill/deploy-astermem--scope user (default) or --scope workspace; --path is the subfolder of the repo that holds the skill; --consent skips the security confirmation prompt.
$ npx skills add Asterove/AsterMem --skill deploy-astermem -a gemini-cliProject install goes to .agents/skills/; add -g for ~/.gemini/skills/.
$ gh skill install Asterove/AsterMem deploy-astermem --agent gemini-cliProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/Asterove/AsterMem.git skills-src && mkdir -p .gemini/skills && cp -r skills-src/skill/deploy-astermem .gemini/skills/deploy-astermem && rm -rf skills-srcUse ~/.gemini/skills/ instead of .gemini/skills for a personal install, then run /skills reload.
Gemini CLI skills documentation · loads skills from .gemini/skills/, .agents/skills/
Install the "deploy-astermem" agent skill from https://github.com/Asterove/AsterMem/tree/main/skill/deploy-astermem into .gemini/skills/deploy-astermem/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "deploy-astermem", then confirm the skill loads.Gemini CLI copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gh skill install Asterove/AsterMem deploy-astermemInstalls for Copilot at project scope by default; add --scope user for a personal install. Preview a skill first with gh skill preview. Needs GitHub CLI 2.90.0 or later (public preview).
$ npx skills add Asterove/AsterMem --skill deploy-astermem -a github-copilotProject install goes to .agents/skills/; add -g for ~/.copilot/skills/.
$ git clone --depth 1 https://github.com/Asterove/AsterMem.git skills-src && mkdir -p .github/skills && cp -r skills-src/skill/deploy-astermem .github/skills/deploy-astermem && rm -rf skills-srcUse ~/.copilot/skills/ instead of .github/skills for a personal install. Commit .github/skills so cloud agent and code review can use it.
GitHub Copilot skills documentation · loads skills from .github/skills/, .claude/skills/, .agents/skills/
Install the "deploy-astermem" agent skill from https://github.com/Asterove/AsterMem/tree/main/skill/deploy-astermem into .github/skills/deploy-astermem/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "deploy-astermem", then confirm the skill loads.GitHub Copilot copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add Asterove/AsterMem --skill deploy-astermem -a opencodeOpenCode documents no install command of its own. Project install goes to .agents/skills/; add -g for ~/.config/opencode/skills/.
$ gh skill install Asterove/AsterMem deploy-astermem --agent opencodeProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/Asterove/AsterMem.git skills-src && mkdir -p .opencode/skills && cp -r skills-src/skill/deploy-astermem .opencode/skills/deploy-astermem && rm -rf skills-srcUse ~/.config/opencode/skills/ instead of .opencode/skills for a personal install.
OpenCode skills documentation · loads skills from .opencode/skills/, .claude/skills/, .agents/skills/
Install the "deploy-astermem" agent skill from https://github.com/Asterove/AsterMem/tree/main/skill/deploy-astermem into .opencode/skills/deploy-astermem/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "deploy-astermem", then confirm the skill loads.OpenCode copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
deploy-astermemGuide the user through taking AsterMem live — on a cloud server, or on a machine they already own (home NAS, Raspberry Pi, this computer) exposed through Cloudflare Tunnel with no public IP.
Deploy Astermem is an agent skill from Asterove/AsterMem. Guide the user through taking AsterMem live — on a cloud server, or on a machine they already own (home NAS, Raspberry Pi, this computer) exposed through Cloudflare Tunnel with no public IP. Ask how they want to deploy first, then install Docker, bring up the service, expose it with HTTPS (Cloudflare Tunnel or Caddy), and harden security post-launch. Use when the user says "deploy to server", "go live", "bind a domain", "public access", "deploy AsterMem", "expose it with a tunnel", or asks how to run this project…
Its SKILL.md is about 3.2k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.
It sits in DevOps & Cloud, covering Containers. It works with Cloudflare, Docker, Amazon Web Services and Alibaba Cloud. The repository describes itself as: Self-hosted memory service for AI assistants. The licence is AGPL-3.0.
7 steps, taken from the step headings in SKILL.md.
Read from SKILL.md and the folder at commit 8bb57be. It shows what the files ask for, not the result of running them.
Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.
From allowed-tools in the SKILL.md frontmatter.
Shell commands in SKILL.md call:
cloudflareddockercurlsshgitapt-getbrewshscpFrom the folder's file list and the shell code blocks in SKILL.md.
Hosts in commands or code, which the agent is likely to contact:
pkg.cloudflare.comget.docker.comFrom URLs in SKILL.md, links to its own repository left out.
Names these keys or tokens, usually read from environment variables:
ASTERMEM_TOKENFrom names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.
Deploy Astermem loads about 3.2k tokens when it runs. Until then it costs about 161 tokens; SKILL.md has 1,420 words of instructions outside code blocks.
Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.
The automated check found patterns that need a careful read before installing.
p/desktop, disable system sleep (macOS: `sudo pmset -a sleep 0`, or System Settings → prevent sleep when on power) — a sssh-keygen -t ed25519 -N "" -f ~/.ssh/id_ed25519 2>/dev/null || true # skip if existscurl -fsSL https://get.docker.com | shf you have a model API key, write it to `.env` (refer to `.env.example`; compose picks it up automatically).Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.
The full file from Asterove/AsterMem at commit 8bb57be, republished under its AGPL-3.0 licence (© Asterove). 1,420 words, ~3,154 tokens.
.claude/skills/deploy-astermem/SKILL.md (or your agent's skills folder).Target state: AsterMem runs via Docker Compose (fixed port 8768, listening on localhost only) on a machine the user chooses, exposed to the internet with HTTPS — either through Cloudflare Tunnel or a Caddy reverse proxy. All data is persisted in that machine's data/ directory.
The process is executed by you (the agent) — locally or over SSH, do not throw commands at the user to run themselves. Check the output of each step before proceeding to the next. But do not touch anything before Step 0: ask the user what they want first.
Ask up front (use AskQuestion if available; ask only for what's missing):
AsterMem is a stateful long-running process (SQLite + on-disk vector index, all data in data/), so it needs a real machine — before recommending a rental, remind the user that Path B (a machine they already own + Cloudflare Tunnel) costs nothing:
cloudflared opens an outbound-only tunnel to Cloudflare's edge, so the machine needs no public IP, no router port forwarding, and no inbound firewall rules. Free plan is enough. Trade-off to state clearly: availability is tied to that machine and its network — it must stay powered on and online.
./start.sh), reuse it — read the port from config.yaml. Otherwise start it with Docker (Step 4; keep the 127.0.0.1:8768:8768 mapping)brew install cloudflaredcloudflare/cloudflared container with the dashboard token insteadservice at the actual local port. On macOS, cloudflared service install registers a launchd service; on Linux, systemdsudo pmset -a sleep 0, or System Settings → prevent sleep when on power) — a sleeping machine means an offline memory servicehttps://<domain>/api/auth/check, then go straight to Step 6 (hardening is mandatory — the service is now public)If going the Cloudflare Tunnel route (Step 5, Option A): no A record is needed — the tunnel creates the DNS record itself. Just confirm the domain's nameservers point to Cloudflare (dig NS example.com), then skip ahead.
Otherwise (Caddy route): have the user add an A record at their domain registrar: mem.example.com → server IP. Then verify locally — do not start installing Caddy until DNS has propagated (certificate issuance will fail):
dig +short mem.example.com # should output the server IPWhen using password login, install the local public key on the server first for passwordless access going forward:
ssh-keygen -t ed25519 -N "" -f ~/.ssh/id_ed25519 2>/dev/null || true # skip if exists
ssh-copy-id -p <port> <user>@<server_ip> # enter password once interactivelyIf ssh-copy-id cannot run interactively, fall back to sshpass (macOS: brew install sshpass). Pass the password via environment variable — never write plaintext passwords into scripts, files, or commit history:
sshpass -p "$SSH_PASS" ssh -o StrictHostKeyChecking=accept-new -p <port> <user>@<server_ip> 'echo ok'Once connected, probe the environment:
ssh <user>@<server_ip> 'cat /etc/os-release; docker --version; docker compose version'curl -fsSL https://get.docker.com | sh
systemctl enable --now dockerFor mainland China servers, if image pulls time out, configure mirror acceleration in /etc/docker/daemon.json then systemctl restart docker.
git clone https://github.com/Asterove/AsterMem.git /opt/astermem
cd /opt/astermemIf the server has difficulty accessing GitHub, pack and upload from the local machine instead:
# Run on local machine (exclude local data and dependencies)
tar czf /tmp/astermem.tgz --exclude=data --exclude=venv --exclude=web-ui/node_modules --exclude=.git .
scp /tmp/astermem.tgz <user>@<server_ip>:/tmp/
ssh <user>@<server_ip> 'mkdir -p /opt/astermem && tar xzf /tmp/astermem.tgz -C /opt/astermem'If you have a model API key, write it to .env (refer to .env.example; compose picks it up automatically).
Security critical: When using a domain route (Step 5, Option A or B), change the port mapping in docker-compose.yml to listen on localhost only, to avoid exposing port 8768 directly to the internet:
ports:
- "127.0.0.1:8768:8768"Start and verify:
docker compose up -d --build
curl -fsS http://127.0.0.1:8768/api/auth/check && echo OK| Route | Pick when | Inbound ports |
|---|---|---|
| A. Cloudflare Tunnel (preferred) | Domain is on Cloudflare, or machine is behind NAT / has no public IP | None |
| B. Caddy reverse proxy | Domain is at another registrar and user won't move it | 80, 443 |
| C. IP + port direct | No domain at all | 8768 |
Zero inbound ports (not even 80/443), HTTPS terminated at Cloudflare's edge, origin IP hidden. Prerequisite: the domain's nameservers are on Cloudflare (free plan is enough; moving nameservers takes minutes and the user only does it once).
Install cloudflared on the server:
curl -fsSL https://pkg.cloudflare.com/cloudflare-main.gpg -o /usr/share/keyrings/cloudflare-main.gpg
echo "deb [signed-by=/usr/share/keyrings/cloudflare-main.gpg] https://pkg.cloudflare.com/cloudflared any main" > /etc/apt/sources.list.d/cloudflared.list
apt-get update && apt-get install -y cloudflaredAuthorize and create the tunnel:
cloudflared tunnel login # prints a URL — send it to the user to open in their browser and pick the zone
cloudflared tunnel create astermem
cloudflared tunnel route dns astermem mem.example.com # creates the DNS record automaticallyWrite /etc/cloudflared/config.yml (get <UUID> from cloudflared tunnel list):
tunnel: <UUID>
credentials-file: /root/.cloudflared/<UUID>.json
ingress:
- hostname: mem.example.com
service: http://127.0.0.1:8768
- service: http_status:404Install as a service and verify:
cloudflared service install
systemctl enable --now cloudflared
curl -fsS https://mem.example.com/api/auth/check && echo OKIf the user prefers clicking over CLI, the equivalent is Cloudflare dashboard → Zero Trust → Networks → Tunnels → Create tunnel; it hands them a one-line cloudflared service install <token> command to run on the server, and the hostname → http://localhost:8768 mapping is configured in the dashboard.
Notes: keep the compose port on 127.0.0.1:8768:8768; no firewall changes needed (the tunnel is outbound-only — you can even close all inbound ports except SSH). Known limit: Cloudflare's free plan caps uploads at 100 MB per request, which can affect large zip imports.
Install Caddy on Debian/Ubuntu (official apt source; for other distros see caddyserver.com/docs/install), then write /etc/caddy/Caddyfile:
mem.example.com {
reverse_proxy 127.0.0.1:8768
}systemctl reload caddyCaddy will automatically issue and renew Let's Encrypt certificates, provided ports 80/443 are reachable and DNS has resolved (domains on mainland China servers must have ICP filing).
Firewall / cloud security group: Allow 80, 443 (and the SSH port); do not allow 8768. Cloud servers typically also need security group rules in the console — server-side ufw/firewalld alone is not enough.
Skip Steps 1 and 5, keep the compose port as "8768:8768", allow 8768 in the security group. No need for 80/443 or ICP filing. Users access via http://<IP>:8768. Clearly inform the user this is plaintext HTTP — a strong password is essential.
https://mem.example.com, log in with the default account admin / admin~/.astermem/credentials on the local machine:ASTERMEM_BASE_URL=https://mem.example.com
ASTERMEM_TOKEN=ast_xxxxxxxx- [ ] https://<domain> opens and certificate is valid (or http is accessible under IP approach)
- [ ] Default password has been changed, login toggle is enabled
- [ ] Port 8768 is not directly exposed to the internet (domain routes)
- [ ] Tunnel routes: cloudflared service is active and survives reboot; Path B: machine will not sleep
- [ ] docker compose ps shows container healthy (Docker deployments)
- [ ] (Optional) Provider test passed, semantic search is workingdata/ directory — backup = copy this directorygit pull && docker compose up -d --build in the project directorydocker compose exec astermem python server.py --reset-admin (resets to admin/admin without touching data)docker compose logs -f --tail 100© Asterove, AGPL-3.0. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file
Just SKILL.md in skill/deploy-astermem of Asterove/AsterMem.
Open the folder on GitHubat commit 8bb57be
Deploy Astermem next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.
| Skill | Stars | Used in | Tokens | Auto-check | Licence | Repo updated |
|---|---|---|---|---|---|---|
| Deploy Astermem this skillAsterove/AsterMem | 161 | — | ~3.2k | Automated safety check: Warn | AGPL-3.0 | |
| Code Service Defragjacob-dietle/context-os | 111 | — | ~3.7k | Automated safety check: Pass | MIT | |
| Devops SpecialistCaoMeiYouRen/caomei-auth | 220 | — | ~446 | Automated safety check: Notes | MIT | |
| Deployment Automationaiskillstore/marketplace | 430 | 1 repos | ~3k | Automated safety check: Notes | None | |
| Senior DevOps Toolkitmaslennikov-ig/claude-code-orchestrator-kit | 259 | 6 repos | ~1.1k | Automated safety check: Notes | Custom licence | |
| Setup Osworldxlang-ai/OSWorld-V2 | 351 | 1 repos | ~2.6k | Automated safety check: Notes | Apache-2.0 |
jacob-dietle/context-os
This skill should be used to periodically defragment a multi-app/multi-service codebase — both CODE (duplicate deploy targets, colliding bindings, stale forks) and CONTEXT (parallel spec…
CaoMeiYouRen/caomei-auth
修改 Docker、CI/CD、部署配置、环境变量、运行时参数、构建脚本和发布流程时使用。优先覆盖 Docker、Vercel、Cloudflare 与 GitHub Actions 场景。用户提到 deploy、Dockerfile、workflow、CI、CD、environment variables、build pipeline、release config 时都应触发。
aiskillstore/marketplace
Automate application deployment to cloud platforms and servers.
maslennikov-ig/claude-code-orchestrator-kit
Comprehensive DevOps skill for CI/CD, infrastructure automation, containerization, and cloud platforms (AWS, GCP, Azure). Includes pipeline setup…
xlang-ai/OSWorld-V2
Provision and verify an OSWorld-V2 checkout after clone. An agent skill from xlang-ai/OSWorld-V2.
nicepkg/auto-company
Deploy to Cloudflare (Workers, R2, D1), Docker, GCP (Cloud Run, GKE), Kubernetes (kubectl, Helm).
Asterove/AsterMem
Operate the user's self-hosted AsterMem service. An agent skill from Asterove/AsterMem.
Categories
Guide the user through taking AsterMem live — on a cloud server, or on a machine they already own (home NAS, Raspberry Pi, this computer) exposed through Cloudflare Tunnel with no public IP. Deploy Astermem is an agent skill from Asterove/AsterMem. Guide the user through taking AsterMem live — on a cloud server, or on a machine they already own (home NAS, Raspberry Pi, this computer) exposed through Cloudflare Tunnel with no public IP.
Deploy Astermem fits situations like: the user says deploy to server; deploy AsterMem; expose it with a tunnel; asks how to run this project on a VPS / cloud server (AWS.
Run `npx skills add Asterove/AsterMem --skill deploy-astermem -a claude-code`. Or copy the skill folder (skill/deploy-astermem in Asterove/AsterMem) into .claude/skills/deploy-astermem in your project. Claude Code loads it when a task matches its description.
Run `npx skills add Asterove/AsterMem --skill deploy-astermem -a codex`. Or copy the skill folder (skill/deploy-astermem in Asterove/AsterMem) into .agents/skills/deploy-astermem in your project. Codex loads it when a task matches its description.
Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add Asterove/AsterMem --skill deploy-astermem -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/deploy-astermem, .gemini/skills/deploy-astermem, .github/skills/deploy-astermem and .opencode/skills/deploy-astermem in your project.
Going by SKILL.md and its folder, Deploy Astermem needs the command-line tools its instructions call (cloudflared, docker, curl, ssh, git and apt-get) and credentials named ASTERMEM_TOKEN. Our summary lists: Docker; A credential in ASTERMEM_TOKEN.
SKILL.md names 2 domains. In commands or code: pkg.cloudflare.com and get.docker.com; the agent is likely to contact these when it follows the instructions. This is read from the text; nothing was executed.
Our automated static check of SKILL.md flagged 1 warning(s): mentions a credentials file (ssh keys, cloud or package-manager tokens). Read the flagged lines before installing; the check is not a guarantee either way.
Deploy Astermem is published under the AGPL-3.0 licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.
About 3.2k tokens (SKILL.md is roughly 13k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.
Skills that share tags, products or a category with Deploy Astermem: Code Service Defrag (jacob-dietle/context-os, 111 stars), Devops Specialist (CaoMeiYouRen/caomei-auth, 220 stars), Deployment Automation (aiskillstore/marketplace, 430 stars) and Senior DevOps Toolkit (maslennikov-ig/claude-code-orchestrator-kit, 259 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.
Asterove (a GitHub user) maintains it in Asterove/AsterMem, which has 161 GitHub stars. The repository holds 2 skills in this directory. The repository was last updated on August 4, 2026.
Source: Asterove/AsterMem on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.