File tree Expand file tree Collapse file tree 2 files changed +28
-0
lines changed Expand file tree Collapse file tree 2 files changed +28
-0
lines changed Original file line number Diff line number Diff line change 1+ #  Import Node base image (change version as needed)
2+ FROM  node:12-slim
3+ 
4+ # Install the node SDK
5+ RUN  npm install ibm-watson
Original file line number Diff line number Diff line change 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+ 
8+ 2 .   Download the dockerfile for this SDK and edit as needed.
9+     -    Change the node version as needed ` FROM node:<your-version> ` 
10+         -    For valid node base images on docker see < https://hub.docker.com/_/node > 
11+ 
12+     -    Copy code/file that you wish to test into the dockerfile 
13+         -    Add line ` COPY <src>... <dest> ` 
14+ 
15+     -    Set dockerfile to execute code file 
16+         -    Add line ` CMD [ "<executable>" ] ` 
17+     
18+     -    For more information on dockerfile construction please visit < https://docs.docker.com/engine/reference/builder/ > 
19+ 
20+ 3 .   Build and run the docker image.
21+     -    Navigate to docker file directory
22+     -    To build the docker image run ` docker build --tag=<your-tag> . ` 
23+     -    To run the docker image run ` docker run <your-tag> ` 
 
 
   
 
     
   
   
          
    
    
     
    
      
     
     
    You can’t perform that action at this time.
  
 
    
  
    
      
        
     
       
      
     
   
 
    
    
  
 
  
 
     
    
0 commit comments