Skip to content
This repository has been archived by the owner on Nov 24, 2024. It is now read-only.

Commit

Permalink
fix usage example
Browse files Browse the repository at this point in the history
  • Loading branch information
philipparndt committed Jan 31, 2022
1 parent 8bbca2d commit a848a31
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,10 +44,11 @@ Enter `https://github.com/alexsteinerde/docker-client-swift.git` for the URL.
## Usage Example
```swift
let client = DockerClient()
let image = try client.images.pullImage(imageName: "hello-world:latest").wait()
let container = try! client.containers.createContainer(image: image).wait()
let image = try client.images.pullImage(byIdentifier: "hello-world:latest").wait()
let container = try client.containers.createContainer(image: image).wait()
try container.start(on: client).wait()
let output = try container.logs(on: client).wait()
try client.syncShutdown()
print(output)
```

Expand Down

0 comments on commit a848a31

Please sign in to comment.