create-claude-workspace 1.1.13 → 1.1.14

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -4,6 +4,19 @@ RUN apt-get update && \
4
4
  apt-get install -y --no-install-recommends git ca-certificates curl gosu && \
5
5
  apt-get clean && rm -rf /var/lib/apt/lists/*
6
6
 
7
+ # GitHub CLI (gh)
8
+ RUN curl -fsSL https://cli.github.com/packages/githubcli-archive-keyring.gpg \
9
+ -o /usr/share/keyrings/githubcli-archive-keyring.gpg && \
10
+ echo "deb [arch=$(dpkg --print-architecture) signed-by=/usr/share/keyrings/githubcli-archive-keyring.gpg] https://cli.github.com/packages stable main" \
11
+ > /etc/apt/sources.list.d/github-cli.list && \
12
+ apt-get update && apt-get install -y --no-install-recommends gh && \
13
+ apt-get clean && rm -rf /var/lib/apt/lists/*
14
+
15
+ # GitLab CLI (glab)
16
+ RUN curl -fsSL "https://gitlab.com/gitlab-org/cli/-/releases/permalink/latest/downloads/glab_$(dpkg --print-architecture).deb" \
17
+ -o /tmp/glab.deb && \
18
+ dpkg -i /tmp/glab.deb && rm /tmp/glab.deb
19
+
7
20
  # Non-root user — Claude Code refuses --dangerously-skip-permissions as root
8
21
  RUN useradd -m -s /bin/bash claude && \
9
22
  mkdir -p /home/claude/.claude && \
@@ -10,6 +10,8 @@ services:
10
10
  - ANTHROPIC_API_KEY
11
11
  - NPM_TOKEN
12
12
  - NPM_REGISTRY
13
+ - GH_TOKEN
14
+ - GITLAB_TOKEN
13
15
 
14
16
  volumes:
15
17
  claude-home:
@@ -24,4 +24,30 @@ fi
24
24
  chown claude:claude /home/claude
25
25
  chown -R claude:claude /home/claude/.claude 2>/dev/null || true
26
26
 
27
+ # Git platform auth — configure gh/glab from env vars if set
28
+ if [[ -n "${GH_TOKEN:-}" ]]; then
29
+ echo "GH_TOKEN detected — GitHub CLI authenticated."
30
+ fi
31
+ if [[ -n "${GITLAB_TOKEN:-}" ]]; then
32
+ echo "GITLAB_TOKEN detected — GitLab CLI authenticated."
33
+ fi
34
+
35
+ # Auth pre-check — fail fast if no credentials available
36
+ if [[ -z "${ANTHROPIC_API_KEY:-}" ]]; then
37
+ creds="/home/claude/.claude/.credentials.json"
38
+ if [[ ! -f "$creds" ]] || [[ ! -s "$creds" ]]; then
39
+ echo ""
40
+ echo "ERROR: No Claude authentication found."
41
+ echo ""
42
+ echo " Option 1 — On your HOST machine:"
43
+ echo " claude auth login"
44
+ echo " Then re-run docker-run.mjs"
45
+ echo ""
46
+ echo " Option 2 — API key:"
47
+ echo " ANTHROPIC_API_KEY=sk-... node .claude/scripts/docker-run.mjs"
48
+ echo ""
49
+ exit 1
50
+ fi
51
+ fi
52
+
27
53
  exec gosu claude "$@"
@@ -146,6 +146,10 @@ npm Publishing (optional):
146
146
  Set NPM_TOKEN=npm_XXXXX before running.
147
147
  Optionally: NPM_REGISTRY=npm.pkg.github.com (default: registry.npmjs.org)
148
148
 
149
+ Git Platform (optional — for push, MR/PR, issues):
150
+ GitHub: set GH_TOKEN=ghp_XXXXX before running
151
+ GitLab: set GITLAB_TOKEN=glpat-XXXXX before running
152
+
149
153
  Examples:
150
154
  node .claude/scripts/docker-run.mjs
151
155
  node .claude/scripts/docker-run.mjs --max-iterations 20
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "create-claude-workspace",
3
- "version": "1.1.13",
3
+ "version": "1.1.14",
4
4
  "description": "Scaffold a project with Claude Code agents for autonomous AI-driven development",
5
5
  "type": "module",
6
6
  "bin": {