Skip to content

Commit

Permalink
Merge pull request #449 from chef/dry-fedora
Browse files Browse the repository at this point in the history
[fedora-*] DRYness pass
  • Loading branch information
Seth Thomas committed Sep 15, 2015
2 parents 7451e1b + b8db9bc commit 1307f3b
Show file tree
Hide file tree
Showing 6 changed files with 184 additions and 107 deletions.
47 changes: 30 additions & 17 deletions fedora-20-i386.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"builders": [
{
"boot_command": [
"<tab> linux ks=http://{{ .HTTPIP }}:{{ .HTTPPort }}/fedora-20/ks.cfg<enter><wait>"
"<tab> linux ks=http://{{ .HTTPIP }}:{{ .HTTPPort }}/{{user `ks_path`}}<enter><wait>"
],
"boot_wait": "10s",
"disk_size": 40960,
Expand All @@ -11,10 +11,10 @@
"hard_drive_interface": "sata",
"headless": "{{ user `headless` }}",
"http_directory": "http",
"iso_checksum": "284ea30ddd50db1b30cd5cd9fae7495dad8714ef1e4428d69a8c8ce80e03b6a9",
"iso_checksum_type": "sha256",
"iso_url": "{{user `mirror`}}/releases/20/Fedora/i386/iso/Fedora-20-i386-DVD.iso",
"output_directory": "packer-fedora-20-i386-virtualbox",
"iso_checksum": "{{user `iso_checksum`}}",
"iso_checksum_type": "{{user `iso_checksum_type`}}",
"iso_url": "{{user `mirror`}}/{{user `mirror_directory`}}/{{user `iso_name`}}",
"output_directory": "packer-{{user `template`}}-virtualbox",
"shutdown_command": "echo 'vagrant'|sudo -S shutdown -P now",
"ssh_password": "vagrant",
"ssh_port": 22,
Expand All @@ -40,17 +40,17 @@
},
{
"boot_command": [
"<tab> linux ks=http://{{ .HTTPIP }}:{{ .HTTPPort }}/fedora-20/ks.cfg<enter><wait>"
"<tab> linux ks=http://{{ .HTTPIP }}:{{ .HTTPPort }}/{{user `ks_path`}}<enter><wait>"
],
"boot_wait": "10s",
"disk_size": 40960,
"guest_os_type": "fedora",
"headless": "{{ user `headless` }}",
"http_directory": "http",
"iso_checksum": "284ea30ddd50db1b30cd5cd9fae7495dad8714ef1e4428d69a8c8ce80e03b6a9",
"iso_checksum_type": "sha256",
"iso_url": "{{user `mirror`}}/releases/20/Fedora/i386/iso/Fedora-20-i386-DVD.iso",
"output_directory": "packer-fedora-20-i386-vmware",
"iso_checksum": "{{user `iso_checksum`}}",
"iso_checksum_type": "{{user `iso_checksum_type`}}",
"iso_url": "{{user `mirror`}}/{{user `mirror_directory`}}/{{user `iso_name`}}"
"output_directory": "packer-{{user `template`}}-vmware",
"shutdown_command": "echo 'vagrant'|sudo -S shutdown -P now",
"ssh_password": "vagrant",
"ssh_port": 22,
Expand All @@ -67,17 +67,17 @@
},
{
"boot_command": [
"<tab> linux ks=http://{{ .HTTPIP }}:{{ .HTTPPort }}/fedora-20/ks.cfg<enter><wait>"
"<tab> linux ks=http://{{ .HTTPIP }}:{{ .HTTPPort }}/{{user `ks_path`}}<enter><wait>"
],
"boot_wait": "10s",
"disk_size": 40960,
"guest_os_type": "fedora-core",
"headless": "{{ user `headless` }}",
"http_directory": "http",
"iso_checksum": "284ea30ddd50db1b30cd5cd9fae7495dad8714ef1e4428d69a8c8ce80e03b6a9",
"iso_checksum_type": "sha256",
"iso_url": "{{user `mirror`}}/releases/20/Fedora/i386/iso/Fedora-20-i386-DVD.iso",
"output_directory": "packer-fedora-20-i386-parallels",
"iso_checksum": "{{user `iso_checksum`}}",
"iso_checksum_type": "{{user `iso_checksum_type`}}",
"iso_url": "{{user `mirror`}}/{{user `mirror_directory`}}/{{user `iso_name`}}",
"output_directory": "packer-{{user `template`}}-parallels",
"parallels_tools_flavor": "lin",
"prlctl": [
[
Expand Down Expand Up @@ -116,7 +116,12 @@
"type": "file"
},
{
"environment_vars": [],
"environment_vars": [
"HOME_DIR=/home/vagrant",
"http_proxy={{user `http_proxy`}}",
"https_proxy={{user `https_proxy`}}",
"no_proxy={{user `no_proxy`}}"
],
"execute_command": "echo 'vagrant' | {{.Vars}} sudo -E -S bash '{{.Path}}'",
"scripts": [
"scripts/common/metadata.sh",
Expand All @@ -136,9 +141,17 @@
"build_timestamp": "{{isotime \"20060102150405\"}}",
"git_revision": "__unknown_git_revision__",
"headless": "",
"http_proxy": "{{env `http_proxy`}}",
"https_proxy": "{{env `https_proxy`}}",
"iso_checksum": "284ea30ddd50db1b30cd5cd9fae7495dad8714ef1e4428d69a8c8ce80e03b6a9",
"iso_checksum_type": "sha256",
"iso_name": "Fedora-20-i386-DVD.iso",
"ks_path": "fedora-20/ks.cfg",
"metadata": "floppy/dummy_metadata.json",
"mirror": "http://download.fedoraproject.org/pub/fedora/linux",
"mirror": "https://archive.fedoraproject.org/pub/archive/fedora/linux",
"mirror_directory": "releases/20/Fedora/x86_64/iso",
"name": "fedora-20-i386",
"no_proxy": "{{env `no_proxy`}}",
"template": "fedora-20-i386",
"version": "2.0.TIMESTAMP"
}
Expand Down
47 changes: 30 additions & 17 deletions fedora-20-x86_64.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"builders": [
{
"boot_command": [
"<tab> linux ks=http://{{ .HTTPIP }}:{{ .HTTPPort }}/fedora-20/ks.cfg<enter><wait>"
"<tab> linux ks=http://{{ .HTTPIP }}:{{ .HTTPPort }}/{{user `ks_path`}}<enter><wait>"
],
"boot_wait": "10s",
"disk_size": 40960,
Expand All @@ -11,10 +11,10 @@
"hard_drive_interface": "sata",
"headless": "{{ user `headless` }}",
"http_directory": "http",
"iso_checksum": "f2eeed5102b8890e9e6f4b9053717fe73031e699c4b76dc7028749ab66e7f917",
"iso_checksum_type": "sha256",
"iso_url": "{{user `mirror`}}/releases/20/Fedora/x86_64/iso/Fedora-20-x86_64-DVD.iso",
"output_directory": "packer-fedora-20-x86_64-virtualbox",
"iso_checksum": "{{user `iso_checksum`}}",
"iso_checksum_type": "{{user `iso_checksum_type`}}",
"iso_url": "{{user `mirror`}}/{{user `mirror_directory`}}/{{user `iso_name`}}",
"output_directory": "packer-{{user `template`}}-virtualbox",
"shutdown_command": "echo 'vagrant'|sudo -S shutdown -P now",
"ssh_password": "vagrant",
"ssh_port": 22,
Expand All @@ -40,17 +40,17 @@
},
{
"boot_command": [
"<tab> linux ks=http://{{ .HTTPIP }}:{{ .HTTPPort }}/fedora-20/ks.cfg<enter><wait>"
"<tab> linux ks=http://{{ .HTTPIP }}:{{ .HTTPPort }}/{{user `ks_path`}}<enter><wait>"
],
"boot_wait": "10s",
"disk_size": 40960,
"guest_os_type": "fedora-64",
"headless": "{{ user `headless` }}",
"http_directory": "http",
"iso_checksum": "f2eeed5102b8890e9e6f4b9053717fe73031e699c4b76dc7028749ab66e7f917",
"iso_checksum_type": "sha256",
"iso_url": "{{user `mirror`}}/releases/20/Fedora/x86_64/iso/Fedora-20-x86_64-DVD.iso",
"output_directory": "packer-fedora-20-x86_64-vmware",
"iso_checksum": "{{user `iso_checksum`}}",
"iso_checksum_type": "{{user `iso_checksum_type`}}",
"iso_url": "{{user `mirror`}}/{{user `mirror_directory`}}/{{user `iso_name`}}",
"output_directory": "packer-{{user `template`}}-vmware",
"shutdown_command": "echo 'vagrant'|sudo -S shutdown -P now",
"ssh_password": "vagrant",
"ssh_port": 22,
Expand All @@ -67,17 +67,17 @@
},
{
"boot_command": [
"<tab> linux ks=http://{{ .HTTPIP }}:{{ .HTTPPort }}/fedora-20/ks.cfg<enter><wait>"
"<tab> linux ks=http://{{ .HTTPIP }}:{{ .HTTPPort }}/{{user `ks_path`}}<enter><wait>"
],
"boot_wait": "10s",
"disk_size": 40960,
"guest_os_type": "fedora-core",
"headless": "{{ user `headless` }}",
"http_directory": "http",
"iso_checksum": "f2eeed5102b8890e9e6f4b9053717fe73031e699c4b76dc7028749ab66e7f917",
"iso_checksum_type": "sha256",
"iso_url": "{{user `mirror`}}/releases/20/Fedora/x86_64/iso/Fedora-20-x86_64-DVD.iso",
"output_directory": "packer-fedora-20-x86_64-parallels",
"iso_checksum": "{{user `iso_checksum`}}",
"iso_checksum_type": "{{user `iso_checksum_type`}}",
"iso_url": "{{user `mirror`}}/{{user `mirror_directory`}}/{{user `iso_name`}}",
"output_directory": "packer-{{user `template`}}-parallels",
"parallels_tools_flavor": "lin",
"prlctl": [
[
Expand Down Expand Up @@ -116,7 +116,12 @@
"type": "file"
},
{
"environment_vars": [],
"environment_vars": [
"HOME_DIR=/home/vagrant",
"http_proxy={{user `http_proxy`}}",
"https_proxy={{user `https_proxy`}}",
"no_proxy={{user `no_proxy`}}"
],
"execute_command": "echo 'vagrant' | {{.Vars}} sudo -E -S bash '{{.Path}}'",
"scripts": [
"scripts/common/metadata.sh",
Expand All @@ -136,9 +141,17 @@
"build_timestamp": "{{isotime \"20060102150405\"}}",
"git_revision": "__unknown_git_revision__",
"headless": "",
"http_proxy": "{{env `http_proxy`}}",
"https_proxy": "{{env `https_proxy`}}",
"iso_checksum": "f2eeed5102b8890e9e6f4b9053717fe73031e699c4b76dc7028749ab66e7f917",
"iso_checksum_type": "sha256",
"iso_name": "Fedora-20-x86_64-DVD.iso",
"ks_path": "fedora-20/ks.cfg",
"metadata": "floppy/dummy_metadata.json",
"mirror": "http://download.fedoraproject.org/pub/fedora/linux",
"mirror": "https://archive.fedoraproject.org/pub/archive/fedora/linux",
"mirror_directory": "releases/20/Fedora/x86_64/iso",
"name": "fedora-20",
"no_proxy": "{{env `no_proxy`}}",
"template": "fedora-20-x86_64",
"version": "2.0.TIMESTAMP"
}
Expand Down
46 changes: 29 additions & 17 deletions fedora-21-i386.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"builders": [
{
"boot_command": [
"<tab> linux ks=http://{{ .HTTPIP }}:{{ .HTTPPort }}/fedora-21/ks.cfg<enter><wait>"
"<tab> linux ks=http://{{ .HTTPIP }}:{{ .HTTPPort }}/{{user `ks_path`}}<enter><wait>"
],
"boot_wait": "10s",
"disk_size": 40960,
Expand All @@ -11,10 +11,10 @@
"hard_drive_interface": "sata",
"headless": "{{ user `headless` }}",
"http_directory": "http",
"iso_checksum": "85e50a8a938996522bf1605b3578a2d6680362c1aa963d0560d59c2e4fc795ef",
"iso_checksum_type": "sha256",
"iso_url": "{{user `mirror`}}/releases/21/Server/i386/iso/Fedora-Server-DVD-i386-21.iso",
"output_directory": "packer-fedora-21-i386-virtualbox",
"iso_checksum": "{{user `iso_checksum`}}",
"iso_checksum_type": "{{user `iso_checksum_type`}}",
"iso_url": "{{user `mirror`}}/{{user `mirror_directory`}}/{{user `iso_name`}}",
"output_directory": "packer-{{user `template`}}-virtualbox",
"shutdown_command": "echo 'vagrant'|sudo -S shutdown -P now",
"ssh_password": "vagrant",
"ssh_port": 22,
Expand All @@ -40,17 +40,17 @@
},
{
"boot_command": [
"<tab> linux ks=http://{{ .HTTPIP }}:{{ .HTTPPort }}/fedora-21/ks.cfg<enter><wait>"
"<tab> linux ks=http://{{ .HTTPIP }}:{{ .HTTPPort }}/{{user `ks_path`}}<enter><wait>"
],
"boot_wait": "10s",
"disk_size": 40960,
"guest_os_type": "fedora",
"headless": "{{ user `headless` }}",
"http_directory": "http",
"iso_checksum": "85e50a8a938996522bf1605b3578a2d6680362c1aa963d0560d59c2e4fc795ef",
"iso_checksum_type": "sha256",
"iso_url": "{{user `mirror`}}/releases/21/Server/i386/iso/Fedora-Server-DVD-i386-21.iso",
"output_directory": "packer-fedora-21-i386-vmware",
"iso_checksum": "{{user `iso_checksum`}}",
"iso_checksum_type": "{{user `iso_checksum_type`}}",
"iso_url": "{{user `mirror`}}/{{user `mirror_directory`}}/{{user `iso_name`}}"
"output_directory": "packer-{{user `template`}}-vmware",
"shutdown_command": "echo 'vagrant'|sudo -S shutdown -P now",
"ssh_password": "vagrant",
"ssh_port": 22,
Expand All @@ -67,17 +67,17 @@
},
{
"boot_command": [
"<tab> linux ks=http://{{ .HTTPIP }}:{{ .HTTPPort }}/fedora-21/ks.cfg<enter><wait>"
"<tab> linux ks=http://{{ .HTTPIP }}:{{ .HTTPPort }}/{{user `ks_path`}}<enter><wait>"
],
"boot_wait": "10s",
"disk_size": 40960,
"guest_os_type": "fedora-core",
"headless": "{{ user `headless` }}",
"http_directory": "http",
"iso_checksum": "85e50a8a938996522bf1605b3578a2d6680362c1aa963d0560d59c2e4fc795ef",
"iso_checksum_type": "sha256",
"iso_url": "{{user `mirror`}}/releases/21/Server/i386/iso/Fedora-Server-DVD-i386-21.iso",
"output_directory": "packer-fedora-21-i386-parallels",
"iso_checksum": "{{user `iso_checksum`}}",
"iso_checksum_type": "{{user `iso_checksum_type`}}",
"iso_url": "{{user `mirror`}}/{{user `mirror_directory`}}/{{user `iso_name`}}",
"output_directory": "packer-{{user `template`}}-parallels",
"parallels_tools_flavor": "lin",
"prlctl": [
[
Expand Down Expand Up @@ -116,7 +116,12 @@
"type": "file"
},
{
"environment_vars": [],
"environment_vars": [
"HOME_DIR=/home/vagrant",
"http_proxy={{user `http_proxy`}}",
"https_proxy={{user `https_proxy`}}",
"no_proxy={{user `no_proxy`}}"
],
"execute_command": "echo 'vagrant' | {{.Vars}} sudo -E -S bash '{{.Path}}'",
"scripts": [
"scripts/common/metadata.sh",
Expand All @@ -136,11 +141,18 @@
"build_timestamp": "{{isotime \"20060102150405\"}}",
"git_revision": "__unknown_git_revision__",
"headless": "",
"http_proxy": "{{env `http_proxy`}}",
"https_proxy": "{{env `https_proxy`}}",
"iso_checksum": "85e50a8a938996522bf1605b3578a2d6680362c1aa963d0560d59c2e4fc795ef",
"iso_checksum_type": "sha256",
"iso_name": "Fedora-Server-DVD-i386-21.iso",
"ks_path": "fedora-21/ks.cfg",
"metadata": "floppy/dummy_metadata.json",
"mirror": "http://download.fedoraproject.org/pub/fedora/linux",
"mirror_directory": "releases/21/Server/i386/iso",
"name": "fedora-21-i386",
"no_proxy": "{{env `no_proxy`}}",
"template": "fedora-21-i386",
"version": "2.0.TIMESTAMP"
}
}

Loading

0 comments on commit 1307f3b

Please sign in to comment.