File size: 1,112 Bytes
05cb51e d96aee8 05cb51e d96aee8 05cb51e d96aee8 05cb51e d96aee8 |
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 |
FROM ubuntu:22.04
ENV DEBIAN_FRONTEND=noninteractive
ENV R3_REGISTRATION_CODE="7D3A85E9-0DDA-503C-B521-052F1F15D160"
# Update and upgrade using both apt and apt-get
RUN apt update && apt upgrade -y && \
apt-get update && apt-get upgrade -y && \
apt-get install -y \
python3 python3-pip \
nodejs npm \
openssh-client \
neofetch \
git \
curl \
procps \
ca-certificates && \
apt-get clean && rm -rf /var/lib/apt/lists/*
# Install Telegram bot library
RUN pip3 install --no-cache-dir pytelegrambotapi
# Generate fresh SSH key (if needed)
RUN mkdir -p /root/.ssh && \
ssh-keygen -t rsa -f /root/.ssh/id_rsa -N '' && \
chmod 700 /root/.ssh && chmod 600 /root/.ssh/id_rsa
# Install remote.it agent using the registration code environment variable
RUN sh -c "$(curl -L https://downloads.remote.it/remoteit/install_agent.sh)"
# Dummy file to keep container alive
RUN mkdir -p /app && echo "Remote.it Agent Running..." > /app/index.html
WORKDIR /app
EXPOSE 7860
# Start dummy HTTP server and remote.it agent
CMD python3 -m http.server 7860 & remoteit agent start |