Skip to content
Permalink
Branch: master
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
66 lines (64 sloc) 2.77 KB
{
"variables": {
"gce_project_id": null,
"gce_network": null,
"gce_subnetwork": "",
"gce_zone": null,
"gce_service_account_email": "",
"gce_source_image": "",
"gce_source_image_family": "",
"gce_source_image_project_id": "",
"gce_disk_size": "100",
"gce_disk_type": "pd-standard",
"gce_machine_type": "n1-standard-1",
"gce_use_internal_ip": "true",
"gce_omit_external_ip": "true",
"appversion": "",
"build_host": "",
"build_info_url": ""
},
"builders": [
{
"type": "googlecompute",
"project_id": "{{user `gce_project_id`}}",
"source_image_project_id": "{{user `gce_source_image_project_id`}}",
"source_image": "{{user `gce_source_image`}}",
"source_image_family": "{{user `gce_source_image_family`}}",
"service_account_email": "{{user `gce_service_account_email`}}",
"zone": "{{user `gce_zone`}}",
"network": "{{user `gce_network`}}",
"subnetwork": "{{user `gce_subnetwork`}}",
"disk_size": "{{user `gce_disk_size`}}",
"disk_type": "{{user `gce_disk_type`}}",
"image_description": "appversion: {{user `appversion`}}, build_host: {{user `build_host`}}, build_info_url: {{user `build_info_url`}}",
"image_labels": {
"app": "{{user `gce_source_image_family`}}"
},
"image_name": "{{user `gce_source_image_family`}}-{{isotime \"20060102150405\"}}",
"image_family": "{{user `gce_source_image_family`}}",
"instance_name": "packer-{{user `gce_source_image_family`}}-{{isotime \"20060102150405\"}}",
"labels": {
"app": "{{user `gce_source_image_family`}}"
},
"machine_type": "{{user `gce_machine_type`}}",
"state_timeout": "15m",
"use_internal_ip": "{{user `gce_use_internal_ip`}}",
"omit_external_ip": "{{user `gce_omit_external_ip`}}",
"communicator": "winrm",
"winrm_username": "packer",
"winrm_insecure": true,
"winrm_use_ssl": false,
"metadata": {
"windows-startup-script-ps1": "winrm quickconfig -quiet ; cmd.exe /c net user /add packer ; cmd.exe /c net localgroup administrators packer /add ; cmd.exe /c wmic useraccount where \"name='packer'\" set PasswordExpires=FALSE ; winrm set winrm/config/winrs '@{MaxMemoryPerShellMB=\"300\"}' ; winrm set winrm/config '@{MaxTimeoutms=\"1800000\"}' ; winrm set winrm/config/service '@{AllowUnencrypted=\"true\"}' ; winrm set winrm/config/service/auth '@{Basic=\"true\"}' ; Stop-Service -Name winrm ; Set-Service -Name winrm -Startup Automatic ; Start-Service -Name winrm ; Set-ExecutionPolicy -ExecutionPolicy Bypass -Scope LocalMachine"
}
}
],
"provisioners": [
{
"type": "powershell",
"inline": [
"& \"C:\\Program files\\Google\\Compute Engine\\sysprep\\gcesysprep\""
]
}
]
}
You can’t perform that action at this time.