This repository has been archived by the owner on Aug 3, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Updated files based on forked repo from CareerJSM/emberjs-docker-test…
…ing (#1) * Updated files based on forked repo from CareerJSM/emberjs-docker-testing * Updated README.md
- Loading branch information
1 parent
b72cfa7
commit 6b7aa6c
Showing
3 changed files
with
55 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,31 @@ | ||
# syntax=docker/dockerfile:experimental | ||
|
||
FROM node:12.8.1 | ||
FROM node:12.8.1-stretch | ||
|
||
RUN \ | ||
--mount=id=apt-cache,type=cache,target=/var/cache/apt \ | ||
--mount=id=apt-lib,type=cache,target=/var/lib/apt \ | ||
apt-get update --fix-missing && apt-get install -y jq | ||
WORKDIR /downloads | ||
RUN wget https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb | ||
RUN \ | ||
--mount=id=apt-cache,type=cache,target=/var/cache/apt \ | ||
--mount=id=apt-lib,type=cache,target=/var/lib/apt \ | ||
apt-get update --fix-missing && apt-get install -y -f ./google-chrome-stable_current_amd64.deb | ||
apt-get update -qqy && \ | ||
apt-get -qqy install xvfb fluxbox x11vnc dbus \ | ||
fontconfig \ | ||
curl \ | ||
python-dev \ | ||
gnupg wget ca-certificates apt-transport-https && \ | ||
wget -q -O - https://dl.google.com/linux/linux_signing_key.pub | apt-key add - && \ | ||
echo "deb https://dl.google.com/linux/chrome/deb/ stable main" >> /etc/apt/sources.list.d/google-chrome.list && \ | ||
apt-get update -qqy && \ | ||
apt-get -qqy install google-chrome-unstable && \ | ||
ln -s /usr/bin/nodejs /usr/bin/node && \ | ||
npm install bower ember-cli -g && \ | ||
rm -rf /var/lib/apt/lists/* && \ | ||
git clone https://github.com/facebook/watchman.git && \ | ||
cd watchman && \ | ||
git checkout v4.9.0 && \ | ||
./autogen.sh && \ | ||
./configure && \ | ||
make && \ | ||
make install | ||
|
||
COPY entrypoint.sh /entrypoint.sh | ||
|
||
CMD ["/entrypoint.sh"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
# Docker Image for Ember Testing | ||
|
||
This Docker image, will setup a system so your ember tests can be executed inside the container itself. | ||
|
||
Based on repository here: https://github.com/BookerSoftwareInc/emberjs-docker-testing. | ||
|
||
## Supported tags and respective `Dockerfile` links | ||
|
||
- latest | ||
- 12.8.1 | ||
|
||
## Run the Image | ||
|
||
``` | ||
docker run --rm -ti -v $PWD:/app -p 7357:7357 careerjsm/emberjs-docker-testing:latest bash | ||
``` | ||
|
||
### Run Your Tests | ||
|
||
Now that you are in the container, you can run the following command `ember test --server`. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
#!/bin/sh | ||
|
||
dt=$(date '+%d/%m/%Y %H:%M:%S'); | ||
echo "=======================================" | ||
echo "$dt. Starting container..." | ||
|
||
#echo "Starting chrome for testing" | ||
xvfb-run --server-args='-screen 0, 1024x768x16' google-chrome -start-maximized > /dev/null & | ||
|
||
#(ember test --silent --reporter xunit || true) > /tmp/test_results.xml |