Skip to content

Commit

Permalink
Merge branch 'master' into feature/leitor-a3
Browse files Browse the repository at this point in the history
# Conflicts:
#	Dockerfile
  • Loading branch information
farribeiro committed Jul 3, 2017
2 parents 68d8064 + e404db0 commit f6a0efd
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 24 deletions.
24 changes: 11 additions & 13 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@
FROM ubuntu:latest
LABEL maintainer "Fabio Rodrigues Ribeiro <[email protected]>"

ADD https://cloud.gastecnologia.com.br/cef/warsaw/install/GBPCEFwr64.deb /src/
COPY startup.sh /home/ff/

# Install Firefox

ADD \
Expand Down Expand Up @@ -32,24 +35,19 @@ RUN apt-get update \
pcscd \
pcsc-tools \
--no-install-recommends \
&& apt -y install /src/*.deb \
&& apt-get purge --auto-remove -y \
&& rm -rf /var/lib/apt/lists/* \
&& rm -rf /src/*.deb

ADD https://cloud.gastecnologia.com.br/cef/warsaw/install/GBPCEFwr64.deb /src/
COPY startup.sh /home/ff/

# Add ff user
RUN groupadd -g 1000 -r ff \
&& useradd -u 1000 -r -g ff -G audio,video ff \
&& mkdir -p /home/ff \
&& groupadd -g 1000 -r ff \
&& useradd -u 1000 -r -g ff -G audio,video ff -d /home/ff \
&& chmod 744 /home/ff/startup.sh \
&& chown -R ff:ff /home/ff \
&& passwd -d root
&& passwd -d root \
&& apt-get purge --auto-remove -y \
&& rm -rf /var/lib/apt/lists/*

# Run firefox as non privileged user
USER ff

# Add volume for recipes PDFs
VOLUME "/home/ff/Downloads"

# Autorun chrome
CMD [ "/home/ff/startup.sh" ]
24 changes: 13 additions & 11 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,17 +1,19 @@
<h1>wscef-docker</h1>
# wscef-docker

<p>Warsaw in docker container</p>
Warsaw in docker container

<h2>Instructions</h2>
## Instructions

<p>Use the docker compose to build and run docker container, because has a
enviorments and volumes setted on a <code>docker-compose.yml</code> and not
needed the <code>docker run</code> anytime</p>
Use docker compose to build and run the docker container, rather than `docker run`,
since environments and volumes are set on `docker-compose.yml`.

<p><strong>To build:</strong> <code>docker-compose build wscef</code></p>
**To build:** `docker-compose build wscef`

<p><strong>To run:</strong> <code>docker-compose run --rm wscef</code>
**To pulling existing image:** `docker-compose pull`

<p><strong>PS:</strong> The xauth will broke the container if you restart or
poweroff the system, else in the same session will run ok, and not erase
it.</p>
**To first run:** `docker-compose run --name wscef wscef`

**To other runs:** `docker start -a wscef`

**PS:** you must run Docker using a GNU/Linux distro running xorg.
Be aware some installations may run another display server, such as Wayland.
1 change: 1 addition & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,3 +15,4 @@ services:
- /dev/shm:/dev/shm
- /tmp/.X11-unix:/tmp/.X11-unix
- ${XAUTHORITY}:/tmp/.docker.xauth:ro
- ~/BankFiles:/home/ff/Downloads

0 comments on commit f6a0efd

Please sign in to comment.