-E '^(install|hold) ok installed$' ls /etc/rc3.d/ | grep -- '^S..nginx$' \ || grep '^\s*start on' /etc/init/nginx.conf service nginx status \ && service nginx status | egrep 'running|online' MasterCloud #7 11
b = backend::direct::Direct::new(); let s = specinfra::new(&b).unwrap(); let file = s.file("/etc/passwd"); match file.mode() { Ok(m) => println!("{:o}", m), Err(e) => println!("{}", e), } } MasterCloud #7 27
s = SSHBuilder::new(); let b = s.hostname("localhost").finalize().unwrap(); let s = specinfra::new(&b).unwrap(); let file = s.file("/etc/passwd"); match file.mode() { Ok(m) => println!("{:o}", m), Err(e) => println!("{}", e), } } MasterCloud #7 28