Update Dockerfile (#1581)
This commit is contained in:
parent
50f5620cd5
commit
4504d963d9
21
Dockerfile
21
Dockerfile
|
|
@ -1,5 +1,7 @@
|
|||
FROM bitnami/minideb:latest
|
||||
|
||||
Label MAINTAINER Amir Pourmand
|
||||
|
||||
RUN apt-get update -y
|
||||
|
||||
# add locale
|
||||
|
|
@ -19,17 +21,20 @@ RUN apt-get install imagemagick -y
|
|||
RUN apt-get install python3-pip -y
|
||||
RUN python3 -m pip install jupyter --break-system-packages
|
||||
|
||||
# clean everything
|
||||
RUN apt-get clean \
|
||||
&& rm -rf /var/lib/apt/lists/
|
||||
RUN pip3 cache purge
|
||||
|
||||
# ENV GEM_HOME='root/gems' \
|
||||
# PATH="root/gems/bin:${PATH}"
|
||||
|
||||
# install jekyll and dependencies
|
||||
RUN gem install jekyll bundler
|
||||
|
||||
RUN mkdir /srv/jekyll
|
||||
|
||||
ADD Gemfile /srv/jekyll
|
||||
|
||||
WORKDIR /srv/jekyll
|
||||
|
||||
RUN bundle install
|
||||
|
||||
# Set Jekyll environment
|
||||
ENV JEKYLL_ENV=production
|
||||
|
||||
EXPOSE 8080
|
||||
|
||||
CMD ["/bin/bash", "-c", "rm -f Gemfile.lock && exec jekyll serve --watch --port=8080 --host=0.0.0.0 --livereload --verbose --trace"]
|
||||
|
|
|
|||
|
|
@ -3,11 +3,7 @@ version: "3"
|
|||
services:
|
||||
jekyll:
|
||||
image: amirpourmand/al-folio
|
||||
container_name: al-folio-website
|
||||
command: bash -c "
|
||||
rm -f Gemfile.lock
|
||||
&& bundler exec jekyll serve --watch --port=8080 --host=0.0.0.0 --livereload --verbose --trace"
|
||||
ports:
|
||||
- 8080:8080
|
||||
volumes:
|
||||
- .:/srv/jekyll
|
||||
- .:/srv/jekyll
|
||||
|
|
|
|||
|
|
@ -4,11 +4,7 @@ services:
|
|||
jekyll_custom:
|
||||
build: .
|
||||
image: al-folio-local-docker
|
||||
container_name: al-folio-local-website
|
||||
command: bash -c "
|
||||
rm -f Gemfile.lock
|
||||
&& bundler exec jekyll serve --watch --port=8080 --host=0.0.0.0 --livereload --verbose --trace"
|
||||
ports:
|
||||
- 8080:8080
|
||||
volumes:
|
||||
- .:/srv/jekyll
|
||||
- .:/srv/jekyll
|
||||
|
|
|
|||
Loading…
Reference in New Issue