test: add isolated install verification scripts
- Dockerfile.test: Ubuntu 24.04 container for clean-room setup testing - test_isolated.sh: mock-based test verifying auto-install URLs are called
This commit is contained in:
32
Dockerfile.test
Normal file
32
Dockerfile.test
Normal file
@@ -0,0 +1,32 @@
|
||||
FROM ubuntu:24.04
|
||||
|
||||
# Avoid interactive prompts during package installation
|
||||
ENV DEBIAN_FRONTEND=noninteractive
|
||||
|
||||
# Install basic dependencies
|
||||
RUN apt-get update && apt-get install -y \
|
||||
curl \
|
||||
bash \
|
||||
python3 \
|
||||
python3-pip \
|
||||
git \
|
||||
sudo \
|
||||
&& rm -rf /var/lib/apt/lists/*
|
||||
|
||||
# Install Node.js 22.x
|
||||
RUN curl -fsSL https://deb.nodesource.com/setup_22.x | bash - \
|
||||
&& apt-get install -y nodejs \
|
||||
&& rm -rf /var/lib/apt/lists/*
|
||||
|
||||
# Create a non-root user (setup script refuses to run as root)
|
||||
RUN useradd -m -s /bin/bash tester
|
||||
|
||||
# Switch to tester user
|
||||
USER tester
|
||||
WORKDIR /home/tester
|
||||
|
||||
# Copy project files
|
||||
COPY --chown=tester:tester . /home/tester/project/
|
||||
|
||||
# Run setup script
|
||||
CMD ["bash", "/home/tester/project/claude_setup.sh"]
|
||||
Reference in New Issue
Block a user