Spaces:
Running
Running
File size: 1,593 Bytes
475d9ff b6eff03 9c1e573 b6eff03 516fd01 b6eff03 516fd01 bc36e1b 14ea311 7ca89db 9c1e573 516fd01 b6eff03 516fd01 bbbc86c 516fd01 bbbc86c |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 |
FROM debian:latest AS puppy
# prep
RUN apt-get update \
&& apt-get install -y curl wget \
&& apt-get clean
RUN useradd -m -u 1000 user
USER user
ENV HOME=/home/user \
PATH=/home/user/.pixi/bin:$PATH \
PUP=/home/user/.pixi/bin/pup
RUN mkdir $HOME/puppy
WORKDIR $HOME/puppy
# install puppy
RUN curl -fsSL https://pixi.sh/install.sh | bash
RUN echo 'export PATH=$HOME/.pixi/bin:$PATH' >> $HOME/.bashrc
RUN . $HOME/.bashrc && \
curl -fsSL https://raw.githubusercontent.com/liquidcarbon/puppy/main/pup.sh | bash -s 3.13
RUN echo '#!/bin/bash' > $PUP && \
echo 'pixi run python /home/user/puppy/pup.py "$@"' >> $PUP && \
chmod +x $PUP
RUN . $HOME/.bashrc && pixi run uv init mo
RUN . $HOME/.bashrc && pixi run uv pip install -U marimo pandas
RUN echo 'export PATH=/home/user/puppy/.pixi/envs/default/bin:$PATH' >> $HOME/.bashrc
RUN . $HOME/.bashrc && \
$HOME/puppy/.pixi/envs/default/bin/python -c "import sys, marimo; print(f'Python path: {sys.executable}'); print(f'Marimo version: {marimo.__version__}')"
RUN . $HOME/.bashrc && \
$HOME/puppy/.pixi/envs/default/bin/python -c "import site, os, marimo; print(os.path.join(site.getsitepackages()[0], 'marimo', '_tutorials'))" > tutorials_path && \
cp -r $(cat tutorials_path) . && \
mv _tutorials marimo_tutorials && \
rm tutorials_path
EXPOSE 7860
CMD ["pixi", "run", "marimo", "tutorial", "intro", "--host", "0.0.0.0", "--port", "7860", "--no-token"]
# deploy without installing
# CMD ["pixi", "run", "uvx", "marimo", "tutorial", "intro", "--host", "0.0.0.0", "--port", "7860", "--no-token"] |