Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
slapos.package
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Francois Le Corre
slapos.package
Commits
5aeec645
Commit
5aeec645
authored
Apr 04, 2016
by
Rafael Monnerat
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
packer: Include initial flavours for tests and automation of VMs
parent
234c2491
Changes
14
Hide whitespace changes
Inline
Side-by-side
Showing
14 changed files
with
808 additions
and
0 deletions
+808
-0
packer/build.yml
packer/build.yml
+151
-0
packer/centos-6.7-testing-version.json
packer/centos-6.7-testing-version.json
+54
-0
packer/centos-7.2-testing-version.json
packer/centos-7.2-testing-version.json
+54
-0
packer/debian7-testing-version.json
packer/debian7-testing-version.json
+64
-0
packer/debian8-erp5-standalone.json
packer/debian8-erp5-standalone.json
+64
-0
packer/debian8-testing-version.json
packer/debian8-testing-version.json
+64
-0
packer/debian8-webrunner-standalone.json
packer/debian8-webrunner-standalone.json
+64
-0
packer/debian8-wendelin-standalone.json
packer/debian8-wendelin-standalone.json
+64
-0
packer/scripts/setup-erp5-standalone.sh
packer/scripts/setup-erp5-standalone.sh
+20
-0
packer/scripts/setup-testing-version.sh
packer/scripts/setup-testing-version.sh
+45
-0
packer/scripts/setup-webrunner-standalone.sh
packer/scripts/setup-webrunner-standalone.sh
+20
-0
packer/scripts/setup-wendelin-standalone.sh
packer/scripts/setup-wendelin-standalone.sh
+20
-0
packer/ubuntu-14.04-server-amd64-testing-version.json
packer/ubuntu-14.04-server-amd64-testing-version.json
+62
-0
packer/ubuntu-15.04-server-amd64-testing-version.json
packer/ubuntu-15.04-server-amd64-testing-version.json
+62
-0
No files found.
packer/build.yml
View file @
5aeec645
...
...
@@ -34,6 +34,46 @@
args
:
creates
:
output-centos72
-
shell
:
PATH=$PATH:/opt/packer/ packer build debian7-testing-version.json >> log/debian7-testing-version.log
args
:
creates
:
output-debian7-testing-version
-
shell
:
PATH=$PATH:/opt/packer/ packer build debian8-testing-version.json >> log/debian8-testing-version.log
args
:
creates
:
output-debian8-testing-version
-
shell
:
PATH=$PATH:/opt/packer/ packer build ubuntu-14.04-server-amd64-testing-version.json >> log/ubuntu-14.04-server-amd64-testing-version.log
args
:
creates
:
output-ubuntu-14-04-server-testing-version
-
shell
:
PATH=$PATH:/opt/packer/ packer build ubuntu-15.04-server-amd64-testing-version.json >> log/ubuntu-15.04-server-amd64-testing-version.log
args
:
creates
:
output-ubuntu-15-04-server-testing-version
-
shell
:
PATH=$PATH:/opt/packer/ packer build centos-6.7-testing-version.json >> log/centos-6.7-testing-version.log
args
:
creates
:
output-centos67-testing-version
-
shell
:
PATH=$PATH:/opt/packer/ packer build centos-7.2-testing-version.json >> log/centos-7.2-testing-version.log
args
:
creates
:
output-centos72-testing-version
-
shell
:
PATH=$PATH:/opt/packer/ packer build debian8-erp5-standalone.json >> log/debian8-erp5-standalone.log
args
:
creates
:
output-debian8-erp5-standalone
-
shell
:
PATH=$PATH:/opt/packer/ packer build debian8-wendelin-standalone.json >> log/debian8-wendelin-standalone.log
args
:
creates
:
output-debian8-wendelin-standalone
-
shell
:
PATH=$PATH:/opt/packer/ packer build debian8-webrunner-standalone.json >> log/debian8-webrunner-standalone.log
args
:
creates
:
output-debian8-webrunner-standalone
-
file
:
path={{ item }} state=directory mode=0755
with_items
:
-
repository
...
...
@@ -83,6 +123,51 @@
creates
:
output-centos72/packer-centos72.gz
ignore_errors
:
True
-
shell
:
gzip output-debian8-testing-version/packer-debian8-testing-version
args
:
creates
:
output-debian8-testing-version/packer-debian8-testing-version.gz
ignore_errors
:
True
-
shell
:
gzip output-debian7-testing-version/packer-debian7-testing-version
args
:
creates
:
output-debian7-testing-version/packer-debian7-testing-version.gz
ignore_errors
:
True
-
shell
:
gzip output-ubuntu-14-04-server-testing-version/packer-ubuntu-14-04-server-testing-version
args
:
creates
:
output-ubuntu-14-04-server-testing-version/packer-ubuntu-14-04-server-testing-version.gz
ignore_errors
:
True
-
shell
:
gzip output-ubuntu-15-04-server-testing-version/packer-ubuntu-15-04-server-testing-version
args
:
creates
:
output-ubuntu-15-04-server-testing-version/packer-ubuntu-15-04-server-testing-version.gz
ignore_errors
:
True
-
shell
:
gzip output-centos67-testing-version/packer-centos67-testing-version
args
:
creates
:
output-centos67-testing-version/packer-centos67.gz
ignore_errors
:
True
-
shell
:
gzip output-centos72-testing-version/packer-centos72-testing-version
args
:
creates
:
output-centos72-testing-version/packer-centos72-testing-version.gz
ignore_errors
:
True
-
shell
:
gzip output-debian8-wendelin-standalone/packer-debian8-wendelin-standalone
args
:
creates
:
output-debian8-wendelin-standalone/packer-debian8-wendelin-standalone.gz
ignore_errors
:
True
-
shell
:
gzip output-debian8-erp5-standalone/packer-debian8-erp5-standalone
args
:
creates
:
output-debian8-erp5-standalone/packer-debian8-erp5-standalone.gz
ignore_errors
:
True
-
shell
:
gzip output-debian8-webrunner-standalone/packer-debian8-webrunner-standalone
args
:
creates
:
output-debian8-webrunner-standalone/packer-debian8-webrunner-standalone.gz
ignore_errors
:
True
-
shell
:
mv output-debian8/packer-debian8.gz repository/debian/8/amd64/base-image.qcow2.gz
args
:
creates
:
repository/debian/8/amd64/base-image.qcow2.gz
...
...
@@ -106,4 +191,70 @@
-
shell
:
mv output-centos72/packer-centos72.gz repository/centos/7/x86_64/base-image.qcow2.gz
args
:
creates
:
repository/centos/7/x86_64/base-image.qcow2.gz
-
shell
:
mv output-debian8-testing-version/packer-debian8-testing-version.gz repository/debian/8/amd64/testing-image.qcow2.gz
args
:
creates
:
repository/debian/8/amd64/testing-image.qcow2.gz
-
shell
:
mv output-debian7-testing-version/packer-debian7-testing-version.gz repository/debian/7/amd64/testing-image.qcow2.gz
args
:
creates
:
repository/debian/7/amd64/testing-image.qcow2.gz
-
shell
:
mv output-ubuntu-14-04-server-testing-version/packer-ubuntu-14-04-server-testing-version.gz repository/ubuntu/14.04/amd64/testing-image.qcow2.gz
args
:
creates
:
repository/ubuntu/14.04/amd64/testing-image.qcow2.gz
-
shell
:
mv output-ubuntu-15-04-server-testing-version/packer-ubuntu-15-04-server-testing-version.gz repository/ubuntu/15.04/amd64/testing-image.qcow2.gz
args
:
creates
:
repository/ubuntu/15.04/amd64/testing-image.qcow2.gz
-
shell
:
mv output-centos67-testing-version/packer-centos67-testing-version.gz repository/centos/6/x86_64/testing-image.qcow2.gz
args
:
creates
:
repository/centos/6/x86_64/testing-image.qcow2.gz
-
shell
:
mv output-centos72-testing-version/packer-centos72-testing-version.gz repository/centos/7/x86_64/testing-image.qcow2.gz
args
:
creates
:
repository/centos/7/x86_64/testing-image.qcow2.gz
-
shell
:
mv output-debian8-webrunner-standalone/packer-debian8-webrunner-standalone.gz repository/debian/8/amd64/erp5-image.qcow2.gz
args
:
creates
:
repository/debian/8/amd64/erp5-image.qcow2.gz
-
shell
:
mv output-debian8-erp5-standalone/packer-debian8-erp5-standalone.gz repository/debian/8/amd64/erp5-image.qcow2.gz
args
:
creates
:
repository/debian/8/amd64/erp5-image.qcow2.gz
-
shell
:
mv output-debian8-wendelin-standalone/packer-debian8-wendelin-standalone.gz repository/debian/8/amd64/wendelin-image.qcow2.gz
args
:
creates
:
repository/debian/8/amd64/wendelin-image.qcow2.gz
-
shell
:
md5sum * > MD5SUM.txt
args
:
chdir
:
repository/debian/8/amd64/
-
shell
:
md5sum * > MD5SUM.txt
args
:
chdir
:
repository/debian/7/amd64/
-
shell
:
md5sum * > MD5SUM.txt
args
:
chdir
:
repository/debian/7/amd64/
-
shell
:
md5sum * > MD5SUM.txt
args
:
chdir
:
repository/ubuntu/14.04/amd64/
-
shell
:
md5sum * > MD5SUM.txt
args
:
chdir
:
repository/ubuntu/15.04/amd64/
-
shell
:
md5sum * > MD5SUM.txt
args
:
chdir
:
repository/centos/6/x86_64/
-
shell
:
md5sum * > MD5SUM.txt
args
:
chdir
:
repository/centos/7/x86_64/
packer/centos-6.7-testing-version.json
0 → 100644
View file @
5aeec645
{
"variables"
:
{
"user"
:
"slapos"
,
"password"
:
"slapos"
,
"disk_size"
:
"100000"
,
"domain"
:
""
},
"builders"
:
[
{
"name"
:
"centos67-testing-version"
,
"type"
:
"qemu"
,
"format"
:
"qcow2"
,
"accelerator"
:
"kvm"
,
"disk_size"
:
"{{ user `disk_size`}}"
,
"iso_url"
:
"http://mirrors.kernel.org/centos/6.7/isos/x86_64/CentOS-6.7-x86_64-minimal.iso"
,
"iso_checksum"
:
"9d3fec5897be6b3fed4d3dda80b8fa7bb62c616bbfd4bdcd27295ca9b764f498"
,
"iso_checksum_type"
:
"sha256"
,
"http_directory"
:
"http"
,
"ssh_username"
:
"{{user `user`}}"
,
"ssh_password"
:
"{{user `password`}}"
,
"ssh_wait_timeout"
:
"1800s"
,
"shutdown_command"
:
"sudo poweroff"
,
"headless"
:
false
,
"boot_wait"
:
"2s"
,
"boot_command"
:
[
"<esc>"
,
"<wait>"
,
"linux ks=http://{{.HTTPIP}}:{{.HTTPPort}}/centos67-anaconda-ks.cfg"
,
"<enter>"
]
}
],
"provisioners"
:
[
{
"type"
:
"shell"
,
"execute_command"
:
"echo '{{user `password`}}' | {{.Vars}} sudo -E -S bash '{{.Path}}'"
,
"scripts"
:
[
"scripts/update-centos.sh"
,
"scripts/packages-centos.sh"
,
"scripts/setup-testing-version.sh"
,
"scripts/cleanup-centos.sh"
]
}
]
}
packer/centos-7.2-testing-version.json
0 → 100644
View file @
5aeec645
{
"variables"
:
{
"user"
:
"slapos"
,
"password"
:
"slapos"
,
"disk_size"
:
"100000"
,
"domain"
:
""
},
"builders"
:
[
{
"name"
:
"centos72-testing-version"
,
"type"
:
"qemu"
,
"format"
:
"qcow2"
,
"accelerator"
:
"kvm"
,
"disk_size"
:
"{{ user `disk_size`}}"
,
"iso_url"
:
"http://mirrors.kernel.org/centos/7.2.1511/isos/x86_64/CentOS-7-x86_64-NetInstall-1511.iso"
,
"iso_checksum"
:
"9ed9ffb5d89ab8cca834afce354daa70a21dcb410f58287d6316259ff89758f5"
,
"iso_checksum_type"
:
"sha256"
,
"http_directory"
:
"http"
,
"ssh_username"
:
"{{user `user`}}"
,
"ssh_password"
:
"{{user `password`}}"
,
"ssh_wait_timeout"
:
"1800s"
,
"shutdown_command"
:
"sudo poweroff"
,
"headless"
:
false
,
"boot_wait"
:
"2s"
,
"boot_command"
:
[
"<esc>"
,
"<wait>"
,
"linux ks=http://{{.HTTPIP}}:{{.HTTPPort}}/centos72-anaconda-ks.cfg biosdevname=0 net.ifnames=0"
,
"<enter>"
]
}
],
"provisioners"
:
[
{
"type"
:
"shell"
,
"execute_command"
:
"echo '{{user `password`}}' | {{.Vars}} sudo -E -S bash '{{.Path}}'"
,
"scripts"
:
[
"scripts/update-centos.sh"
,
"scripts/packages-centos.sh"
,
"scripts/setup-testing-version.sh"
,
"scripts/cleanup-centos.sh"
]
}
]
}
packer/debian7-testing-version.json
0 → 100644
View file @
5aeec645
{
"variables"
:
{
"user"
:
"slapos"
,
"password"
:
"slapos"
,
"disk_size"
:
"100000"
,
"domain"
:
""
},
"builders"
:
[
{
"name"
:
"debian7-testing-version"
,
"type"
:
"qemu"
,
"format"
:
"qcow2"
,
"accelerator"
:
"kvm"
,
"disk_size"
:
"{{ user `disk_size`}}"
,
"iso_url"
:
"http://cdimage.debian.org/mirror/cdimage/archive/7.9.0/amd64/iso-cd/debian-7.9.0-amd64-netinst.iso"
,
"iso_checksum"
:
"774d1fc8c5364e63b22242c33a89c1a3"
,
"iso_checksum_type"
:
"md5"
,
"http_directory"
:
"http"
,
"ssh_username"
:
"{{user `user`}}"
,
"ssh_password"
:
"{{user `password`}}"
,
"ssh_wait_timeout"
:
"1800s"
,
"shutdown_command"
:
"echo '{{user `password`}}'|sudo -S shutdown -h now"
,
"headless"
:
false
,
"boot_wait"
:
"2s"
,
"boot_command"
:
[
"<esc><wait><wait>"
,
"install auto "
,
"preseed/url=http://{{ .HTTPIP }}:{{ .HTTPPort }}/preseed-debian7.cfg "
,
"debian-installer=en_US locale=en_US keymap=us "
,
"netcfg/get_hostname={{ .Name }} "
,
"netcfg/get_domain={{ user `domain`}} "
,
"fb=false debconf/frontend=noninteractive "
,
"passwd/user-fullname={{user `user`}} "
,
"passwd/user-password={{user `password`}} "
,
"passwd/user-password-again={{user `password`}} "
,
"passwd/username={{user `user`}} "
,
"<enter>"
]
}
],
"provisioners"
:
[
{
"type"
:
"shell"
,
"execute_command"
:
"echo '{{user `password`}}' | {{.Vars}} sudo -E -S bash '{{.Path}}'"
,
"scripts"
:
[
"scripts/update.sh"
,
"scripts/packages.sh"
,
"scripts/setup-testing-version.sh"
,
"scripts/cleanup.sh"
]
}
]
}
packer/debian8-erp5-standalone.json
0 → 100644
View file @
5aeec645
{
"variables"
:
{
"user"
:
"slapos"
,
"password"
:
"slapos"
,
"disk_size"
:
"100000"
,
"domain"
:
""
},
"builders"
:
[
{
"name"
:
"debian8-erp5-standalone"
,
"type"
:
"qemu"
,
"format"
:
"qcow2"
,
"accelerator"
:
"kvm"
,
"disk_size"
:
"{{ user `disk_size`}}"
,
"iso_url"
:
"http://cdimage.debian.org/debian-cd/8.3.0/amd64/iso-cd/debian-8.3.0-amd64-netinst.iso"
,
"iso_checksum"
:
"a9b490b4215d1e72e876b031dafa7184"
,
"iso_checksum_type"
:
"md5"
,
"http_directory"
:
"http"
,
"ssh_username"
:
"{{user `user`}}"
,
"ssh_password"
:
"{{user `password`}}"
,
"ssh_wait_timeout"
:
"1800s"
,
"shutdown_command"
:
"echo '{{user `password`}}'|sudo -S shutdown -h now"
,
"headless"
:
false
,
"boot_wait"
:
"2s"
,
"boot_command"
:
[
"<esc><wait><wait>"
,
"install auto "
,
"preseed/url=http://{{ .HTTPIP }}:{{ .HTTPPort }}/preseed-debian8.cfg "
,
"debian-installer=en_US locale=en_US keymap=us "
,
"netcfg/get_hostname={{ .Name }} "
,
"netcfg/get_domain={{ user `domain`}} "
,
"fb=false debconf/frontend=noninteractive "
,
"passwd/user-fullname={{user `user`}} "
,
"passwd/user-password={{user `password`}} "
,
"passwd/user-password-again={{user `password`}} "
,
"passwd/username={{user `user`}} "
,
"<enter>"
]
}
],
"provisioners"
:
[
{
"type"
:
"shell"
,
"execute_command"
:
"echo '{{user `password`}}' | {{.Vars}} sudo -E -S bash '{{.Path}}'"
,
"scripts"
:
[
"scripts/update.sh"
,
"scripts/packages.sh"
,
"scripts/setup-erp5-standalone.sh"
,
"scripts/cleanup.sh"
]
}
]
}
packer/debian8-testing-version.json
0 → 100644
View file @
5aeec645
{
"variables"
:
{
"user"
:
"slapos"
,
"password"
:
"slapos"
,
"disk_size"
:
"100000"
,
"domain"
:
""
},
"builders"
:
[
{
"name"
:
"debian8-testing-version"
,
"type"
:
"qemu"
,
"format"
:
"qcow2"
,
"accelerator"
:
"kvm"
,
"disk_size"
:
"{{ user `disk_size`}}"
,
"iso_url"
:
"http://cdimage.debian.org/debian-cd/8.3.0/amd64/iso-cd/debian-8.3.0-amd64-netinst.iso"
,
"iso_checksum"
:
"a9b490b4215d1e72e876b031dafa7184"
,
"iso_checksum_type"
:
"md5"
,
"http_directory"
:
"http"
,
"ssh_username"
:
"{{user `user`}}"
,
"ssh_password"
:
"{{user `password`}}"
,
"ssh_wait_timeout"
:
"1800s"
,
"shutdown_command"
:
"echo '{{user `password`}}'|sudo -S shutdown -h now"
,
"headless"
:
false
,
"boot_wait"
:
"2s"
,
"boot_command"
:
[
"<esc><wait><wait>"
,
"install auto "
,
"preseed/url=http://{{ .HTTPIP }}:{{ .HTTPPort }}/preseed-debian8.cfg "
,
"debian-installer=en_US locale=en_US keymap=us "
,
"netcfg/get_hostname={{ .Name }} "
,
"netcfg/get_domain={{ user `domain`}} "
,
"fb=false debconf/frontend=noninteractive "
,
"passwd/user-fullname={{user `user`}} "
,
"passwd/user-password={{user `password`}} "
,
"passwd/user-password-again={{user `password`}} "
,
"passwd/username={{user `user`}} "
,
"<enter>"
]
}
],
"provisioners"
:
[
{
"type"
:
"shell"
,
"execute_command"
:
"echo '{{user `password`}}' | {{.Vars}} sudo -E -S bash '{{.Path}}'"
,
"scripts"
:
[
"scripts/update.sh"
,
"scripts/packages.sh"
,
"scripts/setup-testing-version.sh"
,
"scripts/cleanup.sh"
]
}
]
}
packer/debian8-webrunner-standalone.json
0 → 100644
View file @
5aeec645
{
"variables"
:
{
"user"
:
"slapos"
,
"password"
:
"slapos"
,
"disk_size"
:
"100000"
,
"domain"
:
""
},
"builders"
:
[
{
"name"
:
"debian8"
,
"type"
:
"qemu"
,
"format"
:
"qcow2"
,
"accelerator"
:
"kvm"
,
"disk_size"
:
"{{ user `disk_size`}}"
,
"iso_url"
:
"http://cdimage.debian.org/debian-cd/8.3.0/amd64/iso-cd/debian-8.3.0-amd64-netinst.iso"
,
"iso_checksum"
:
"a9b490b4215d1e72e876b031dafa7184"
,
"iso_checksum_type"
:
"md5"
,
"http_directory"
:
"http"
,
"ssh_username"
:
"{{user `user`}}"
,
"ssh_password"
:
"{{user `password`}}"
,
"ssh_wait_timeout"
:
"1800s"
,
"shutdown_command"
:
"echo '{{user `password`}}'|sudo -S shutdown -h now"
,
"headless"
:
false
,
"boot_wait"
:
"2s"
,
"boot_command"
:
[
"<esc><wait><wait>"
,
"install auto "
,
"preseed/url=http://{{ .HTTPIP }}:{{ .HTTPPort }}/preseed-debian8.cfg "
,
"debian-installer=en_US locale=en_US keymap=us "
,
"netcfg/get_hostname={{ .Name }} "
,
"netcfg/get_domain={{ user `domain`}} "
,
"fb=false debconf/frontend=noninteractive "
,
"passwd/user-fullname={{user `user`}} "
,
"passwd/user-password={{user `password`}} "
,
"passwd/user-password-again={{user `password`}} "
,
"passwd/username={{user `user`}} "
,
"<enter>"
]
}
],
"provisioners"
:
[
{
"type"
:
"shell"
,
"execute_command"
:
"echo '{{user `password`}}' | {{.Vars}} sudo -E -S bash '{{.Path}}'"
,
"scripts"
:
[
"scripts/update.sh"
,
"scripts/packages.sh"
,
"scripts/setup-webrunner-standalone.sh"
,
"scripts/cleanup.sh"
]
}
]
}
packer/debian8-wendelin-standalone.json
0 → 100644
View file @
5aeec645
{
"variables"
:
{
"user"
:
"slapos"
,
"password"
:
"slapos"
,
"disk_size"
:
"100000"
,
"domain"
:
""
},
"builders"
:
[
{
"name"
:
"debian8-wendelin"
,
"type"
:
"qemu"
,
"format"
:
"qcow2"
,
"accelerator"
:
"kvm"
,
"disk_size"
:
"{{ user `disk_size`}}"
,
"iso_url"
:
"http://cdimage.debian.org/debian-cd/8.3.0/amd64/iso-cd/debian-8.3.0-amd64-netinst.iso"
,
"iso_checksum"
:
"a9b490b4215d1e72e876b031dafa7184"
,
"iso_checksum_type"
:
"md5"
,
"http_directory"
:
"http"
,
"ssh_username"
:
"{{user `user`}}"
,
"ssh_password"
:
"{{user `password`}}"
,
"ssh_wait_timeout"
:
"1800s"
,
"shutdown_command"
:
"echo '{{user `password`}}'|sudo -S shutdown -h now"
,
"headless"
:
false
,
"boot_wait"
:
"2s"
,
"boot_command"
:
[
"<esc><wait><wait>"
,
"install auto "
,
"preseed/url=http://{{ .HTTPIP }}:{{ .HTTPPort }}/preseed-debian8.cfg "
,
"debian-installer=en_US locale=en_US keymap=us "
,
"netcfg/get_hostname={{ .Name }} "
,
"netcfg/get_domain={{ user `domain`}} "
,
"fb=false debconf/frontend=noninteractive "
,
"passwd/user-fullname={{user `user`}} "
,
"passwd/user-password={{user `password`}} "
,
"passwd/user-password-again={{user `password`}} "
,
"passwd/username={{user `user`}} "
,
"<enter>"
]
}
],
"provisioners"
:
[
{
"type"
:
"shell"
,
"execute_command"
:
"echo '{{user `password`}}' | {{.Vars}} sudo -E -S bash '{{.Path}}'"
,
"scripts"
:
[
"scripts/update.sh"
,
"scripts/packages.sh"
,
"scripts/setup-wendelin-standalone.sh"
,
"scripts/cleanup.sh"
]
}
]
}
packer/scripts/setup-erp5-standalone.sh
0 → 100644
View file @
5aeec645
wget http://deploy.erp5.cn/erp5-standalone
-O
/root/run-standalone
bash /root/run-standalone
sleep
10
for
i
in
1 2 3 4 5
do
slapos node software
sleep
5
done
for
i
in
1 2 3 4 5
do
slapos node instance
sleep
5
done
packer/scripts/setup-testing-version.sh
0 → 100644
View file @
5aeec645
cat
<<
EOF
> /root/run-test
#!/bin/bash
BOOTSTRAP="/root/start-bootstrap"
FILE="/etc/cron.d/ansible-vm-bootstrap"
if [[ ! -f "
$BOOTSTRAP
" ]]
then
exit 1
fi
# Check if playbook has been correctly extracted
COUNT=
$(
ls
/opt/slapos.playbook |
wc
-l
)
if [[ !
$COUNT
-gt 1 ]]
then
rm -f
$FILE
rm -f /opt/slapos.playbook/playbook.tar.gz
fi
lf=/tmp/pidLockFile
cat /dev/null >>
$lf
read lastPID <
$lf
# if lastPID is not null and a process with that pid exists , exit
[ ! -z "
$lastPID
" -a -d /proc/
$lastPID
] && exit
# save my pid in the lock file
echo
$$
>
$lf
if [[ -f "
$FILE
" ]] && [[ -s "
$FILE
" ]] && [[
$COUNT
-gt 1 ]]
then
rm /etc/cron.d/vm-boostrap
fi
export TERM=xterm
sleep 5
wget -O /root/launch-test http://deploy.erp5.cn/launch-test
chmod +x /root/launch-test
bash -lc /root/launch-test
EOF
cat
<<
EOF
> /etc/cron.d/vm-boostrap
# Bootstrap vm every minutes until it succeed
* * * * * root bash -lc /root/run-test >> /var/log/vm-bootstrap.log 2>&1
EOF
packer/scripts/setup-webrunner-standalone.sh
0 → 100644
View file @
5aeec645
wget http://deploy.erp5.cn/webrunner-standalone
-O
/root/run-standalone
bash /root/run-standalone
sleep
10
for
i
in
1 2 3 4 5
do
slapos node software
sleep
5
done
for
i
in
1 2 3 4 5
do
slapos node instance
sleep
5
done
packer/scripts/setup-wendelin-standalone.sh
0 → 100644
View file @
5aeec645
wget http://deploy.erp5.cn/wendelin-standalone
-O
/root/run-standalone
bash /root/run-standalone
sleep
10
for
i
in
1 2 3 4 5
do
slapos node software
sleep
5
done
for
i
in
1 2 3 4 5
do
slapos node instance
sleep
5
done
packer/ubuntu-14.04-server-amd64-testing-version.json
0 → 100644
View file @
5aeec645
{
"variables"
:
{
"user"
:
"slapos"
,
"password"
:
"slapos"
,
"disk_size"
:
"100000"
},
"builders"
:
[
{
"name"
:
"ubuntu-14-04-server-testing-version"
,
"type"
:
"qemu"
,
"format"
:
"qcow2"
,
"accelerator"
:
"kvm"
,
"disk_size"
:
"{{ user `disk_size`}}"
,
"iso_url"
:
"http://releases.ubuntu.com/14.04/ubuntu-14.04.4-server-amd64.iso"
,
"iso_checksum"
:
"2ac1f3e0de626e54d05065d6f549fa3a"
,
"iso_checksum_type"
:
"md5"
,
"http_directory"
:
"http"
,
"ssh_username"
:
"{{user `user`}}"
,
"ssh_password"
:
"{{user `password`}}"
,
"ssh_wait_timeout"
:
"1800s"
,
"shutdown_command"
:
"echo '{{user `password`}}'|sudo -S shutdown -P now"
,
"boot_wait"
:
"2s"
,
"boot_command"
:
[
"<esc><esc><enter><wait>"
,
"/install/vmlinuz url=http://{{ .HTTPIP }}:{{ .HTTPPort }}/preseed-ubuntu.cfg "
,
"debian-installer=en_US auto locale=en_US kbd-chooser/method=us "
,
"hostname={{ .Name }} "
,
"keyboard-configuration/modelcode=SKIP "
,
"keyboard-configuration/layout=USA "
,
"keyboard-configuration/variant=USA "
,
"passwd/user-fullname={{user `user`}} "
,
"passwd/user-password-again={{user `password`}} "
,
"passwd/user-password={{user `password`}} "
,
"passwd/username={{user `user`}} "
,
"initrd=/install/initrd.gz -- <enter>"
]
}
],
"provisioners"
:
[
{
"type"
:
"shell"
,
"execute_command"
:
"echo '{{user `password`}}' | {{.Vars}} sudo -E -S bash '{{.Path}}'"
,
"scripts"
:
[
"scripts/update-ubuntu.sh"
,
"scripts/packages-ubuntu.sh"
,
"scripts/setup-testing-version.sh"
,
"scripts/network-ubuntu.sh"
]
}
]
}
packer/ubuntu-15.04-server-amd64-testing-version.json
0 → 100644
View file @
5aeec645
{
"variables"
:
{
"user"
:
"slapos"
,
"password"
:
"slapos"
,
"disk_size"
:
"100000"
},
"builders"
:
[
{
"name"
:
"ubuntu-15-04-server-testing-version"
,
"type"
:
"qemu"
,
"format"
:
"qcow2"
,
"accelerator"
:
"kvm"
,
"disk_size"
:
"{{ user `disk_size`}}"
,
"iso_url"
:
"http://releases.ubuntu.com/15.04/ubuntu-15.04-server-amd64.iso"
,
"iso_checksum"
:
"487f4a81f22f8597503db3d51a1b502e"
,
"iso_checksum_type"
:
"md5"
,
"http_directory"
:
"http"
,
"ssh_username"
:
"{{user `user`}}"
,
"ssh_password"
:
"{{user `password`}}"
,
"ssh_wait_timeout"
:
"1800s"
,
"shutdown_command"
:
"echo '{{user `password`}}'|sudo -S shutdown -P now"
,
"boot_wait"
:
"2s"
,
"boot_command"
:
[
"<esc><esc><enter><wait>"
,
"/install/vmlinuz url=http://{{ .HTTPIP }}:{{ .HTTPPort }}/preseed-ubuntu.cfg "
,
"debian-installer=en_US auto locale=en_US kbd-chooser/method=us "
,
"hostname={{ .Name }} "
,
"keyboard-configuration/modelcode=SKIP "
,
"keyboard-configuration/layout=USA "
,
"keyboard-configuration/variant=USA "
,
"passwd/user-fullname={{user `user`}} "
,
"passwd/user-password-again={{user `password`}} "
,
"passwd/user-password={{user `password`}} "
,
"passwd/username={{user `user`}} "
,
"initrd=/install/initrd.gz -- <enter>"
]
}
],
"provisioners"
:
[
{
"type"
:
"shell"
,
"execute_command"
:
"echo '{{user `password`}}' | {{.Vars}} sudo -E -S bash '{{.Path}}'"
,
"scripts"
:
[
"scripts/update-ubuntu.sh"
,
"scripts/packages-ubuntu.sh"
,
"scripts/setup-testing-version.sh"
,
"scripts/network-ubuntu.sh"
]
}
]
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment