instances: Add methods to evaluate PHP

This commit is contained in:
Tom Wiesing 2022-09-15 23:21:14 +02:00
parent 492a0c0404
commit a3511b1bfc
No known key found for this signature in database
3 changed files with 151 additions and 8 deletions

View file

@ -1,8 +1,10 @@
package instances
import "github.com/tkw1536/goprogram/stream"
import (
"github.com/tkw1536/goprogram/stream"
)
// Shell executes a shell command inside the instance.
func (wisski WissKI) Shell(io stream.IOStream, argv ...string) (int, error) {
func (wisski *WissKI) Shell(io stream.IOStream, argv ...string) (int, error) {
return wisski.Barrel().Exec(io, "barrel", "/bin/sh", append([]string{"/user_shell.sh"}, argv...)...)
}