mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-12-05 14:02:21 +00:00
24 lines
531 B
Plaintext
24 lines
531 B
Plaintext
|
#!/usr/bin/expect -f
|
||
|
|
||
|
# Wait enough (forever) until a long-time boot
|
||
|
set timeout -1
|
||
|
|
||
|
spawn qemu-system-x86_64 \
|
||
|
-hda bionic-server-cloudimg-amd64.img \
|
||
|
-cpu qemu64,+ssse3,+sse4.1,+sse4.2,+popcnt -smp 8 \
|
||
|
-net nic -net user,hostfwd=tcp::11022-:22 \
|
||
|
-m 4096 -nographic
|
||
|
|
||
|
expect "login: "
|
||
|
send "root\n"
|
||
|
|
||
|
expect "Password: "
|
||
|
send "root\n"
|
||
|
|
||
|
# Without it ssh is not working on guest machine for some reason
|
||
|
expect "# "
|
||
|
send "dhclient && ssh-keygen -A && systemctl restart sshd.service\n"
|
||
|
|
||
|
# Wait forever
|
||
|
expect "########"
|