A firefox appliance

Fix #22
This commit is contained in:
Julien Duponchelle 2015-10-08 16:19:41 +02:00
parent 237b2b82e7
commit 5b14cf2f22
6 changed files with 138 additions and 1 deletions

42
appliances/firefox.gns3a Normal file
View File

@ -0,0 +1,42 @@
{
"category": "guest",
"status": "stable",
"maintainer": "GNS3 team",
"name": "Firefox",
"versions": [],
"symbol": "firefox.svg",
"registry_version": 1,
"maintainer_email": "developers@gns3.net",
"product_url": "https://www.mozilla.org/firefox",
"documentation_url": "https://support.mozilla.org",
"images": [],
"vendor_name": "Mozilla Foundation",
"qemu": {
"adapter_type": "e1000",
"console_type": "vnc",
"ram": 256,
"arch": "i386",
"adapters": 1
},
"product_name": "Firefox",
"vendor_url": "http://www.mozilla.org",
"description": "A light Linux based on TinyCore Linux with Firefox preinstalled",
"images": [
{
"filename": "linux-tinycore-linux-6.4-firefox-33.1.1.img",
"version": "31.1.1",
"md5sum": "9e51ad24dc25c4a26f7a8fb99bc77830",
"filesize": 82313216,
"download_url": "https://sourceforge.net/projects/gns-3/files/Qemu%20Appliances/",
"direct_download_url": "http://downloads.sourceforge.net/project/gns-3/Qemu%20Appliances/linux-tinycore-linux-6.4-firefox-33.1.1.img"
}
],
"versions": [
{
"name": "31.1.1",
"images": {
"hda_disk_image": "linux-tinycore-linux-6.4-firefox-33.1.1.img"
}
}
]
}

View File

@ -1,8 +1,9 @@
Packer for TinyCore GNS3 appliance
==================================
For building a MicroCore / TinyCore appliance run:
For building a MicroCore / TinyCore appliance.
http://tinycorelinux.net/
Clean core Linux installation
*****************************
@ -16,3 +17,20 @@ The only added packages are:
packer build core-linux.json
Tiny Core Linux installation
****************************
Tiny Core is Micro Core with a light GUI installed.
Firefox
'''''''''
A build of Tiny Core with Firefox preinstalled.
.. code:: bash
packer build -var-file=tinycore-linux-firefox.json tinycore-linux.json

View File

@ -0,0 +1,4 @@
# Install firefox and openit at startup
tce-load -wi firefox-official
mkdir -p /home/gns3/.X.d
echo 'firefox -setDefaultBrowser -private &' > /home/gns3/.X.d/firefox

View File

@ -0,0 +1,8 @@
# Install the GUI
tce-load -wi fltk-1.3
tce-load -wi flwm
tce-load -wi Xvesa
tce-load -wi wbar
tce-load -wi Xprogs
tce-load -wi Xlibs
tce-load -wi aterm

View File

@ -0,0 +1,4 @@
{
"vm_name": "linux-tinycore-linux-6.4-firefox.img",
"setup_script": "firefox.sh"
}

View File

@ -0,0 +1,61 @@
{
"variables": {
"tc_iso_url": "http://distro.ibiblio.org/tinycorelinux/6.x/x86/release/Core-6.4.iso",
"tc_iso_checksum": "c8e04e26de234e5528e6eac8ecb1bdda",
"vm_name": "linux-tinycore-linux-6.4.img",
"setup_script": "core.sh"
},
"builders": [
{
"type": "qemu",
"iso_url": "{{user `tc_iso_url`}}",
"iso_checksum": "{{user `tc_iso_checksum`}}",
"iso_checksum_type": "md5",
"shutdown_command": "sudo poweroff",
"format": "qcow2",
"headless": false,
"ssh_username": "gns3",
"ssh_password": "gns3",
"accelerator": "none",
"vm_name": "{{user `vm_name`}}",
"disk_interface": "ide",
"disk_size": 1000,
"net_device": "e1000",
"http_directory": "http",
"boot_wait": "5s",
"boot_command": [
"mc user=gns3<enter><wait10><wait10><wait10><wait10><wait10><wait10>",
"sudo passwd gns3<enter>gns3<enter>gns3<enter>",
"tce-load -wi openssh<enter><wait10>",
"cd /usr/local/etc/ssh; [ -f sshd_config.example ] && sudo cp -a sshd_config.example sshd_config; cd<enter>",
"sudo /usr/local/etc/init.d/openssh start<enter>"
]
}
],
"provisioners": [
{
"type": "shell",
"script": "scripts/hd-install.sh"
},
{
"type": "shell",
"script": "scripts/serial.sh"
},
{
"type": "shell",
"script": "scripts/packages.sh"
},
{
"type": "shell",
"script": "scripts/gui.sh"
},
{
"type": "shell",
"script": "scripts/{{user `setup_script`}}"
},
{
"type": "shell",
"script": "scripts/post_setup.sh"
}
]
}