EOX GitLab Instance

Commit 369e0a9a authored by Stephan Meißl's avatar Stephan Meißl
Browse files

Merge branch 'virtualbox' of /home/git/repositories/vagrant/builder_rpm

parents 01337ead 2e982fc9
.vagrant .vagrant*
build/RPMS build/RPMS
build/SOURCES build/SOURCES
build/SPECS build/SPECS
build/SRPMS build/SRPMS
\ No newline at end of file
# Builder-RPM # Builder-RPM
Welcome to our [vagrant](http://www.vagrantup.com) based build system for RPMs. Welcome to our [vagrant](http://www.vagrantup.com) based build system for RPMs.
If you need assistence you can (almost) always reach us on [IRC](https://irc.eox.at), channel *#eox* If you need assistence you can (almost) always reach us on [IRC](https://irc.eox.at), channel *#eox*
## (Currently) Supported Projects ## (Currently) Supported Projects
Currently we _automagically_ install the build dependencies for the following projects. For an up-to-date list (in case somebody forgot to add his project to thos list, see [puppet/modules](puppet/modules/)). Currently we _automagically_ install the build dependencies for the following projects. For an up-to-date list (in case somebody forgot to add his project to thos list, see [puppet/modules](puppet/modules/)).
* eox-release (which doesn't have any, so it's easy) * eox-release (which doesn't have any, so it's easy)
* mapserver * mapserver
* rasdaman * rasdaman
* eoxserver * eoxserver
* mapserver * mapserver
* mapcache * mapcache
* gdal-shibboleth * gdal-shibboleth
* ngeo-b * ngeo-b
If your software mentions all build dependencies in its SPEC file, you don't need to create a new puppet module. If your software mentions all build dependencies in its SPEC file, you don't need to create a new puppet module.
## Vagrant Installation ## Vagrant Installation
Previously you could install vagrant via rubygems (e.g. using bundler), but since 1.1.x this method is deprecated, so please go to http://downloads.vagrantup.com/ and download the latest package for your operating system. On Debian / Ubuntu run the f.ex. following command. Previously you could install vagrant via rubygems (e.g. using bundler), but since 1.1.x this method is deprecated, so please go to http://downloads.vagrantup.com/ and download the latest package for your operating system. On Debian / Ubuntu run the f.ex. following command.
```bash ```bash
gem uninstall vagrant gem uninstall vagrant
wget http://files.vagrantup.com/packages/87613ec9392d4660ffcb1d5755307136c06af08c/vagrant_x86_64.deb wget http://files.vagrantup.com/packages/87613ec9392d4660ffcb1d5755307136c06af08c/vagrant_x86_64.deb
sudo dpkg -i vagrant_x86_64.deb sudo dpkg -i vagrant_x86_64.deb
``` ```
Install a vagrant plugin to keep the virtualbox guest additions up-to-date. Install a vagrant plugin to keep the virtualbox guest additions up-to-date.
```bash ```bash
vagrant plugin install vagrant-vbguest vagrant plugin install vagrant-vbguest
``` ```
## To start building ## To start building
Clone this project! Clone this project!
```bash ```bash
git clone https://gitlab.eox.at/vagrant/builder_rpm.git ./ git clone https://gitlab.eox.at/vagrant/builder_rpm.git ./
``` ```
Edit the _Vagrantfile_ and update the project (see the beginning of [Vagrantfile](/vagrant/builder_rpm/tree/master/Vagrantfile)) Edit the _Vagrantfile_ and update the project (see the beginning of [Vagrantfile](/vagrant/builder_rpm/tree/master/Vagrantfile))
Copy your source archive into the _build/SOURCES_ folder, your spec file into the _build/SPECS_ folder, start the VM and open a SSH connection Copy your source archive into the _build/SOURCES_ folder, your spec file into the _build/SPECS_ folder, start the VM and open a SSH connection
```bash ```bash
vagrant up vagrant up
vagrant ssh vagrant ssh
``` ```
Change to the _rpmbuild_ folder and start building Change to the _rpmbuild_ folder and start building
```bash ```bash
cd rpmbuild cd rpmbuild
yum-builddep SPECS/project.spec yum-builddep SPECS/project.spec
rpmdev-bumpspec --comment="<COMMENT>" --userstring="<NAME> <<MAIL>>" SPECS/project.spec rpmdev-bumpspec --comment="<COMMENT>" --userstring="<NAME> <<MAIL>>" SPECS/project.spec
rpmbuild -ba SPECS/project.spec rpmbuild -ba SPECS/project.spec
``` ```
Wait... On your own machine, you can now find your RPMs in the _build/RPMS_ and _build/SRPMS_ folders. Done! Wait... On your own machine, you can now find your RPMs in the _build/RPMS_ and _build/SRPMS_ folders. Done!
## How to add a new project ## How to add a new project
* Find out, what the projects build dependencies are * Find out, what the projects build dependencies are
* Create a new puppet module inside the _puppet/modules_ directory. (See the [rasdaman module](/vagrant/builder_rpm/tree/master/puppet/modules/rasdaman) for an example) * Create a new puppet module inside the _puppet/modules_ directory. (See the [rasdaman module](/vagrant/builder_rpm/tree/master/puppet/modules/rasdaman) for an example)
* Update the Readme.md and add the new project * Update the Readme.md and add the new project
* Create a merge request * Create a merge request
If you are not sure, you can also email the build dependencies to marko.locher@eox.at and I'll do it for you! If you are not sure, you can also email the build dependencies to marko.locher@eox.at and I'll do it for you!
...@@ -22,6 +22,8 @@ Vagrant.configure("2") do |config| ...@@ -22,6 +22,8 @@ Vagrant.configure("2") do |config|
# doesn't already exist on the user's system. # doesn't already exist on the user's system.
config.vm.box_url = "http://downloads.eox.at/boxes/centos64.box" config.vm.box_url = "http://downloads.eox.at/boxes/centos64.box"
config.vm.hostname = "builder-rpm-vagrant"
# Create a forwarded port mapping which allows access to a specific port # Create a forwarded port mapping which allows access to a specific port
# within the machine from a port on the host machine. In the example below, # within the machine from a port on the host machine. In the example below,
# accessing "localhost:8080" will access port 80 on the guest machine. # accessing "localhost:8080" will access port 80 on the guest machine.
...@@ -50,8 +52,17 @@ Vagrant.configure("2") do |config| ...@@ -50,8 +52,17 @@ Vagrant.configure("2") do |config|
# backing providers for Vagrant. These expose provider-specific options. # backing providers for Vagrant. These expose provider-specific options.
# View the documentation for the provider you're using for more # View the documentation for the provider you're using for more
# information on available options. # information on available options.
config.vm.provider :virtualbox do |vb| config.vm.provider "virtualbox" do |v|
vb.customize ["modifyvm", :id, "--memory", 1024] # Custom name
v.name = "builder_rpm"
# Increase memory and cpus
v.customize ["modifyvm", :id, "--memory", 1024, "--cpus", 2]
# Increase performance i.e. don't use swap extensively
v.customize ["modifyvm", :id, "--ioapic", "on", "--largepages", "off", "--vtxvpid", "off"]
# Use GUI for debugging purposes
#v.gui = true
end end
# Enable provisioning with Puppet stand alone. Puppet manifests # Enable provisioning with Puppet stand alone. Puppet manifests
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment