Skip to content

Commit 4504d96

Browse files
authored
Update Dockerfile (alshedivat#1581)
1 parent 50f5620 commit 4504d96

File tree

3 files changed

+15
-18
lines changed

3 files changed

+15
-18
lines changed

Dockerfile

Lines changed: 13 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
FROM bitnami/minideb:latest
2+
23
Label MAINTAINER Amir Pourmand
4+
35
RUN apt-get update -y
46

57
# add locale
@@ -19,17 +21,20 @@ RUN apt-get install imagemagick -y
1921
RUN apt-get install python3-pip -y
2022
RUN python3 -m pip install jupyter --break-system-packages
2123

22-
# clean everything
23-
RUN apt-get clean \
24-
&& rm -rf /var/lib/apt/lists/
25-
RUN pip3 cache purge
26-
27-
# ENV GEM_HOME='root/gems' \
28-
# PATH="root/gems/bin:${PATH}"
29-
3024
# install jekyll and dependencies
3125
RUN gem install jekyll bundler
26+
3227
RUN mkdir /srv/jekyll
28+
3329
ADD Gemfile /srv/jekyll
30+
3431
WORKDIR /srv/jekyll
32+
3533
RUN bundle install
34+
35+
# Set Jekyll environment
36+
ENV JEKYLL_ENV=production
37+
38+
EXPOSE 8080
39+
40+
CMD ["/bin/bash", "-c", "rm -f Gemfile.lock && exec jekyll serve --watch --port=8080 --host=0.0.0.0 --livereload --verbose --trace"]

docker-compose.yml

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,7 @@ version: "3"
33
services:
44
jekyll:
55
image: amirpourmand/al-folio
6-
container_name: al-folio-website
7-
command: bash -c "
8-
rm -f Gemfile.lock
9-
&& bundler exec jekyll serve --watch --port=8080 --host=0.0.0.0 --livereload --verbose --trace"
106
ports:
117
- 8080:8080
128
volumes:
13-
- .:/srv/jekyll
9+
- .:/srv/jekyll

docker-local.yml

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,7 @@ services:
44
jekyll_custom:
55
build: .
66
image: al-folio-local-docker
7-
container_name: al-folio-local-website
8-
command: bash -c "
9-
rm -f Gemfile.lock
10-
&& bundler exec jekyll serve --watch --port=8080 --host=0.0.0.0 --livereload --verbose --trace"
117
ports:
128
- 8080:8080
139
volumes:
14-
- .:/srv/jekyll
10+
- .:/srv/jekyll

0 commit comments

Comments
 (0)