feat: set peerDependencies
This commit is contained in:
@@ -70,15 +70,17 @@ export class Container {
|
||||
*
|
||||
* @param query - Query parameters to send to the request
|
||||
*/
|
||||
async logs(query: {
|
||||
follow?: boolean;
|
||||
stdout?: boolean;
|
||||
stderr?: boolean;
|
||||
since?: number;
|
||||
until?: number;
|
||||
timestamps?: boolean;
|
||||
tail?: number | "all";
|
||||
} = {}): Promise<Response> {
|
||||
async logs(
|
||||
query: {
|
||||
follow?: boolean;
|
||||
stdout?: boolean;
|
||||
stderr?: boolean;
|
||||
since?: number;
|
||||
until?: number;
|
||||
timestamps?: boolean;
|
||||
tail?: number | "all";
|
||||
} = {},
|
||||
): Promise<Response> {
|
||||
return modem.request({ method: "GET", path: `/containers/${this.id}/logs`, query });
|
||||
}
|
||||
|
||||
|
||||
@@ -51,9 +51,13 @@ class Modem {
|
||||
* @param param.body - Request body. _(Ignored for `GET` requests.)_
|
||||
* @param param.headers - Headers to send with the request.
|
||||
*/
|
||||
async request(
|
||||
{ method, path, query = {}, body, headers = {} }: { method: "POST" | "GET" | "DELETE" } & RequestOptions,
|
||||
): Promise<Response> {
|
||||
async request({
|
||||
method,
|
||||
path,
|
||||
query = {},
|
||||
body,
|
||||
headers = {},
|
||||
}: { method: "POST" | "GET" | "DELETE" } & RequestOptions): Promise<Response> {
|
||||
return this.client.fetch(`http://docker${path}${toSearchParams(query)}`, {
|
||||
method,
|
||||
body,
|
||||
|
||||
Reference in New Issue
Block a user