commit de73f80b437f19028943c66c5160a2561a01d6da Author: Torsten Raudssus Date: Tue Dec 3 00:05:31 2024 +0100 plandex image, simple setup, with sample script diff --git a/.dockerignore b/.dockerignore new file mode 100644 index 0000000..2e124b1 --- /dev/null +++ b/.dockerignore @@ -0,0 +1 @@ +plandex diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..38f65af --- /dev/null +++ b/Dockerfile @@ -0,0 +1,30 @@ +FROM --platform=linux/amd64 golang:1.21.3 + +ARG SRV_UID="1000" +ARG SRV_GID="1000" +ARG SRV_VERSION="0" + +ENV SRV_UID $SRV_UID +ENV SRV_GID $SRV_GID +ENV SRV_VERSION $SRV_VERSION +ENV SRV_APT_GET_INSTALL $SRV_APT_GET_INSTALL + +RUN apt-get update -y && \ + apt-get install -y git gcc g++ make $SRV_APT_GET_INSTALL && \ + apt-get clean && rm -rf /var/lib/apt/lists/* + +RUN ( id -g $SRV_GID || groupadd -g $SRV_GID srv ) && \ + ( id $SRV_UID || useradd -s /bin/bash -d /app -u $SRV_UID -g $SRV_GID srv ) && \ + install -o $SRV_UID -g $SRV_GID -d /app + +RUN curl -sL https://plandex.ai/install.sh | bash + +USER $SRV_UID:$SRV_GID + +RUN ln -s /app/.bash_history $HOME/.bash_history + +VOLUME /app + +WORKDIR /app + +CMD ["/bin/bash"] diff --git a/plandex b/plandex new file mode 100755 index 0000000..57ac7a2 --- /dev/null +++ b/plandex @@ -0,0 +1,4 @@ +#!/bin/sh + +docker run -it --rm -v$PWD:/app \ + src.ci/srv/plandex:latest /usr/local/bin/plandex $@