Jump to content

Recommended Posts

Posted

Hi,

 

Looking to implement a virtual environment for mysql and flask.

 

Im using oracle virtualbox and it works great other than i cant lock down the settings, especially the network settings.

 

Has anyone managed to do this, or if not, have an alternate product that allows this.

 

Thanks in advance

Posted

Did something myself too many years ago with VirtualBox. Can't remember exactly, but had the config of the VM set in stone so it had no network access, but could however map a folder in the VM directly to their Home Directory so they could at least move files back and forth. Disk was immutable, so always reverted back to its original config once it was shutdown. It did work well, however was a nightmare to setup and getting working correctly. In the end, so much moved to within the browser or just local it was given up as a bad idea and we moved on.

 

Pete

Posted (edited)

Configure your virtual machine with no NICs, and then apply a user login script that runs any required vboxmanage.exe commands like this. In addition to this, you should also use file permissions to prevent end users from modifying the main vbox file of the VM.

 

if exist "C:\Program Files\Oracle\VirtualBox\vboxmanage.exe" (
"C:\Program Files\Oracle\VirtualBox\vboxmanage.exe" registervm "C:\path\to\virtualmachine.vbox"
"C:\Program Files\Oracle\VirtualBox\vboxmanage.exe" setextradata global GUI/Customizations noSelector
"C:\Program Files\Oracle\VirtualBox\vboxmanage.exe" setextradata global GUI/SuppressMessages remindAboutAutoCapture,remindAboutMouseIntegration,showRuntimeError.warning.HostAudioNotResponding,remindAboutGoingSeamless,remindAboutInputCapture,remindAboutGoingFullscreen,remindAboutMouseIntegrationOff,confirmGoingSeamless,confirmInputCapture,remindAboutPausedVMInput,confirmVMReset,confirmGoingFullscreen,remindAboutWrongColorDepth
"C:\Program Files\Oracle\VirtualBox\vboxmanage.exe" setextradata global GUI/RestrictedGlobalSettingsPages General,Input,Update,Language,Display,Network,Extensions,Proxy
"C:\Program Files\Oracle\VirtualBox\vboxmanage.exe" setextradata "C:\path\to\virtualmachine.vbox" GUI/RestrictedRuntimeMenus Machine,View,Devices,Help,Debug
"C:\Program Files\Oracle\VirtualBox\vboxmanage.exe" setextradata "C:\path\to\virtualmachine.vbox" GUI/RestrictedStatusBarIndicators HardDisks,OpticalDisks,FloppyDisks,Network,USB,SharedFolders,Features,Mouse,Keyboard
"C:\Program Files\Oracle\VirtualBox\vboxmanage.exe" setextradata "C:\path\to\virtualmachine.vbox" GUI/RestrictedCloseActions SaveState,PowerOff,Restore
)

 

With the "setextradata global GUI/Customizations noSelector" command being run, you'd also need to deploy a shortcut that enables your end users to launch the VM, since that command will prevent them from opening the main VirtualBox application window.

Edited by jthompson
Posted

Thanks for pointing me in the right direction,

ive altered your code to the following:

 

if exist "C:\Program Files\Oracle\VirtualBox\vboxmanage.exe" ( "C:\Program Files\Oracle\VirtualBox\vboxmanage.exe" setextradata global GUI/RestrictedGlobalSettingsPages General,Input,Update,Language,Display,Network,Extensions,Proxy)

 

but im getting an error:

B4TfUGNScw6EAAAAAElFTkSuQmCC

 

Thanks again

if exist CProgram FilesOracleVirtua.vbs

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now



×
×
  • Create New...