Skip to content

Commit

Permalink
Merge pull request #93 from andreub/master
Browse files Browse the repository at this point in the history
Add Dockerfile to run as cli
  • Loading branch information
marcelduran committed Mar 8, 2017
2 parents 698a652 + 0348dd5 commit f4ac66d
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 0 deletions.
14 changes: 14 additions & 0 deletions Dockerfile
@@ -0,0 +1,14 @@
FROM node:boron

# Create app directory
RUN mkdir -p /usr/src/app
WORKDIR /usr/src/app

# Install app dependencies
COPY package.json /usr/src/app/
RUN npm install

# Bundle app source
COPY . /usr/src/app

ENTRYPOINT [ "bin/webpagetest" ]
10 changes: 10 additions & 0 deletions README.md
Expand Up @@ -20,6 +20,16 @@ $ npm install webpagetest -g
$ webpagetest test https://twitter.com/marcelduran
```

### Docker
#### Build
```bash
$ docker build -t webpagetest-api .
```
#### Run
```bash
$ docker run -it --rm webpagetest-api -k YOURAPIKEY test https://twitter.com/marcelduran
```

### Module
```javascript
var WebPageTest = require('webpagetest');
Expand Down

0 comments on commit f4ac66d

Please sign in to comment.