Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use Upstream Container Images #173

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
35 changes: 12 additions & 23 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,28 +1,17 @@
FROM fedora:34 as builder
FROM python:3 AS builder

COPY . /code
WORKDIR /code

RUN dnf -y install gettext python3-setuptools python3-pyyaml python3-mako python3-babel python3-pygraphviz && dnf clean all && python3 setup.py install && ./build.sh
COPY requirements.txt ./
RUN pip install --no-cache-dir -r requirements.txt

FROM fedora:34
COPY . .

COPY --from=builder /code/build /var/www/html/
COPY --from=builder /code/container/l10n.conf /etc/httpd/conf/l10n.conf
COPY container/favicon.xpm /var/www/html/static/image/favicon.xpm
COPY container/whatcanidoforfedora-web.conf /etc/httpd/conf/httpd.conf
RUN dnf -y install httpd && dnf clean all\
&& chown apache:0 /etc/httpd/conf/httpd.conf \
&& chmod g+r /etc/httpd/conf/httpd.conf \
&& chown apache:0 /etc/httpd/conf/l10n.conf \
&& chmod g+r /etc/httpd/conf/l10n.conf \
&& chown apache:0 /var/log/httpd \
&& chmod g+rwX /var/log/httpd \
&& chown apache:0 /var/run/httpd \
&& chmod g+rwX /var/run/httpd\
&& chown -R apache:0 /var/www/html \
&& chmod -R g+rwX /var/www/html
EXPOSE 8080
USER apache
ADD container/container-entrypoint.sh /srv
ENTRYPOINT ["bash", "/srv/container-entrypoint.sh"]
RUN ./build.sh

FROM httpd:2.4

COPY --from=builder /code/build /usr/local/apache2/htdocs/
COPY --from=builder /code/container/l10n.conf /usr/local/apache2/conf/l10n.conf
COPY container/favicon.xpm /usr/local/apache2/htdocs/static/image/favicon.xpm
COPY container/whatcanidoforfedora-web.conf /usr/local/apache2/conf/httpd.conf
6 changes: 1 addition & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -111,11 +111,7 @@ podman-compose up -d

###### Verifiying

In your Favorite Browser Just type:

```
localhost:8080
```
In your favorite browser navigate to [localhost:8080](http://localhost:8080).

## Application Deployment

Expand Down
1 change: 0 additions & 1 deletion container/container-entrypoint.sh

This file was deleted.

Loading