API-Docker
view release on metacpan or search on metacpan
lib/API/Docker/API/Exec.pm view on Meta::CPAN
my $exec = $exec->create($container_id,
Cmd => ['/bin/sh', '-c', 'echo hello'],
AttachStdout => 1,
AttachStderr => 1,
Tty => 0,
);
Create an exec instance. Returns hashref with C<Id>.
Required config: C<Cmd> (ArrayRef of command and arguments).
Common config keys: C<AttachStdin>, C<AttachStdout>, C<AttachStderr>, C<Tty>,
C<Env>, C<User>, C<WorkingDir>.
=head2 start
$exec->start($exec_id, Detach => 0);
Start an exec instance. Options: C<Detach>, C<Tty>.
=head2 resize
$exec->resize($exec_id, h => 40, w => 120);
Resize the TTY for an exec instance. Options: C<h> (height), C<w> (width).
=head2 inspect
my $info = $exec->inspect($exec_id);
Get information about an exec instance.
=head1 SEE ALSO
=over
=item * L<API::Docker> - Main Docker client
=item * L<API::Docker::API::Containers> - Container management
=back
=head1 SUPPORT
=head2 Issues
Please report bugs and feature requests on GitHub at
L<https://github.com/Getty/p5-api-docker/issues>.
=head1 CONTRIBUTING
Contributions are welcome! Please fork the repository and submit a pull request.
=head1 AUTHOR
Torsten Raudssus <getty@cpan.org>
=head1 COPYRIGHT AND LICENSE
This software is copyright (c) 2026 by Torsten Raudssus <torsten@raudssus.de> L<https://raudssus.de/>.
This is free software; you can redistribute it and/or modify it under
the same terms as the Perl 5 programming language system itself.
=cut
( run in 0.607 second using v1.01-cache-2.11-cpan-e1769b4cff6 )