hackatime/Dockerfile.dev
2025-05-13 14:55:28 -04:00

32 lines
No EOL
696 B
Text

FROM ruby:3.4.3
# Install system dependencies
RUN apt-get update -qq && \
apt-get install --no-install-recommends -y \
build-essential \
git \
libpq-dev \
libyaml-dev \
postgresql-client \
libvips \
pkg-config \
curl \
vim \
&& rm -rf /var/lib/apt/lists/* /var/cache/apt/archives
# Set working directory
WORKDIR /app
# Install application dependencies
COPY Gemfile Gemfile.lock ./
RUN bundle install
# Add a script to be executed every time the container starts
COPY entrypoint.dev.sh /usr/bin/
RUN chmod +x /usr/bin/entrypoint.dev.sh
ENTRYPOINT ["entrypoint.dev.sh"]
EXPOSE 3000
# Start the main process
CMD ["rails", "server", "-b", "0.0.0.0"]