# Wordpress Cms

> WordPress CMS setup on Docker + Blocksy theme + MCP integration for autonomous content publishing

- **Type:** Skill
- **Install:** `agentstack add skill-humanerd-drew-opencode-drewgent-wordpress-cms`
- **Verified:** Yes — security-reviewed for prompt injection and unsafe behavior
- **Seller:** [humanerd-drew](https://agentstack.voostack.com/s/humanerd-drew)
- **Installs:** 0
- **Category:** [Cloud & Infrastructure](https://agentstack.voostack.com/c/cloud-infrastructure)
- **Latest version:** 0.1.0
- **License:** MIT
- **Upstream author:** [humanerd-drew](https://github.com/humanerd-drew)
- **Source:** https://github.com/humanerd-drew/opencode-drewgent/tree/main/skills/devops/wordpress-cms

## Install

```sh
agentstack add skill-humanerd-drew-opencode-drewgent-wordpress-cms
```

Requires the [AgentStack CLI](https://agentstack.voostack.com/docs/cli). Works with Claude Code, Cursor, and any MCP-compatible agent.

## About

# WordPress CMS

WordPress + Docker + Blocksy + MCP integration for YOUR_DOMAIN.

## Docker Setup

```yaml
# ~/.{{AGENT_NAME_LOWER}}/wordpress/docker-compose.yml
services:
  db:
    image: mysql:8.0
    container_name: YOUR_DOMAIN-db
    ports: ["3307:3306"]
    volumes:
      - /Volumes/YOUR_NAS/docker/wordpress/db:/var/lib/mysql
  wordpress:
    image: wordpress:6.7-php8.3-apache
    container_name: YOUR_DOMAIN-wp
    depends_on: [db]
    ports: ["8080:80"]
    volumes:
      - /Volumes/YOUR_NAS/docker/wordpress/wp-content:/var/www/html/wp-content
      - ~/.{{AGENT_NAME_LOWER}}/wordpress/wp-content/plugins:/var/www/html/wp-content/plugins
      - ~/.{{AGENT_NAME_LOWER}}/wordpress/wp-content/themes:/var/www/html/wp-content/themes
```

**pw 저장:** `~/.{{AGENT_NAME_LOWER}}/wordpress/.wp-env` (chmod 600)

## Blocksy Theme

Blocksy is the active theme. Free version supports:
- **Custom Fonts** upload (Noto Sans KR, Noto Serif KR) — included free
- **Header/Footer Builder** — drag and drop
- **Global Color Palette** — 10-color system with bronze accent (#8b7355)
- **Blog Layout** — card grid, list, masonry
- **Typography** — per-element font/size/line-height
- **Dark Mode** — built-in

### Setup via wp-cli

```bash
docker exec YOUR_DOMAIN-wp wp --allow-root theme install blocksy --activate
docker exec YOUR_DOMAIN-wp wp --allow-root plugin install blocksy-companion --activate
```

### Custom Fonts (Google Fonts)

MU plugin at `wp-content/mu-plugins/YOUR_PREFIX-fonts.php`:
```php
add_action("wp_enqueue_scripts", function() {
  wp_enqueue_style("YOUR_PREFIX-fonts",
    "https://fonts.googleapis.com/css2?family=Noto+Sans+KR:wght@300;400;500;700&family=Noto+Serif+KR:wght@400;600;700&family=JetBrains+Mono:wght@400;700&display=swap"
  );
});
```

### Color Palette (Blocksy)

```php
$palette = array(
  array("color" => "#1c1c1a", "id" => "color1"),   # text primary
  array("color" => "#6b6b68", "id" => "color2"),   # text secondary
  array("color" => "#9b9b97", "id" => "color3"),   # text tertiary
  array("color" => "#ffffff", "id" => "color4"),   # white
  array("color" => "#fafaf8", "id" => "color5"),   # bg
  array("color" => "#f2f2ee", "id" => "color6"),   # surface
  array("color" => "#e8e7e4", "id" => "color7"),   # border
  array("color" => "#8b7355", "id" => "color8"),   # accent (bronze)
  array("color" => "#7a6349", "id" => "color9"),   # accent hover
  array("color" => "#d4c4b0", "id" => "color10"),  # accent muted
);
set_theme_mod("blocksy_color_palette", $palette);
```

### .htaccess

WordPress Docker 이미지는 .htaccess rewrite rules를 자동 생성하지 않음. 수동 설정 필수:

```apache
# BEGIN WordPress

RewriteEngine On
RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]

# END WordPress
```

## WordPress MCP Server

Custom MCP server for autonomous agent→WordPress interaction.

**Path:** `~/.{{AGENT_NAME_LOWER}}/scripts/wordpress-mcp-server.js`
**Config:** `mcp_servers.wordpress` in `~/.hermes/config.yaml`
**Backend:** Node.js wrapping `docker exec YOUR_DOMAIN-wp wp --allow-root` via STDIO JSON-RPC 2.0

### Available Tools

| Tool | Params | Returns |
|------|--------|---------|
| create_post | title, content, category, tags, status | Post ID |
| upload_media | file_path (inside container), title | Media ID |
| list_posts | posts_per_page, status | JSON array |
| get_post | id | JSON |
| create_category | name, slug | Term ID |
| set_site_option | key, value | Success msg |
| set_theme_mod | key, value (JSON string) | Success msg |

### Test

```bash
printf '{"jsonrpc":"2.0","id":1,"method":"tools/list"}\n' | node ~/.{{AGENT_NAME_LOWER}}/scripts/wordpress-mcp-server.js
```

## Huly MCP Integration

Huly workspace "YOUR_WORKSPACE" with MCP server (`@bgx4k3p/huly-mcp-server@latest`).
81 tools available including issue management, project management, team management.

Key tools for content workflow:
- `create_issue` — 제목/설명/담당자/프로젝트 지정
- `list_issues` — 필터링 + 커서 페이지네이션
- `search_issues` — 풀텍스트 검색
- `get_issue` — 상세 내용 + 상태
- `update_issue` — 상태 변경 (e.g. "Todo" → "Done")
- `list_statuses` — 프로젝트별 상태 workflow 조회

## Site Structure

| Page | URL | Content |
|------|-----|---------|
| Home | / | 최근 글 + 프로젝트 소개 |
| Blog | /blog/ | 포스트 목록 (카드 그리드) |
| About | /about/ | 사이트 소개 |

Categories: build-log (Build Log), ai-tools (AI & Tools), systems (Systems), creative (Creative)

## wp-cli Cheatsheet

```bash
# Post management
docker exec YOUR_DOMAIN-wp wp --allow-root post create --post_title="T" --post_content="C" --post_status=publish --post_category=systems

# Theme/plugin
docker exec YOUR_DOMAIN-wp wp --allow-root theme install  --activate
docker exec YOUR_DOMAIN-wp wp --allow-root plugin install  --activate

# Options
docker exec YOUR_DOMAIN-wp wp --allow-root option update blogname "YOUR_SITE_NAME"
docker exec YOUR_DOMAIN-wp wp --allow-root rewrite flush

# Media
docker exec YOUR_DOMAIN-wp wp --allow-root media import /path/to/file.png --title="Logo"

# Custom PHP
docker exec YOUR_DOMAIN-wp wp --allow-root eval 'echo get_option("blogname");'
docker exec YOUR_DOMAIN-wp wp --allow-root eval-file /tmp/setup.php
```

## Path Pitfalls

- All paths in wp-cli commands inside container are **container paths** (/var/www/html/...)
- Host paths need `docker cp` before `docker exec`
- `.htaccess` must be manually written (Docker image bug)
- Always use `--allow-root` with wp-cli inside container
- env vars (DOCKER_HOST) needed when colima manages Docker

## Source & license

This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.

- **Author:** [humanerd-drew](https://github.com/humanerd-drew)
- **Source:** [humanerd-drew/opencode-drewgent](https://github.com/humanerd-drew/opencode-drewgent)
- **License:** MIT

Install and usage instructions live in the source repository linked above.

## Pricing

- **Free** — Free

## Security capabilities

Automated source analysis of v0.1.0 — what this tool can access:

- **Network access:** no
- **Filesystem access:** no
- **Shell / process execution:** no
- **Environment & secrets:** no
- **Dynamic code execution:** no

*"Yes" means the capability is present in the source — more access means more to trust, not that it is unsafe.*


## Versions

- **0.1.0** — security scan: passed — Imported from the upstream source.

## Links

- Listing page: https://agentstack.voostack.com/l/skill-humanerd-drew-opencode-drewgent-wordpress-cms
- Seller: https://agentstack.voostack.com/s/humanerd-drew
- Browse the marketplace: https://agentstack.voostack.com/browse

---
Listed on AgentStack — the marketplace for AI agent skills and MCP servers. Every listing is security-reviewed. Creators keep 70%.
