Skip to content

Commit e80a72f

Browse files
committed
feat(docker): readme for docker use
1 parent 33724a3 commit e80a72f

File tree

2 files changed

+20
-2
lines changed

2 files changed

+20
-2
lines changed

docker/Dockerfile

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,4 @@
22
FROM ruby:2.7-rc
33

44
#Install Ruby SDK
5-
RUN gem install ibm_watson
6-
5+
RUN gem install ibm_watson

docker/README.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
## Docker
2+
You can use docker to test issues you have with the SDK.
3+
4+
1. Install docker
5+
- Mac: https://docs.docker.com/docker-for-mac/install/
6+
- Windows: https://docs.docker.com/docker-for-windows/install/
7+
1. Download the dockerfile for this SDK and edit as needed.
8+
- Change the ruby version as needed `FROM ruby:<your-version>`
9+
- For valid ruby base images on docker see https://hub.docker.com/_/ruby
10+
- Copy code/file that you wish to test into the dockerfile
11+
- Add line `COPY <src>... <dest>`
12+
- Set dockerfile to execute code file
13+
- Add line `CMD [ "<executable>" ]`
14+
15+
- For more information on dockerfile construction please visit https://docs.docker.com/engine/reference/builder/
16+
1. Build and run the docker image.
17+
- Navigate to docker file directory
18+
- To build the docker image run `docker build --tag=<your-tag> .`
19+
- To run the docker image run `docker run <your-tag>`

0 commit comments

Comments
 (0)