oh-my-fish / theme-bobthefish

A Powerline-style, Git-aware fish theme optimized for awesome.
MIT License
1.46k stars 226 forks source link

Vagrant indication seems broken #46

Closed jschank closed 8 years ago

jschank commented 8 years ago

I believe the vagrant status portion is broken. I see a ! which indicates unknown status It looks like the code is looking for VMState but as you can see below, the property appears to be just State

$ vagrant --version Vagrant 1.8.1

VirtualBox version 5.0.18 r106667

VBoxManage showvminfo capitol-connect-dev_capitol-connect-dev_1464200304904_86096
Name:            capitol-connect-dev_capitol-connect-dev_1464200304904_86096
Groups:          /
Guest OS:        Red Hat (64-bit)
UUID:            83652330-5585-431e-b876-3d1c399789d3
Config file:     /Users/jschank/VirtualBox VMs/capitol-connect-dev_capitol-connect-dev_1464200304904_86096/capitol-connect-dev_capitol-connect-dev_1464200304904_86096.vbox
Snapshot folder: /Users/jschank/VirtualBox VMs/capitol-connect-dev_capitol-connect-dev_1464200304904_86096/Snapshots
Log folder:      /Users/jschank/VirtualBox VMs/capitol-connect-dev_capitol-connect-dev_1464200304904_86096/Logs
Hardware UUID:   83652330-5585-431e-b876-3d1c399789d3
Memory size:     2048MB
Page Fusion:     off
VRAM size:       8MB
CPU exec cap:    100%
HPET:            off
Chipset:         piix3
Firmware:        BIOS
Number of CPUs:  2
PAE:             on
Long Mode:       on
CPUID Portability Level: 0
CPUID overrides: None
Boot menu mode:  message and menu
Boot Device (1): HardDisk
Boot Device (2): DVD
Boot Device (3): Not Assigned
Boot Device (4): Not Assigned
ACPI:            on
IOAPIC:          on
Time offset:     0ms
RTC:             UTC
Hardw. virt.ext: on
Nested Paging:   on
Large Pages:     on
VT-x VPID:       on
VT-x unr. exec.: on
Paravirt. Provider: Legacy
State:           powered off (since 2016-05-25T21:22:48.000000000)
Monitor count:   1
3D Acceleration: off
2D Video Acceleration: off
Teleporter Enabled: off
Teleporter Port: 0
Teleporter Address:
Teleporter Password:
Tracing Enabled: off
Allow Tracing to Access VM: off
Tracing Configuration:
Autostart Enabled: off
Autostart Delay: 0
Default Frontend:
Storage Controller Name (0):            IDE Controller
Storage Controller Type (0):            PIIX4
Storage Controller Instance Number (0): 0
Storage Controller Max Port Count (0):  2
Storage Controller Port Count (0):      2
Storage Controller Bootable (0):        on
IDE Controller (0, 0): /Users/jschank/VirtualBox VMs/capitol-connect-dev_capitol-connect-dev_1464200304904_86096/box-disk1.vmdk (UUID: 3eb66820-fb98-40ca-886d-cb661c7e6688)
NIC 1:           MAC: 080027D70E5A, Attachment: NAT, Cable connected: on, Trace: off (file: none), Type: 82540EM, Reported speed: 0 Mbps, Boot priority: 0, Promisc Policy: deny, Bandwidth group: none
NIC 1 Settings:  MTU: 0, Socket (send: 64, receive: 64), TCP Window (send:64, receive: 64)
NIC 1 Rule(0):   name = ssh, protocol = tcp, host ip = 127.0.0.1, host port = 2222, guest ip = , guest port = 22
NIC 1 Rule(1):   name = tcp7777, protocol = tcp, host ip = , host port = 7777, guest ip = , guest port = 80
NIC 1 Rule(2):   name = tcp9003, protocol = tcp, host ip = , host port = 9003, guest ip = , guest port = 9003
NIC 2:           disabled
NIC 3:           disabled
NIC 4:           disabled
NIC 5:           disabled
NIC 6:           disabled
NIC 7:           disabled
NIC 8:           disabled
Pointing Device: PS/2 Mouse
Keyboard Device: PS/2 Keyboard
UART 1:          disabled
UART 2:          disabled
UART 3:          disabled
UART 4:          disabled
LPT 1:           disabled
LPT 2:           disabled
Audio:           disabled
Clipboard Mode:  disabled
Drag and drop Mode: disabled
VRDE:            disabled
USB:             disabled
EHCI:            disabled
XHCI:            disabled

USB Device Filters:

<none>

Bandwidth groups:  <none>

Shared folders:

Name: 'var_www_html_apps', Host path: '/Users/jschank/ddc-advocacy/projects/capitol-connect-dev/sites' (machine mapping), writable
Name: 'var_log_httpd', Host path: '/Users/jschank/ddc-advocacy/projects/capitol-connect-dev/logs' (machine mapping), writable
Name: 'vagrant', Host path: '/Users/jschank/ddc-advocacy/projects/capitol-connect-dev' (machine mapping), writable

Video capturing:    not active
Capture screens:    0
Capture file:       /Users/jschank/VirtualBox VMs/capitol-connect-dev_capitol-connect-dev_1464200304904_86096/capitol-connect-dev_capitol-connect-dev_1464200304904_86096.webm
Capture dimensions: 1024x768
Capture rate:       512 kbps
Capture FPS:        25

Guest:

Configured memory balloon size:      0 MB
bobthecow commented 8 years ago

I only use the VMWare Vagrant implementation, so I'm not sure how much help I'll be.

@sashaegorov do you mind taking a look at this?

sashaegorov commented 8 years ago

Hi @jschank I need some additional information. Please note the difference of these examples:

VBoxManage showvminfo "turnstun_default_1462525310804_71573" | grep -i state
State:           powered off (since 2016-05-27T15:10:06.000000000)

This is similar to yours. However during state detection --machinereadable is used:

VBoxManage showvminfo --machinereadable "turnstun_default_1462525310804_71573" | grep -i state
VMState="poweroff"
...

So could you please to send me same output with --machinereadable? Hope it will help to figure out why it shows !.

jschank commented 8 years ago

hmm, I think you're absolutely right. I missed the whole --machinereadable. FWIW my output is this

$ vboxmanage showvminfo --machinereadable "capitol-connect-dev_capitol-connect-dev_1464785959276_67250" | grep -i state
VMState="poweroff"
VMStateChangeTime="2016-06-02T03:01:34.000000000"

I don't think there is an actual problem.

Thanks for looking into it and getting in touch.