Compare commits
2 Commits
6541791383
...
18f559c4e6
| Author | SHA1 | Date | |
|---|---|---|---|
| 18f559c4e6 | |||
| c909668246 |
17
Dockerfile
17
Dockerfile
@@ -39,16 +39,21 @@ RUN apt-get update && apt-get install -y --no-install-recommends \
|
|||||||
&& apt-get install -y nodejs \
|
&& apt-get install -y nodejs \
|
||||||
&& rm -rf /var/lib/apt/lists/*
|
&& rm -rf /var/lib/apt/lists/*
|
||||||
|
|
||||||
# Install yq (v4.x)
|
# Install yq (v4.x) with checksum verification
|
||||||
RUN YQ_VERSION="v4.40.5" && \
|
RUN YQ_VERSION="v4.40.5" && \
|
||||||
|
YQ_SHA256="0d6aaf1cf44a8d18fbc7ed0ef14f735a8df8d2e314c4cc0f0242d35c0a440c95" && \
|
||||||
wget https://github.com/mikefarah/yq/releases/download/${YQ_VERSION}/yq_linux_amd64 -O /usr/bin/yq && \
|
wget https://github.com/mikefarah/yq/releases/download/${YQ_VERSION}/yq_linux_amd64 -O /usr/bin/yq && \
|
||||||
|
echo "${YQ_SHA256} /usr/bin/yq" | sha256sum -c - && \
|
||||||
chmod +x /usr/bin/yq
|
chmod +x /usr/bin/yq
|
||||||
|
|
||||||
# Install OpenShift CLI (oc)
|
# Install OpenShift CLI (oc) with checksum verification
|
||||||
RUN OC_VERSION="stable" && \
|
RUN OC_VERSION="stable" && \
|
||||||
wget https://mirror.openshift.com/pub/openshift-v4/clients/ocp/${OC_VERSION}/openshift-client-linux.tar.gz -O /tmp/oc.tar.gz && \
|
OC_BASE_URL="https://mirror.openshift.com/pub/openshift-v4/clients/ocp/${OC_VERSION}" && \
|
||||||
tar -xvf /tmp/oc.tar.gz -C /usr/bin/ oc && \
|
wget ${OC_BASE_URL}/openshift-client-linux.tar.gz -O /tmp/openshift-client-linux.tar.gz && \
|
||||||
rm /tmp/oc.tar.gz && chmod +x /usr/bin/oc
|
wget ${OC_BASE_URL}/sha256sum.txt -O /tmp/sha256sum.txt && \
|
||||||
|
cd /tmp && grep "openshift-client-linux.tar.gz$" sha256sum.txt | sha256sum -c - && \
|
||||||
|
tar -xvf openshift-client-linux.tar.gz -C /usr/bin/ oc && \
|
||||||
|
rm openshift-client-linux.tar.gz sha256sum.txt && chmod +x /usr/bin/oc
|
||||||
|
|
||||||
# Install Python tools for LLM work
|
# Install Python tools for LLM work
|
||||||
RUN pip3 install --no-cache-dir --break-system-packages \
|
RUN pip3 install --no-cache-dir --break-system-packages \
|
||||||
@@ -125,5 +130,5 @@ for keytype in rsa ecdsa ed25519; do \
|
|||||||
fi; \
|
fi; \
|
||||||
done && \
|
done && \
|
||||||
chmod 600 /data/ssh/ssh_host_*_key && \
|
chmod 600 /data/ssh/ssh_host_*_key && \
|
||||||
if [ -f /data/.gitconfig ]; then ln -sf /data/.gitconfig ~/.gitconfig; fi && \
|
ln -sf /data/.gitconfig ~/.gitconfig && \
|
||||||
/usr/sbin/sshd -D -e -f /etc/ssh/sshd_config"]
|
/usr/sbin/sshd -D -e -f /etc/ssh/sshd_config"]
|
||||||
|
|||||||
12
README.md
12
README.md
@@ -19,6 +19,18 @@ This container provides a stable, tool-rich environment for the AI agent to:
|
|||||||
- **Kubernetes:** OpenShift CLI (oc)
|
- **Kubernetes:** OpenShift CLI (oc)
|
||||||
- **Search:** ripgrep (fast grep alternative)
|
- **Search:** ripgrep (fast grep alternative)
|
||||||
|
|
||||||
|
## Prerequisites
|
||||||
|
|
||||||
|
Before deploying, create the kubeconfig secret to give the container kubectl/oc access:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
kubectl create secret generic kube \
|
||||||
|
--from-file=config=$HOME/.kube/breakglass-system-admin.kubeconfig \
|
||||||
|
-n clawdbox
|
||||||
|
```
|
||||||
|
|
||||||
|
**Note:** This kubeconfig is mounted at `/home/claw/.kube/config` inside the container.
|
||||||
|
|
||||||
## Deployment (OpenShift / K8s)
|
## Deployment (OpenShift / K8s)
|
||||||
|
|
||||||
1. **Build Image:**
|
1. **Build Image:**
|
||||||
|
|||||||
@@ -23,7 +23,7 @@ spec:
|
|||||||
runAsNonRoot: true
|
runAsNonRoot: true
|
||||||
initContainers:
|
initContainers:
|
||||||
- name: setup-ssh
|
- name: setup-ssh
|
||||||
image: busybox:latest
|
image: busybox:1.36
|
||||||
command:
|
command:
|
||||||
- sh
|
- sh
|
||||||
- -c
|
- -c
|
||||||
|
|||||||
Reference in New Issue
Block a user