Comments (13)
openssh/cygwin builds are pretty useful, for example I use packer/vagrant for running windows builds on remote bare-metal boxes which only have remote access over ssh.
Being able to do ssh into one of those remote vbox builds is priceless.
(ssh -X/vnc/rdp is not an option)
from windows.
Linux and OSX had the vagrant-winrm
plugin available and I believe in more recent versions the functionality has been rolled into Vagrant proper, so it shouldn't even require a plugin anymore.
from windows.
I was unable to make vmware//win7x86-enterprise today. I kept getting an error when the VMware tools were suppose to upload, right after WinRM successfully connected. I tried make clean before trying again and it failed the same way. I then tried make vmware//win7x86-enterprise-ssh and it worked. So removing ssh and cygwin would be removing a quick work around when WinRM is obviously not working right.
from windows.
I fixed that issue locally, using
winrm set winrm/config/winrs @{MaxMemoryPerShellMB="2048"}
from windows.
rasa, I'm new to using packer/boxcutter/vagrant/chocolately. I'm currently on a Windows 10 PC using VMware Workstation and I'm not aware of where I would use that winrm set command? Is it something I configure for my Windows environment or for VMware somehow? Does it go into a config file? Thanks.
from windows.
rasa, never mind, I figured it out.
from windows.
This would make the boxes unusable on linux and OSX as these platforms don't have winrm client support in vagrant.
from windows.
I'm all for this removal as well.
from windows.
It appears that the vote is to not remove these templates.
How about consolidating them? There aren't too many differences between the templates, it might be possible to use something like jq
to merge the ssh or cygwin parts into the main template?
If there's no interest in either of the aforementioned solutions, I'll likely close this in a month or so as "wontfix" if nobody has any objections. Let me know.
from windows.
Now that Packer supports writing templates in HCL I wonder if there is an option to write them in HCL and do an import or merge on top of a base with the SSH and cygwin functionality and export to JSON. I'd definitely hope to avoid going too crazy with having code that generates templates just to avoid a little bit of repeated code.
from windows.
Yeah, agreed on avoiding going crazy with generating templates for everything.
With regards to jq
or whatever other mechanism, I was thinking something along the lines of the following...like you can do relatively quick merges like the following to add/replace some fields to an individual builder.
jq '.builders[] |= . + {"communicator":"ssh","ssh_username":"blah","ssh_password":"blah"}' eval-win7x86-enterprise.json
This logic simply adds the communicator, ssh_username, and ssh_password from specified dict into each of the builder elements for a template.
But with regards to integrating this into boxcutter/windows, it'd probably look something more like the following if we've isolated the ssh-specific/cygwin-specific components into their own json. I've been doing this sort of stuff in my own fork of boxcutter/windows to de-vagrantify all of the templates, and to change the default usernames/passwords.
jq --slurpfile builders /path/to/ssh-builders.json --slurpfile provisioners /path/to/ssh-provisioners.json '(.provisioners[].scripts += $provisioners) | (.builders[] |= . + $ssh)' eval-win7x86-enterprise.json
But, to avoid forcing people to have to build these templates themselves (which'd require having jq), we could split up the logic for ssh-ifying (or cygwin-ifying) a template into the makefile, and then have a maintainer just ensure that its part of a pre-commit hook or something similar so that from the users' perspective, nothing appears to have changed.
Re-writing all of the json templates in HCL kind of feels out of scope for this project, especially since its kind-of in "maintenance" mode. It might be better to consider a whole rewrite for non-json templates in some newer project like github.com/boxcutter/windows-ps
or something similar
from windows.
This issue has had no discussion or input for over 6 months. I've tagged it as stale and as a result this issue will be closed in 1 month.
If you disagree and feel this decision is a mistake, please let me know and I'll remove the label.
from windows.
Closing this issue as it's been stale for over a month.
from windows.
Related Issues (20)
- win2012r2-standardcore-ssh.json template has the wrong vm_name for some of the builders HOT 2
- Feature: Consolidate the vm_name and suffix into knobs that the user can adjust HOT 1
- Cygwin templates: The sshd daemon doesn't seem to get started
- Deprecated schema options used in some of the templates HOT 2
- Standardization of the order of the fields for the builders in all the templates HOT 6
- Possibly unused floppy/oracle-cert.cer for VirtualBox has expired on 3/2019 HOT 1
- The eval-win7x86-enterprise-ssh.json template does not install openssh in the hyperv-iso builder HOT 1
- The hyperv-iso builder for the win2012r2-standard-cygwin.json template installs openssh instead of cygwin HOT 1
- Issue with wget.exe on the eval-win81x86-enterprise template HOT 2
- Issue when trying to download wget.exe with some of the templates for the older platforms. HOT 2
- eval-win7x64-enterprise template blocks at the set network location screen HOT 2
- The bootstrapped downloader is still stored within the template after completing its build
- Windows 10 eval is failing to find disk to install to on Parallels HOT 9
- The `iso_checksum_type` key has been deprecated in Packer 1.6.0 HOT 1
- Windows Server 2019 support? HOT 4
- Windows Server 2016 blocks on bootup during vmware build. Guest OS Type incorrect?
- Updating the saltstack version deployed by script/cmtool.bat from 2019.2.2 to the "latest" HOT 1
- Downloading ultradefrag from sourceforge will sometimes not work if curl or powershell is used as a downloader HOT 2
- Not using Makefile causes errors due to incorrectly formatted `shutdown` comment string and other things HOT 5
- Missing labels for "eof" in 00-run-all-scripts.cmd and zzz-debug-log.cmd HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from windows.