forked from bellwether/minerva
added test files
This commit is contained in:
parent
9f8b67b98f
commit
e3055333b3
9 changed files with 313 additions and 17 deletions
28
test/streaming.py
Normal file
28
test/streaming.py
Normal file
|
|
@ -0,0 +1,28 @@
|
|||
import minerva
|
||||
import sys
|
||||
import select
|
||||
|
||||
m = minerva.Minerva("hay")
|
||||
pier = m.pier(subnet_id = "subnet-05eb26d8649a093e1", # project-subnet-public1-us-east-1a
|
||||
sg_groups = ["sg-0f9e555954e863954", # ssh
|
||||
"sg-0b34a3f7398076545"], # default
|
||||
iam = "S3+SSM+CloudWatch+ECR",
|
||||
key_pair = ("Ari-Brown-HAY", "/Users/ari/.ssh/Ari-Brown-HAY.pem"))
|
||||
|
||||
mach = pier.machine(ami = "ami-0b0cd81283738558a", # ubuntu 22.04 x86
|
||||
instance_type = "t3.medium",
|
||||
username = "ubuntu",
|
||||
name = f"minerva-aws-test")
|
||||
|
||||
try:
|
||||
mach.create()
|
||||
mach.login()
|
||||
#stdout, stderr = mach.cmd("for i in $(seq 1 10); do echo $i; >&2 echo $i; sleep 2; done", disown=True)
|
||||
|
||||
import IPython
|
||||
IPython.embed()
|
||||
|
||||
finally:
|
||||
mach.terminate()
|
||||
|
||||
|
||||
Loading…
Add table
Add a link
Reference in a new issue