+++ /dev/null
-##############################################################################
-# Copyright (c) 2015 Ericsson AB and others.
-# stefan.k.berg@ericsson.com
-# jonas.bjurel@ericsson.com
-# All rights reserved. This program and the accompanying materials
-# are made available under the terms of the Apache License, Version 2.0
-# which accompanies this distribution, and is available at
-# http://www.apache.org/licenses/LICENSE-2.0
-##############################################################################
-
-TOP := $(shell pwd)
-
-.PHONY: all
-all:
-
-.PHONY: clean
-clean:
- @rm -rf tmp
- @rm -rf release
-
-
-.PHONY: release
-release:
- @cp -Rvp puppet/modules/* ../release/puppet/modules
+++ /dev/null
-##############################################################################
-# Copyright (c) 2015 Ericsson AB and others.
-# stefan.k.berg@ericsson.com
-# jonas.bjurel@ericsson.com
-# All rights reserved. This program and the accompanying materials
-# are made available under the terms of the Apache License, Version 2.0
-# which accompanies this distribution, and is available at
-# http://www.apache.org/licenses/LICENSE-2.0
-##############################################################################
-
-TOP := $(shell pwd)
-
-.PHONY: all
-all:
-
-.PHONY: clean
-clean:
- @rm -rf tmp
- @rm -rf release
-
-
-.PHONY: release
-release:
- @cp -Rvp puppet/modules/* ../release/puppet/modules
# http://www.apache.org/licenses/LICENSE-2.0
##############################################################################
-How to setup and use the OPNFV/BGS/FUEL build system - work in progress
+How to setup and use the OPNFV/BGS/FUEL build system
+====================================================
1. Build system requirements
----------------------------
1.1 Host HW/VM requirements
---------------------------
-- A x86_64 host (real iron or VM) with Ubuntu 12.04/14.04 LTS installed
-- 100 GB storage
-- 8 GB RAM
+- An x86_64 host (real iron or VM) with Ubuntu 14.04 LTS installed
+- ~30 GB available disc
+- 4 GB RAM
1.2 Host SW dependencies
------------------------
+The host should run Ubuntu 14.04
On the host, the following packages must be installed:
-- docker - see https://docs.docker.com/installation/ubuntulinux/ for installation notes for 12.04 and 14.04
+- docker - see https://docs.docker.com/installation/ubuntulinux/ for installation notes
+for Ubuntu 14.04. Note: only use the Ubuntu stock distro of Docker (docker.io)
- git (simply available through apt-get install git)
+- make (simply available through apt-get install make)
2 Setting up the Docker build container
----------------------------------------
in your /etc/default/docker config file, eg.
DOCKER_OPTS=" --dns=8.8.8.8 --dns=8.8.8.4"
-Then restart docker with "service docker restart".:
+Then restart docker with "service docker.io restart".:
3. Setting up OPNFV Gerrit in order to being able to clone the code
-------------------------------------------------------------------
5. Set up (build) your build environment
----------------------------------------
-YOU DO NOT NEED TO SET UP YOUR BUILD ENVIRONMENT, THE TOP MAKE ALL TARGET WILL DO THAT FOR YOU IF NOT ALREADY DONE,
-THE BELOW ACTIONS IN THIS SECTION ARE NOT NEEDED!
-
-Note and TODO:
-The build system will for now partly run as sudo as that is needed for the debootstrap procedure to create the root file
-system for the Ubuntu 12.04 Docker image - BUT NOTE, NONE OF THE MAKEFILES OR SCRIPTS SHALL BE EXECUTED WITH SUDO/ROOT PRIVILEDGES!
-(TODO: Change the scripts so that no root priviledges will be needed)
-
-With your ordinary user-, run the following commands from your git root:
-cd docker
-make (and you will be prompted for your password by sudo)
-cd ..
+Select the versions of the components you want to build by editing the
+fuel-build/config-spec file. Note if you want to build with OpenDaylight
+SDN controller you need to uncomment the lines starting with odl-main and
+java-main
6. Build your fuel .iso image
-----------------------------
This will:
- If not allready existing, initialize the docker build environment
-- If not already done, build fuel from upstream
-- Build the defined derivate of fuel (as defined by the structure of this framework)
+- If not already done, build OpenDaylight from upstream (as defined by fuel-build/
+ config-spec)
+- If not already done, build fuel from upstream (as defined by fuel-build/config-spec)
+- Build the defined additions to fuel (as defined by the structure of this framework)
+- Apply changes and patches to fuel (as defined by the structure of this framework)
+- Reconstruct a fuel .iso image
+
+If the build is successful, you will find the generated ISO file in the release
+subdirectory!
-If the build is successful, you will find the generated ISO file in the release subdirectory!
+NOTE: the build of the baseline for Fuel and odl are cached, if build results reffering
+to the same versions as specified in fuel-build/config spec has been built before, these
+packages will not be rebuilt. The cache is cleared by "make clean"
7. Install your stack
---------------------
Please see DOC/INSTALL/README
+
+NOTES and TODO:
+---------------
+The build system will for now partly run as sudo
+BUT NOTE, NONE OF THE MAKEFILES OR SCRIPTS SHALL BE EXECUTED WITH
+SUDO/ROOT PRIVILEDGES!
+TODO: Change the scripts so that no root priviledges will be needed
+
--- /dev/null
+##############################################################################
+# Copyright (c) 2015 Ericsson AB and others.
+# stefan.k.berg@ericsson.com
+# jonas.bjurel@ericsson.com
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Apache License, Version 2.0
+# which accompanies this distribution, and is available at
+# http://www.apache.org/licenses/LICENSE-2.0
+##############################################################################
+
+############################################################################
+# BEGIN of variables to customize
+#
+SHELL = /bin/bash
+
+include config.mk
+
+export BUILD_BASE = $(shell pwd)
+export DEB_DEST := $(BUILD_BASE)/release/packages/ubuntu/pool/main
+export PUPPET_DEST := $(BUILD_BASE)/release/puppet/modules
+
+ISOSRC = file:$(shell pwd)/fuel-6.0.1.iso
+ISOCACHE = $(shell pwd)/$(shell basename $(ISOSRC))
+PRODNO = "OPNFV_BGS"
+REVSTATE = "P0000"
+NEWISO = $(shell pwd)/release/opnfv-${REVSTATE}.iso
+DOCKERIMG = opnfv.org/ubuntu-builder:14.04
+# Note! Invoke with "make REVSTATE=RXXXX iso" to make release build!
+# Invoke with ICOCACHE=/full/path/to/iso if cached ISO is in non-standard location.
+#
+# END of variables to customize
+#############################################################################
+export TOPDIR := $(shell pwd)
+ORIGDIR := $(TOPDIR)/origiso
+
+SUBDIRS := f_isoroot
+SUBDIRS += f_opnfv_puppet
+SUBDIRS += f_osnaily
+SUBDIRS += f_l23network
+SUBDIRS += f_resolvconf
+SUBDIRS += f_ntp
+#SUBDIRS += f_gif
+#SUBDIRS += f_libnss
+#SUBDIRS += f_libpcs
+#SUBDIRS += f_libxt
+#SUBDIRS += f_comm_java
+#SUBDIRS += f_ca_cert
+#SUBDIRS += f_atk_wrap
+#SUBDIRS += f_jre_head
+#SUBDIRS += f_jre
+#SUBDIRS += f_java
+#SUBDIRS += f_odl
+
+
+
+# f_example is only an example of how to generate a .deb package and
+# should not be enabled in official builds.
+#SUBDIRS += f_example
+
+SUBCLEAN = $(addsuffix .clean,$(SUBDIRS))
+
+.PHONY: all
+all:
+ @docker version >/dev/null 2>&1 || (echo 'No Docker installation available'; exit 1)
+ @make -C docker
+ @docker/runcontext $(DOCKERIMG) $(MAKE) $(MAKEFLAGS) iso
+
+$(ISOCACHE):
+ # Clone Fuel to non-persistent location and build
+ cd /tmp && git clone $(FUEL_MAIN_REPO)
+ cd /tmp/fuel-main && git checkout $(FUEL_MAIN_TAG)
+ # Setup cgroups for docker-in-docker
+ sudo /root/enable_dockerx2
+ # Patch to fix race condition when doing "Docker-in-Docker" build
+ cd /tmp/fuel-main && patch -p1 < $(TOPDIR)/fuel-main_1.patch
+ # Patch to make the sandbox chroot in Fuel succeed with package
+ # installation in a Docker build
+ cd /tmp/fuel-main && patch -p1 < $(TOPDIR)/fuel-main_2.patch
+ # Remove Docker optimizations, otherwise multistrap will fail during
+ # Fuel build.
+ sudo rm -f /etc/apt/apt.conf.d/docker*
+ #
+ cd /tmp/fuel-main && ./prepare-build-env.sh
+ cd /tmp/fuel-main && make iso
+ mv /tmp/fuel-main/build/artifacts/fuel*.iso .
+
+.PHONY: mount-origiso umount-origiso
+mount-origiso: $(ISOCACHE)
+ @echo "Mounting original ISO in $(ORIGDIR)"
+ @mkdir -p $(ORIGDIR)
+ @fuseiso $(ISOCACHE) $(ORIGDIR)
+
+umount-origiso:
+ @echo "Unmounting original ISO from $(ORIGDIR)"
+ @fusermount -u $(ORIGDIR)
+ @rmdir $(ORIGDIR)
+
+.PHONY: $(SUBDIRS)
+$(SUBDIRS):
+ @mkdir -p release/packages/ubuntu/pool/main release/puppet/modules release/isoroot
+ $(MAKE) -C $@ -f Makefile release
+
+.PHONY: patch-packages
+patch-packages:
+ ORIGISO=$(ISOCACHE) REVSTATE=$(REVSTATE) $(MAKE) -C $@ -f Makefile release
+
+.PHONY: prepare
+prepare:
+ $(MAKE) -C opendaylight -f Makefile setup
+
+.PHONY: odl
+odl:
+ $(MAKE) -C opendaylight -f Makefile
+
+.PHONY: build-clean $(SUBCLEAN)
+build-clean: $(SUBCLEAN)
+ $(MAKE) -C patch-packages -f Makefile clean
+ @rm -Rf release
+ @rm -Rf newiso
+ @rm -f $(NEWISO)
+
+.PHONY: clean $(SUBCLEAN)
+clean: prepare $(SUBCLEAN)
+ $(MAKE) -C patch-packages -f Makefile clean
+ $(MAKE) -C opendaylight -f Makefile clean
+ @rm -f *.iso
+ @rm -Rf release
+ @rm -Rf newiso
+ @rm -f f_odl
+ @rm -f $(NEWISO)
+
+$(SUBCLEAN): %.clean:
+ $(MAKE) -C $* -f Makefile clean
+
+# Todo: Make things smarter - we shouldn't need to clean everything
+# betwen make invocations.
+.PHONY: iso
+iso: prepare build-clean odl $(ISOCACHE) $(SUBDIRS) patch-packages
+ install/install.sh iso $(ISOCACHE) $(NEWISO) $(PRODNO) $(REVSTATE)
+ @printf "\n\nProduct ISO is $(NEWISO)\n\n"
# BEGIN of variables to customize
#
SHELL = /bin/bash
+
+include config.mk
+
+export BUILD_BASE = $(shell pwd)
+export DEB_DEST := $(BUILD_BASE)/release/packages/ubuntu/pool/main
+export PUPPET_DEST := $(BUILD_BASE)/release/puppet/modules
+
ISOSRC = file:$(shell pwd)/fuel-6.0.1.iso
ISOCACHE = $(shell pwd)/$(shell basename $(ISOSRC))
-PRODUCT_NAME = "OPNFV_BGS"
-VERSION = "P0000"
-NEWISO = $(shell pwd)/release/opnfv-${VERSION}.iso
+PRODNO = "OPNFV_BGS"
+REVSTATE = "P0000"
+NEWISO = $(shell pwd)/release/opnfv-${REVSTATE}.iso
DOCKERIMG = opnfv.org/ubuntu-builder:14.04
-# Note! Invoke with "make VERSION=RXXXX iso" to make release build!
+# Note! Invoke with "make REVSTATE=RXXXX iso" to make release build!
# Invoke with ICOCACHE=/full/path/to/iso if cached ISO is in non-standard location.
#
# END of variables to customize
#############################################################################
-TOPDIR := $(shell pwd)
+export TOPDIR := $(shell pwd)
ORIGDIR := $(TOPDIR)/origiso
SUBDIRS := f_isoroot
SUBDIRS += f_l23network
SUBDIRS += f_resolvconf
SUBDIRS += f_ntp
+SUBDIRS += f_gif
+SUBDIRS += f_libnss
+SUBDIRS += f_libpcs
+SUBDIRS += f_libxt
+SUBDIRS += f_comm_java
+SUBDIRS += f_ca_cert
+SUBDIRS += f_atk_wrap
+SUBDIRS += f_jre_head
+SUBDIRS += f_jre
+SUBDIRS += f_java
+SUBDIRS += f_odl
+
+
# f_example is only an example of how to generate a .deb package and
# should not be enabled in official builds.
$(ISOCACHE):
# Clone Fuel to non-persistent location and build
- cd /tmp && git clone https://github.com/stackforge/fuel-main
- cd /tmp/fuel-main && git checkout stable/6.0
+ cd /tmp && git clone $(FUEL_MAIN_REPO)
+ cd /tmp/fuel-main && git checkout $(FUEL_MAIN_TAG)
# Setup cgroups for docker-in-docker
sudo /root/enable_dockerx2
# Patch to fix race condition when doing "Docker-in-Docker" build
.PHONY: patch-packages
patch-packages:
- ORIGISO=$(ISOCACHE) VERSION=$(VERSION) $(MAKE) -C $@ -f Makefile release
+ ORIGISO=$(ISOCACHE) REVSTATE=$(REVSTATE) $(MAKE) -C $@ -f Makefile release
+
+.PHONY: prepare
+prepare:
+ $(MAKE) -C opendaylight -f Makefile setup
+
+.PHONY: odl
+odl:
+ $(MAKE) -C opendaylight -f Makefile
+
+.PHONY: build-clean $(SUBCLEAN)
+build-clean: $(SUBCLEAN)
+ $(MAKE) -C patch-packages -f Makefile clean
+ @rm -Rf release
+ @rm -Rf newiso
+ @rm -f $(NEWISO)
.PHONY: clean $(SUBCLEAN)
-clean: $(SUBCLEAN)
+clean: prepare $(SUBCLEAN)
$(MAKE) -C patch-packages -f Makefile clean
+ $(MAKE) -C opendaylight -f Makefile clean
+ @rm -f *.iso
@rm -Rf release
@rm -Rf newiso
+ @rm -f f_odl
@rm -f $(NEWISO)
$(SUBCLEAN): %.clean:
# Todo: Make things smarter - we shouldn't need to clean everything
# betwen make invocations.
.PHONY: iso
-iso: clean $(ISOCACHE) $(SUBDIRS) patch-packages
- install/install.sh iso $(ISOCACHE) $(NEWISO) $(PRODUCT_NAME) $(VERSION)
+iso: prepare build-clean odl $(ISOCACHE) $(SUBDIRS) patch-packages
+ install/install.sh iso $(ISOCACHE) $(NEWISO) $(PRODNO) $(REVSTATE)
@printf "\n\nProduct ISO is $(NEWISO)\n\n"
3) Re factor/rebuild the .iso image for deployment (also builds in a container, for the same reason as mentioned above)
4) Through a pre-deployment script, setting config's not part of the pristine fuel build can be achieved
-For detailed instructions on how to add content, configuration, build and deply - please see:
-DOC/
+For detailed instructions on how to add content, configuration, build and deply - please see: DOC/
--- /dev/null
+##############################################################################
+# Copyright (c) 2015 Ericsson AB and others.
+# stefan.k.berg@ericsson.com
+# jonas.bjurel@ericsson.com
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Apache License, Version 2.0
+# which accompanies this distribution, and is available at
+# http://www.apache.org/licenses/LICENSE-2.0
+##############################################################################
+
+This patch introduces the following features and bug fixes:
+-----------------------------------------------------------
+1) The OpenDaylight SDN server - unplumbed (config.mk needs to be changed
+ in order to enable it, see: fuel-build/DOC/BUILD/README.build)
+2) cofig-spec - a way to configure the stack component versions
+ to be built - see the fuel-build/config.mk file
+3) A simplified Docker build startegy, pulling a pre-fabricated
+ docker base image from the Internet
+
+NOTE: Before you start building - you need to purge any previous
+"opnfv.org/ubuntu-builder" docker image: "sudo docker rmi -f opnfv.org/ubuntu-builder
+Double check that you dont have any remaining "opnfv.org/ubuntu-builder" images by
+"docker images".
+A new docker image will automatically be rebuilt in the build process.
+
+Limitations and known issues:
+-----------------------------
+1) OpenDaylight is for now just sitting in the controllers, not plumbed to anything
+ northbound or southbound.
+2) OpenDaylight is currently only building with Oracle Java JDK, that is Oracle Java
+ is used in the build process while OpenJava is used in the runtime environment.
+ Read the licencing obligations in /fuel-build/LICENCE before you start building.
# jonas.bjurel@ericsson.com 0.1 2015.01.28
############################################
Following items needs to be done to achieve an OPNFV/BGS R1 Stack:
-1) Rebase to Fuel 6.0/6.1
-2) Add support for CentOS 6.5
+1) Rebase to Fuel 6.0/6.1 - DONE
+2) Add support for CentOS 6.5 - REMAINING
3) Add build-support and manifests for Open daylight Ubuntu and CentOS
+ - Initial build and deployment of ODL/Helium - DONE
+ - Configuration and plumbing - IN PROGRESS
\ No newline at end of file
--- /dev/null
+##############################################################################
+# Copyright (c) 2015 Ericsson AB and others.
+# stefan.k.berg@ericsson.com
+# jonas.bjurel@ericsson.com
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Apache License, Version 2.0
+# which accompanies this distribution, and is available at
+# http://www.apache.org/licenses/LICENSE-2.0
+##############################################################################
+
+ODL_MAIN_REPO := https://git.opendaylight.org/gerrit/p/controller.git
+ODL_MAIN_TAG := release/helium
+
+FUEL_MAIN_REPO := https://github.com/stackforge/fuel-main
+FUEL_MAIN_TAG = stable/6.0
+
+JAVA_MAIN_REPO := https://mirrors.kernel.org/ubuntu/pool/universe/o/openjdk-8
+ATK_MAIN_REPO := https://mirrors.kernel.org/ubuntu/pool/main/j/java-atk-wrapper
+GIF_MAIN_REPO := https://mirrors.kernel.org/ubuntu/pool/main/g/giflib
+CERT_MAIN_REPO := https://mirrors.kernel.org/ubuntu/pool/main/c/ca-certificates
+COMM_MAIN_REPO := https://mirrors.kernel.org/ubuntu/pool/main/j/java-common
+LIBPCS_MAIN_REPO := https://mirrors.kernel.org/ubuntu/pool/main/p/pcsc-lite
+LIBXT_MAIN_REPO := https://mirrors.kernel.org/ubuntu/pool/main/libx/libxtst
+DEFJRE_MAIN_REPO := https://mirrors.kernel.org/ubuntu/pool/main/j/java-common
+LIBNSS_MAIN_REPO := https://mirrors.kernel.org/ubuntu/pool/main/n/nss
all: .docker
.docker: $(FILES)
- /usr/bin/docker build --rm=true -t opnfv.org/ubuntu-builder:14.04 ubuntu-builder
+ /usr/bin/docker build --rm=true --no-cache=true -t opnfv.org/ubuntu-builder:14.04 ubuntu-builder
/usr/bin/docker tag -f opnfv.org/ubuntu-builder:14.04 opnfv.org/ubuntu-builder
touch .docker
FROM ubuntu:14.04
RUN apt-get update
-RUN apt-get install -y make python-setuptools python-all dpkg-dev debhelper \
+RUN apt-get install -y software-properties-common python-software-properties \
+ make python-setuptools python-all dpkg-dev debhelper \
fuseiso git genisoimage bind9-host wget curl lintian tmux lxc iptables \
ca-certificates sudo apt-utils lsb-release
RUN echo "ALL ALL=NOPASSWD: ALL" > /etc/sudoers.d/open-sudo
RUN chmod 0440 /etc/sudoers.d/open-sudo
+RUN chmod 4755 /bin/fusermount
ADD ./setcontext /root/setcontext
RUN chmod +x /root/setcontext
ADD ./enable_dockerx2 /root/enable_dockerx2
RUN chmod +x /root/enable_dockerx2
+ADD ./install.sh /root/install.sh
+RUN chmod +x /root/install.sh
+RUN /root/install.sh
+
VOLUME /var/lib/docker
##############################################################################
#
# Needed to expose underlying cgroups to container
+echo "running x2" > /x2
mount -n -t tmpfs -o uid=0,gid=0,mode=0755 cgroup /sys/fs/cgroup
mount -t securityfs none /sys/kernel/security
--- /dev/null
+#!/bin/bash
+##############################################################################
+# Copyright (c) 2015 Ericsson AB and others.
+# stefan.k.berg@ericsson.com
+# jonas.bjurel@ericsson.com
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Apache License, Version 2.0
+# which accompanies this distribution, and is available at
+# http://www.apache.org/licenses/LICENSE-2.0
+##############################################################################
+
+#Install Oracle Java 7 jdk
+echo "Installing JAVA 7"
+apt-get update
+add-apt-repository ppa:webupd8team/java -y
+apt-get update
+echo debconf shared/accepted-oracle-license-v1-1 select true | debconf-set-selections
+apt-get install oracle-java7-installer -y
+
+#Install Maven 3
+echo deb http://ppa.launchpad.net/natecarlson/maven3/ubuntu precise main >> /etc/apt/sources.list
+echo deb-src http://ppa.launchpad.net/natecarlson/maven3/ubuntu precise main >> /etc/apt/sources.list
+apt-get update || exit 1
+sudo apt-get install -y --force-yes maven3 || exit 1
+ln -s /usr/share/maven3/bin/mvn /usr/bin/mvn
--- /dev/null
+##############################################################################
+# Copyright (c) 2015 Ericsson AB and others.
+# daniel.smith@ericsson.com
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Apache License, Version 2.0
+# which accompanies this distribution, and is available at
+# http://www.apache.org/licenses/LICENSE-2.0
+##############################################################################
+
+TOP := $(shell pwd)
+include ../config.mk
+
+PACKAGE := libatk-wrapper-java
+VERSION := 0.30.4-4_all
+DEB_NAME := $(PACKAGE)_$(VERSION).deb
+
+.PHONY: all
+all: release/pool/main/$(DEB_NAME)
+
+release/pool/main/$(DEB_NAME):
+ifeq ($(ATK_MAIN_REPO),)
+ @echo "No config-spec target for Java, nothing to build"
+else
+ @mkdir -p release/pool/main && \
+ cd release/pool/main && \
+ wget -N $(ATK_MAIN_REPO)/$(DEB_NAME)
+ @lintian release/pool/main/$(DEB_NAME)
+endif
+
+.PHONY: clean
+clean:
+ @rm -rf release
+ @rm -f $(DEB_DEST)/$(DEB_NAME)
+
+
+.PHONY: release
+release:release/pool/main/$(DEB_NAME)
+ifneq ($(ATK_MAIN_REPO),)
+ @cp release/pool/main/$(DEB_NAME) $(DEB_DEST)
+ @cp -Rvp puppet/modules/* $(PUPPET_DEST)
+endif
+
--- /dev/null
+class opnfv::atk_wrap {
+ if $::osfamily == 'Debian' {
+ case $::fuel_settings['role'] {
+ /controller/: {
+ package { 'libatk-wrapper-java':
+ ensure => installed,
+ }
+ }
+ }
+ }
+}
+
--- /dev/null
+##############################################################################
+# Copyright (c) 2015 Ericsson AB and others.
+# stefan.k.berg@ericsson.com
+# jonas.bjurel@ericsson.com
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Apache License, Version 2.0
+# which accompanies this distribution, and is available at
+# http://www.apache.org/licenses/LICENSE-2.0
+##############################################################################
+
+TOP := $(shell pwd)
+include ../config.mk
+
+PACKAGE := ca-certificates
+VERSION := 20130906ubuntu2_all
+DEB_NAME := $(PACKAGE)_$(VERSION).deb
+
+.PHONY: all
+all: release/pool/main/$(DEB_NAME)
+
+release/pool/main/$(DEB_NAME):
+ifeq ($(CERT_MAIN_REPO),)
+ @echo "No config-spec target for Java, nothing to build"
+else
+ @mkdir -p release/pool/main && \
+ cd release/pool/main && \
+ wget -N $(CERT_MAIN_REPO)/$(DEB_NAME)
+ @lintian release/pool/main/$(DEB_NAME)
+endif
+
+.PHONY: clean
+clean:
+ @rm -rf release
+ @rm -f $(DEB_DEST)/$(DEB_NAME)
+
+
+.PHONY: release
+release:release/pool/main/$(DEB_NAME)
+ifneq ($(CERT_MAIN_REPO),)
+ @cp release/pool/main/$(DEB_NAME) $(DEB_DEST)
+ @cp -Rvp puppet/modules/* $(PUPPET_DEST)
+endif
--- /dev/null
+class opnfv::ca_cert {
+ if $::osfamily == 'Debian' {
+ case $::fuel_settings['role'] {
+ /controller/: {
+ package { 'ca-certificates':
+ ensure => installed,
+ }
+ }
+ }
+ }
+}
--- /dev/null
+##############################################################################
+# Copyright (c) 2015 Ericsson AB and others.
+# stefan.k.berg@ericsson.com
+# jonas.bjurel@ericsson.com
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Apache License, Version 2.0
+# which accompanies this distribution, and is available at
+# http://www.apache.org/licenses/LICENSE-2.0
+##############################################################################
+
+TOP := $(shell pwd)
+include ../config.mk
+
+PACKAGE := java-common
+VERSION := 0.51_all
+DEB_NAME := $(PACKAGE)_$(VERSION).deb
+
+.PHONY: all
+all: release/pool/main/$(DEB_NAME)
+
+release/pool/main/$(DEB_NAME):
+ifeq ($(COMM_MAIN_REPO),)
+ @echo "No config-spec target for Java, nothing to build"
+else
+ @mkdir -p release/pool/main && \
+ cd release/pool/main && \
+ wget -N $(COMM_MAIN_REPO)/$(DEB_NAME)
+ @lintian release/pool/main/$(DEB_NAME)
+endif
+
+.PHONY: clean
+clean:
+ @rm -rf release
+ @rm -f $(DEB_DEST)/$(DEB_NAME)
+
+
+.PHONY: release
+release:release/pool/main/$(DEB_NAME)
+ifneq ($(COMM_MAIN_REPO),)
+ @cp release/pool/main/$(DEB_NAME) $(DEB_DEST)
+ @cp -Rvp puppet/modules/* $(PUPPET_DEST)
+endif
--- /dev/null
+class opnfv::comm_java {
+ if $::osfamily == 'Debian' {
+ case $::fuel_settings['role'] {
+ /controller/: {
+ package { 'java-common':
+ ensure => installed,
+ }
+ }
+ }
+ }
+}
--- /dev/null
+##############################################################################
+# Copyright (c) 2015 Ericsson AB and others.
+# stefan.k.berg@ericsson.com
+# jonas.bjurel@ericsson.com
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Apache License, Version 2.0
+# which accompanies this distribution, and is available at
+# http://www.apache.org/licenses/LICENSE-2.0
+##############################################################################
+
+TOP := $(shell pwd)
+include ../config.mk
+
+PACKAGE := default-jre
+VERSION := 1.7-51_amd64
+DEB_NAME := $(PACKAGE)_$(VERSION).deb
+
+.PHONY: all
+all: release/pool/main/$(DEB_NAME)
+
+release/pool/main/$(DEB_NAME):
+ifeq ($(DEFJRE_MAIN_REPO),)
+ @echo "No config-spec target for Java, nothing to build"
+else
+ @mkdir -p release/pool/main && \
+ cd release/pool/main && \
+ wget -N $(DEFJRE_MAIN_REPO)/$(DEB_NAME)
+ @lintian release/pool/main/$(DEB_NAME)
+endif
+
+.PHONY: clean
+clean:
+ @rm -rf release
+ @rm -f $(DEB_DEST)/$(DEB_NAME)
+
+
+.PHONY: release
+release:release/pool/main/$(DEB_NAME)
+ifneq ($(DEFJRE_MAIN_REPO),)
+ @cp release/pool/main/$(DEB_NAME) $(DEB_DEST)
+ @cp -Rvp puppet/modules/* $(PUPPET_DEST)
+endif
--- /dev/null
+class opnfv::defjre {
+ if $::osfamily == 'Debian' {
+ case $::fuel_settings['role'] {
+ /controller/: {
+ package { 'default-jre':
+ ensure => installed,
+ }
+ }
+ }
+ }
+}
.PHONY: release
release:
- @cp -Rvp puppet/modules/* ../release/puppet/modules
+ @cp -Rvp puppet/modules/* $(PUPPET_DEST)
TOP := $(shell pwd)
PACKAGE := foobar
VERSION := 1.0-1
+DEB_NAME := $(PACKAGE)_$(VERSION).deb
.PHONY: all
-all: release/pool/main/$(PACKAGE)_$(VERSION).deb
+all: release/pool/main/$(DEB_NAME)
-release/pool/main/$(PACKAGE)_$(VERSION).deb:
+release/pool/main/$(DEB_NAME):
@mkdir -p tmp/src
@mkdir -p release/pool/main
- @cp -r $(PACKAGE)_$(VERSION) tmp/src
- @gzip -9 tmp/src/$(PACKAGE)_$(VERSION)/usr/share/doc/$(PACKAGE)/changelog.Debian
- @fakeroot dpkg-deb --build tmp/src/$(PACKAGE)_$(VERSION)
- @lintian tmp/src/$(PACKAGE)_$(VERSION).deb
- @cp tmp/src/$(PACKAGE)_$(VERSION).deb release/pool/main
+ @cp -r $(DEB_NAME) tmp/src
+ @gzip -9 tmp/src/$(DEB_NAME)/usr/share/doc/$(PACKAGE)/changelog.Debian
+ @fakeroot dpkg-deb --build tmp/src/$(DEB_NAME)
+ @lintian tmp/src/$(DEB_NAME)
+ @cp tmp/src/$(DEB_NAME) release/pool/main
.PHONY: clean
clean:
@rm -rf tmp
@rm -rf release
- @rm -f ../release/packages/ubuntu/pool/main/$(PACKAGE)_$(VERSION).deb
+ @rm -f ../release/packages/ubuntu/pool/main/$(DEB_NAME)
.PHONY: release
-release:release/pool/main/$(PACKAGE)_$(VERSION).deb
- @cp release/pool/main/$(PACKAGE)_$(VERSION).deb ../release/packages/ubuntu/pool/main
- @cp -Rvp puppet/modules/* ../release/puppet/modules
+release:release/pool/main/$(DEB_NAME)
+ @cp release/pool/main/$(DEB_NAME) $(DEB_DEST)
+ @cp -Rvp puppet/modules/* $(PUPPET_DEST)
--- /dev/null
+##############################################################################
+# Copyright (c) 2015 Ericsson AB and others.
+# stefan.k.berg@ericsson.com
+# jonas.bjurel@ericsson.com
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Apache License, Version 2.0
+# which accompanies this distribution, and is available at
+# http://www.apache.org/licenses/LICENSE-2.0
+##############################################################################
+
+TOP := $(shell pwd)
+include ../config.mk
+
+PACKAGE := libgif4
+VERSION := 4.1.6-11_amd64
+DEB_NAME := $(PACKAGE)_$(VERSION).deb
+
+.PHONY: all
+all: release/pool/main/$(DEB_NAME)
+
+release/pool/main/$(DEB_NAME):
+ifeq ($(GIF_MAIN_REPO),)
+ @echo "No config-spec target for Java, nothing to build"
+else
+ @mkdir -p release/pool/main && \
+ cd release/pool/main && \
+ wget -N $(GIF_MAIN_REPO)/$(DEB_NAME)
+ @lintian release/pool/main/$(DEB_NAME)
+endif
+
+.PHONY: clean
+clean:
+ @rm -rf release
+ @rm -f $(DEB_DEST)/$(DEB_NAME)
+
+
+.PHONY: release
+release:release/pool/main/$(DEB_NAME)
+ifneq ($(GIF_MAIN_REPO),)
+ @cp release/pool/main/$(DEB_NAME) $(DEB_DEST)
+ @cp -Rvp puppet/modules/* $(PUPPET_DEST)
+endif
--- /dev/null
+class opnfv::gif {
+ if $::osfamily == 'Debian' {
+ case $::fuel_settings['role'] {
+ /controller/: {
+ package { 'libgif4':
+ ensure => installed,
+ }
+ }
+ }
+ }
+}
--- /dev/null
+##############################################################################
+# Copyright (c) 2015 Ericsson AB and others.
+# stefan.k.berg@ericsson.com
+# jonas.bjurel@ericsson.com
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Apache License, Version 2.0
+# which accompanies this distribution, and is available at
+# http://www.apache.org/licenses/LICENSE-2.0
+##############################################################################
+
+TOP := $(shell pwd)
+include ../config.mk
+
+PACKAGE := openjdk-8-jdk
+VERSION := 8u40~b09-1_amd64
+DEB_NAME := $(PACKAGE)_$(VERSION).deb
+
+.PHONY: all
+all: release/pool/main/$(DEB_NAME)
+
+release/pool/main/$(DEB_NAME):
+ifeq ($(JAVA_MAIN_REPO),)
+ @echo "No config-spec target for Java, nothing to build"
+else
+ @mkdir -p release/pool/main && \
+ cd release/pool/main && \
+ wget -N $(JAVA_MAIN_REPO)/$(DEB_NAME)
+ @lintian release/pool/main/$(DEB_NAME)
+endif
+
+.PHONY: clean
+clean:
+ @rm -rf release
+ @rm -f $(DEB_DEST)/$(DEB_NAME)
+
+
+.PHONY: release
+release:release/pool/main/$(DEB_NAME)
+ifneq ($(JAVA_MAIN_REPO),)
+ @cp release/pool/main/$(DEB_NAME) $(DEB_DEST)
+ @cp -Rvp puppet/modules/* $(PUPPET_DEST)
+endif
--- /dev/null
+##############################################################################
+# Copyright (c) 2015 Ericsson AB and others.
+# stefan.k.berg@ericsson.com
+# jonas.bjurel@ericsson.com
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Apache License, Version 2.0
+# which accompanies this distribution, and is available at
+# http://www.apache.org/licenses/LICENSE-2.0
+##############################################################################
+
+This directory adds the openjdk-8-jdk Java package and related puppet
+deployment manifest such that it gets built into the .iso image an deployed
+on the stack controller cluster.
+
+The f_java has the following structure:
+.
++--------+----------+-----------+
+ | | |
+ puppet/ Makefile README
+ | (this file)
+ |
+ |
+ modules/
+ |
+ |
+ |
+ opnfv/
+ |
+ |
+ |
+ manifests/
+ |
+ |
+ |
+ java.pp
+
+Makefile:
+Invoked by the git root Makefile, it pulls the openjdk-8-jdk deb package
+from a propper mirror and pushes i together with the manifests to a fuel
+build artifact directory, such that it eventually gets built into the new
+fuel .iso
+
+java.pp:
+Controls the installation and configuration of java
--- /dev/null
+class opnfv::java {
+ if $::osfamily == 'Debian' {
+ case $::fuel_settings['role'] {
+ /controller/: {
+ package { 'openjdk-8-jdk':
+ ensure => installed,
+ }
+ }
+ }
+ }
+}
--- /dev/null
+##############################################################################
+# Copyright (c) 2015 Ericsson AB and others.
+# stefan.k.berg@ericsson.com
+# jonas.bjurel@ericsson.com
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Apache License, Version 2.0
+# which accompanies this distribution, and is available at
+# http://www.apache.org/licenses/LICENSE-2.0
+##############################################################################
+
+In order to test the functionality without performing a full deployment, run "puppet apply" on the
+fake_init.pp which will call only the opnfv::java class.
--- /dev/null
+##############################################################################
+# Copyright (c) 2015 Ericsson AB and others.
+# stefan.k.berg@ericsson.com
+# jonas.bjurel@ericsson.com
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Apache License, Version 2.0
+# which accompanies this distribution, and is available at
+# http://www.apache.org/licenses/LICENSE-2.0
+##############################################################################
+
+$fuel_settings = parseyaml($astute_settings_yaml)
+
+include opnfv::java
--- /dev/null
+##############################################################################
+# Copyright (c) 2015 Ericsson AB and others.
+# daniel.smith@ericsson.com
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Apache License, Version 2.0
+# which accompanies this distribution, and is available at
+# http://www.apache.org/licenses/LICENSE-2.0
+##############################################################################
+
+TOP := $(shell pwd)
+include ../config.mk
+
+PACKAGE := openjdk-8-jre
+VERSION := 8u40~b09-1_amd64
+DEB_NAME := $(PACKAGE)_$(VERSION).deb
+
+.PHONY: all
+all: release/pool/main/$(DEB_NAME)
+
+release/pool/main/$(DEB_NAME):
+ifeq ($(JAVA_MAIN_REPO),)
+ @echo "No config-spec target for Java, nothing to build"
+else
+ @mkdir -p release/pool/main && \
+ cd release/pool/main && \
+ wget -N $(JAVA_MAIN_REPO)/$(DEB_NAME)
+endif
+
+.PHONY: clean
+clean:
+ @rm -rf release
+ @rm -f $(DEB_DEST)/$(DEB_NAME)
+
+
+.PHONY: release
+release:release/pool/main/$(DEB_NAME)
+ifneq ($(JAVA_MAIN_REPO),)
+ @cp release/pool/main/$(DEB_NAME) $(DEB_DEST)
+ @cp -Rvp puppet/modules/* $(PUPPET_DEST)
+endif
+
--- /dev/null
+
+##############################################################################
+# Copyright (c) 2015 Ericsson AB and others.
+# daniel.smith@ericsson.com
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Apache License, Version 2.0
+# which accompanies this distribution, and is available at
+# http://www.apache.org/licenses/LICENSE-2.0
+##############################################################################
+
+This directory adds the openjdk-8-jre Java package and related puppet
+deployment manifest such that it gets built into the .iso image an deployed
+on the stack controller cluster.
+
+The f_jre has the following structure:
+.
++--------+----------+-----------+
+ | | |
+ puppet/ Makefile README
+ | (this file)
+ |
+ |
+ modules/
+ |
+ |
+ |
+ opnfv/
+ |
+ |
+ |
+ manifests/
+ |
+ |
+ |
+ jre.pp
+
+Makefile:
+Invoked by the git root Makefile, it pulls the openjdk-8-jre deb package
+from a propper mirror and pushes i together with the manifests to a fuel
+build artifact directory, such that it eventually gets built into the new
+fuel .iso
+
+jre.pp:
+Controls the installation and configuration of java
--- /dev/null
+class opnfv::jre {
+ if $::osfamily == 'Debian' {
+
+
+ case $::fuel_settings['role'] {
+ /controller/: {
+ package { 'openjdk-8-jre':
+ ensure => installed,
+ }
+ }
+ }
+ }
+}
+
--- /dev/null
+##############################################################################
+# Copyright (c) 2015 Ericsson AB and others.
+# stefan.k.berg@ericsson.com
+# jonas.bjurel@ericsson.com
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Apache License, Version 2.0
+# which accompanies this distribution, and is available at
+# http://www.apache.org/licenses/LICENSE-2.0
+##############################################################################
+
+In order to test the functionality without performing a full deployment, run "puppet apply" on the
+fake_init.pp which will call only the opnfv::java class.
+
--- /dev/null
+##############################################################################
+# Copyright (c) 2015 Ericsson AB and others.
+# daniel.smith@ericsson.com
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Apache License, Version 2.0
+# which accompanies this distribution, and is available at
+# http://www.apache.org/licenses/LICENSE-2.0
+##############################################################################
+
+$fuel_settings = parseyaml($astute_settings_yaml)
+
+include opnfv::jre
+
--- /dev/null
+##############################################################################
+# Copyright (c) 2015 Ericsson AB and others.
+# daniel.smith@ericsson.com
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Apache License, Version 2.0
+# which accompanies this distribution, and is available at
+# http://www.apache.org/licenses/LICENSE-2.0
+##############################################################################
+
+TOP := $(shell pwd)
+include ../config.mk
+
+PACKAGE := openjdk-8-jre-headless
+VERSION := 8u40~b09-1_amd64
+DEB_NAME := $(PACKAGE)_$(VERSION).deb
+
+
+.PHONY: all
+all: release/pool/main/$(DEB_NAME)
+
+release/pool/main/$(DEB_NAME):
+ifeq ($(JAVA_MAIN_REPO),)
+ @echo "No config-spec target for Java, nothing to build"
+else
+ @mkdir -p release/pool/main && \
+ cd release/pool/main && \
+ wget -N $(JAVA_MAIN_REPO)/$(DEB_NAME)
+ @lintian release/pool/main/$(DEB_NAME)
+endif
+
+.PHONY: clean
+clean:
+ @rm -rf release
+ @rm -f $(DEB_DEST)/$(DEB_NAME)
+
+
+.PHONY: release
+release:release/pool/main/$(DEB_NAME)
+ifneq ($(JAVA_MAIN_REPO),)
+ @cp release/pool/main/$(DEB_NAME) $(DEB_DEST)
+ @cp -Rvp puppet/modules/* $(PUPPET_DEST)
+endif
+
--- /dev/null
+class opnfv::jre_head {
+ if $::osfamily == 'Debian' {
+
+ case $::fuel_settings['role'] {
+ /controller/: {
+
+ package { 'openjdk-8-jre-headless' :
+ ensure => installed,
+ }
+
+ }
+ }
+ }
+}
+
.PHONY: release
release:
- @cp -Rvp puppet/modules/* ../release/puppet/modules
+ @cp -Rvp puppet/modules/* $(PUPPET_DEST)
--- /dev/null
+##############################################################################
+# Copyright (c) 2015 Ericsson AB and others.
+# stefan.k.berg@ericsson.com
+# jonas.bjurel@ericsson.com
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Apache License, Version 2.0
+# which accompanies this distribution, and is available at
+# http://www.apache.org/licenses/LICENSE-2.0
+##############################################################################
+
+TOP := $(shell pwd)
+include ../config.mk
+
+PACKAGE := libnss3
+VERSION := 3.17.4-0ubuntu0.14.04.1_amd64
+DEB_NAME := $(PACKAGE)_$(VERSION).deb
+
+.PHONY: all
+all: release/pool/main/$(DEB_NAME)
+
+release/pool/main/$(DEB_NAME):
+ifeq ($(LIBNSS_MAIN_REPO),)
+ @echo "No config-spec target for Java, nothing to build"
+else
+ @mkdir -p release/pool/main && \
+ cd release/pool/main && \
+ wget -N $(LIBNSS_MAIN_REPO)/$(DEB_NAME)
+ @lintian release/pool/main/$(DEB_NAME)
+endif
+
+.PHONY: clean
+clean:
+ @rm -rf release
+ @rm -f $(DEB_DEST)/$(DEB_NAME)
+
+
+.PHONY: release
+release:release/pool/main/$(DEB_NAME)
+ifneq ($(LIBNSS_MAIN_REPO),)
+ @cp release/pool/main/$(DEB_NAME) $(DEB_DEST)
+ @cp -Rvp puppet/modules/* $(PUPPET_DEST)
+endif
--- /dev/null
+##############################################################################
+# Copyright (c) 2015 Ericsson AB and others.
+# stefan.k.berg@ericsson.com
+# jonas.bjurel@ericsson.com
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Apache License, Version 2.0
+# which accompanies this distribution, and is available at
+# http://www.apache.org/licenses/LICENSE-2.0
+##############################################################################
+
+This directory adds the openjdk-8-jdk Java package and related puppet
+deployment manifest such that it gets built into the .iso image an deployed
+on the stack controller cluster.
+
+The f_java has the following structure:
+.
++--------+----------+-----------+
+ | | |
+ puppet/ Makefile README
+ | (this file)
+ |
+ |
+ modules/
+ |
+ |
+ |
+ opnfv/
+ |
+ |
+ |
+ manifests/
+ |
+ |
+ |
+ java.pp
+
+Makefile:
+Invoked by the git root Makefile, it pulls the openjdk-8-jdk deb package
+from a propper mirror and pushes i together with the manifests to a fuel
+build artifact directory, such that it eventually gets built into the new
+fuel .iso
+
+java.pp:
+Controls the installation and configuration of java
--- /dev/null
+class opnfv::libnss {
+ if $::osfamily == 'Debian' {
+ case $::fuel_settings['role'] {
+ /controller/: {
+ package { 'libnss3':
+ ensure => installed,
+ }
+ }
+ }
+ }
+}
--- /dev/null
+##############################################################################
+# Copyright (c) 2015 Ericsson AB and others.
+# stefan.k.berg@ericsson.com
+# jonas.bjurel@ericsson.com
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Apache License, Version 2.0
+# which accompanies this distribution, and is available at
+# http://www.apache.org/licenses/LICENSE-2.0
+##############################################################################
+
+In order to test the functionality without performing a full deployment, run "puppet apply" on the
+fake_init.pp which will call only the opnfv::java class.
--- /dev/null
+##############################################################################
+# Copyright (c) 2015 Ericsson AB and others.
+# stefan.k.berg@ericsson.com
+# jonas.bjurel@ericsson.com
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Apache License, Version 2.0
+# which accompanies this distribution, and is available at
+# http://www.apache.org/licenses/LICENSE-2.0
+##############################################################################
+
+$fuel_settings = parseyaml($astute_settings_yaml)
+
+include opnfv::java
--- /dev/null
+##############################################################################
+# Copyright (c) 2015 Ericsson AB and others.
+# stefan.k.berg@ericsson.com
+# jonas.bjurel@ericsson.com
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Apache License, Version 2.0
+# which accompanies this distribution, and is available at
+# http://www.apache.org/licenses/LICENSE-2.0
+##############################################################################
+
+TOP := $(shell pwd)
+include ../config.mk
+
+PACKAGE := libpcsclite1
+VERSION := 1.8.10-1ubuntu1_amd64
+DEB_NAME := $(PACKAGE)_$(VERSION).deb
+
+.PHONY: all
+all: release/pool/main/$(DEB_NAME)
+
+release/pool/main/$(DEB_NAME):
+ifeq ($(LIBPCS_MAIN_REPO),)
+ @echo "No config-spec target for Java, nothing to build"
+else
+ @mkdir -p release/pool/main && \
+ cd release/pool/main && \
+ wget -N $(LIBPCS_MAIN_REPO)/$(DEB_NAME)
+ @lintian release/pool/main/$(DEB_NAME)
+endif
+
+.PHONY: clean
+clean:
+ @rm -rf release
+ @rm -f $(DEB_DEST)/$(DEB_NAME)
+
+
+.PHONY: release
+release:release/pool/main/$(DEB_NAME)
+ifneq ($(LIBPCS_MAIN_REPO),)
+ @cp release/pool/main/$(DEB_NAME) $(DEB_DEST)
+ @cp -Rvp puppet/modules/* $(PUPPET_DEST)
+endif
--- /dev/null
+class opnfv::libpcs {
+ if $::osfamily == 'Debian' {
+ case $::fuel_settings['role'] {
+ /controller/: {
+ package { 'libpcsclite1':
+ ensure => installed,
+ }
+ }
+ }
+ }
+}
--- /dev/null
+##############################################################################
+# Copyright (c) 2015 Ericsson AB and others.
+# stefan.k.berg@ericsson.com
+# jonas.bjurel@ericsson.com
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Apache License, Version 2.0
+# which accompanies this distribution, and is available at
+# http://www.apache.org/licenses/LICENSE-2.0
+##############################################################################
+
+TOP := $(shell pwd)
+include ../config.mk
+
+PACKAGE := libxtst6
+VERSION := 1.2.2-1_amd64
+DEB_NAME := $(PACKAGE)_$(VERSION).deb
+
+.PHONY: all
+all: release/pool/main/$(DEB_NAME)
+
+release/pool/main/$(DEB_NAME):
+ifeq ($(LIBXT_MAIN_REPO),)
+ @echo "No config-spec target for Java, nothing to build"
+else
+ @mkdir -p release/pool/main && \
+ cd release/pool/main && \
+ wget -N $(LIBXT_MAIN_REPO)/$(DEB_NAME)
+ @lintian release/pool/main/$(DEB_NAME)
+endif
+
+.PHONY: clean
+clean:
+ @rm -rf release
+ @rm -f $(DEB_DEST)/$(DEB_NAME)
+
+
+.PHONY: release
+release:release/pool/main/$(DEB_NAME)
+ifneq ($(LIBXT_MAIN_REPO),)
+ @cp release/pool/main/$(DEB_NAME) $(DEB_DEST)
+ @cp -Rvp puppet/modules/* $(PUPPET_DEST)
+endif
--- /dev/null
+class opnfv::libxt {
+ if $::osfamily == 'Debian' {
+ case $::fuel_settings['role'] {
+ /controller/: {
+ package { 'libxtst6':
+ ensure => installed,
+ }
+ }
+ }
+ }
+}
.PHONY: release
release:
- @cp -Rvp puppet/modules/* ../release/puppet/modules
+ @cp -Rvp puppet/modules/* $(PUPPET_DEST)
3. Upload the modifed deployment information: fuel --env 1 deployment --upload
After deploying, the additions will be included in /etc/astute.yaml of each host.
+
.PHONY: release
release:
- @cp -Rvp puppet/modules/* ../release/puppet/modules
+ @cp -Rvp puppet/modules/* $(PUPPET_DEST)
include opnfv::resolver
# Setup OPNFV style NTP config
include opnfv::ntp
- # Make sure all added packages are installed
+ # Make sure all added packages are installed
include opnfv::add_packages
+ # Setup OpenDaylight
+ include opnfv::odl
+ include opnfv::java
+ include opnfv::jre
+ include opnfv::jre_head
+ include opnfv::atk_wrap
+ include opnfv::gif
+ include opnfv::ca_cert
+ include opnfv::comm_java
+ include opnfv::libpcs
+ include opnfv::libxt
+ include opnfv::libnss
+ include opnfv::defjre
}
--- /dev/null
+##############################################################################
+# Copyright (c) 2015 Ericsson AB and others.
+# stefan.k.berg@ericsson.com
+# jonas.bjurel@ericsson.com
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Apache License, Version 2.0
+# which accompanies this distribution, and is available at
+# http://www.apache.org/licenses/LICENSE-2.0
+##############################################################################
+
+TOP := $(shell pwd)
+
+.PHONY: all
+all:
+
+.PHONY: clean
+clean:
+ @rm -rf tmp
+ @rm -rf release
+
+
+.PHONY: release
+release:
+ @cp -Rvp puppet/modules/* $(PUPPET_DEST)
--- /dev/null
+##############################################################################
+# Copyright (c) 2015 Ericsson AB and others.
+# stefan.k.berg@ericsson.com
+# jonas.bjurel@ericsson.com
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Apache License, Version 2.0
+# which accompanies this distribution, and is available at
+# http://www.apache.org/licenses/LICENSE-2.0
+##############################################################################
+
+TOP := $(shell pwd)
+
+.PHONY: all
+all:
+
+.PHONY: clean
+clean:
+ @rm -rf tmp
+ @rm -rf release
+
+
+.PHONY: release
+release:
+ @cp -Rvp puppet/modules/* $(PUPPET_DEST)
After deploying, the additions will be included in /etc/astute.yaml of each
host.
+
@@ -5,7 +5,7 @@
FROM fuel/centos
MAINTAINER Matthew Mosesohn mmosesohn@mirantis.com
-
+
-RUN rm -rf /etc/yum.repos.d/*; echo -e "[nailgun]\nname=Nailgun Local Repo\nbaseurl=http://$(route -n | awk '/^0.0.0.0/ { print $2 }'):_PORT_/os/x86_64/\ngpgcheck=0" > /etc/yum.repos.d/nailgun.repo; yum clean all; yum --quiet install -y ruby21-nailgun-mcagents sysstat
+RUN sleep 15; rm -rf /etc/yum.repos.d/*; echo -e "[nailgun]\nname=Nailgun Local Repo\nbaseurl=http://$(route -n | awk '/^0.0.0.0/ { print $2 }'):_PORT_/os/x86_64/\ngpgcheck=0" > /etc/yum.repos.d/nailgun.repo; yum clean all; yum --quiet install -y ruby21-nailgun-mcagents sysstat
-
+
ADD etc /etc
ADD start.sh /usr/local/bin/start.sh
diff --git a/docker/cobbler/Dockerfile b/docker/cobbler/Dockerfile
@@ -5,7 +5,7 @@
FROM fuel/centos
MAINTAINER Matthew Mosesohn mmosesohn@mirantis.com
-
+
-RUN rm -rf /etc/yum.repos.d/*;echo -e "[nailgun]\nname=Nailgun Local Repo\nbaseurl=http://$(route -n | awk '/^0.0.0.0/ { print $2 }'):_PORT_/os/x86_64/\ngpgcheck=0" > /etc/yum.repos.d/nailgun.repo; yum clean all; yum --quiet install -y httpd cobbler dnsmasq xinetd tftp-server; ln -s /etc/dnsmasq.conf /etc/cobbler.dnsmasq.conf
+RUN sleep 15; rm -rf /etc/yum.repos.d/*;echo -e "[nailgun]\nname=Nailgun Local Repo\nbaseurl=http://$(route -n | awk '/^0.0.0.0/ { print $2 }'):_PORT_/os/x86_64/\ngpgcheck=0" > /etc/yum.repos.d/nailgun.repo; yum clean all; yum --quiet install -y httpd cobbler dnsmasq xinetd tftp-server; ln -s /etc/dnsmasq.conf /etc/cobbler.dnsmasq.conf
-
+
ADD etc /etc
ADD start.sh /usr/local/bin/start.sh
diff --git a/docker/mcollective/Dockerfile b/docker/mcollective/Dockerfile
--- a/docker/mcollective/Dockerfile
+++ b/docker/mcollective/Dockerfile
@@ -4,7 +4,7 @@ MAINTAINER Aleksandr Didenko adidenko@mirantis.com
-
+
WORKDIR /root
-
+
-RUN rm -rf /etc/yum.repos.d/*; echo -e "[nailgun]\nname=Nailgun Local Repo\nbaseurl=http://$(route -n | awk '/^0.0.0.0/ { print $2 }'):_PORT_/os/x86_64/\ngpgcheck=0" > /etc/yum.repos.d/nailgun.repo; yum clean all; yum --quiet install -y sudo ruby21-mcollective
+RUN sleep 15; rm -rf /etc/yum.repos.d/*; echo -e "[nailgun]\nname=Nailgun Local Repo\nbaseurl=http://$(route -n | awk '/^0.0.0.0/ { print $2 }'):_PORT_/os/x86_64/\ngpgcheck=0" > /etc/yum.repos.d/nailgun.repo; yum clean all; yum --quiet install -y sudo ruby21-mcollective
-
+
ADD etc /etc
ADD start.sh /usr/local/bin/start.sh
diff --git a/docker/ostf/Dockerfile b/docker/ostf/Dockerfile
@@ -5,7 +5,7 @@
FROM fuel/centos
MAINTAINER Matthew Mosesohn mmosesohn@mirantis.com
-
+
-RUN rm -rf /etc/yum.repos.d/*;echo -e "[nailgun]\nname=Nailgun Local Repo\nbaseurl=http://$(route -n | awk '/^0.0.0.0/ { print $2 }'):_PORT_/os/x86_64/\ngpgcheck=0" > /etc/yum.repos.d/nailgun.repo;yum clean all; yum --quiet install -y python-fuelclient supervisor postgresql-libs
+RUN sleep 15; rm -rf /etc/yum.repos.d/*;echo -e "[nailgun]\nname=Nailgun Local Repo\nbaseurl=http://$(route -n | awk '/^0.0.0.0/ { print $2 }'):_PORT_/os/x86_64/\ngpgcheck=0" > /etc/yum.repos.d/nailgun.repo;yum clean all; yum --quiet install -y python-fuelclient supervisor postgresql-libs
-
+
ADD etc /etc
ADD start.sh /usr/local/bin/start.sh
diff --git a/docker/postgres/Dockerfile b/docker/postgres/Dockerfile
--- a/docker/postgres/Dockerfile
+++ b/docker/postgres/Dockerfile
@@ -3,7 +3,7 @@ FROM fuel/centos
-
+
MAINTAINER Aleksandr Didenko adidenko@mirantis.com
-
+
-RUN rm -rf /etc/yum.repos.d/*; echo -e "[nailgun]\nname=Nailgun Local Repo\nbaseurl=http://$(route -n | awk '/^0.0.0.0/ { print $2 }'):_PORT_/os/x86_64/\ngpgcheck=0" > /etc/yum.repos.d/nailgun.repo;yum clean all;yum --quiet install -y sudo
+RUN sleep 15; rm -rf /etc/yum.repos.d/*; echo -e "[nailgun]\nname=Nailgun Local Repo\nbaseurl=http://$(route -n | awk '/^0.0.0.0/ { print $2 }'):_PORT_/os/x86_64/\ngpgcheck=0" > /etc/yum.repos.d/nailgun.repo;yum clean all;yum --quiet install -y sudo
-
+
ADD etc /etc
ADD start.sh /usr/local/bin/start.sh
diff --git a/docker/rabbitmq/Dockerfile b/docker/rabbitmq/Dockerfile
@@ -3,7 +3,7 @@
FROM fuel/centos
MAINTAINER Aleksandr Didenko adidenko@mirantis.com
-
+
-RUN rm -rf /etc/yum.repos.d/*; echo -e "[nailgun]\nname=Nailgun Local Repo\nbaseurl=http://$(route -n | awk '/^0.0.0.0/ { print $2 }'):_PORT_/os/x86_64/\ngpgcheck=0" > /etc/yum.repos.d/nailgun.repo; yum clean all; yum --quiet install -y rabbitmq-server
+RUN sleep 15; rm -rf /etc/yum.repos.d/*; echo -e "[nailgun]\nname=Nailgun Local Repo\nbaseurl=http://$(route -n | awk '/^0.0.0.0/ { print $2 }'):_PORT_/os/x86_64/\ngpgcheck=0" > /etc/yum.repos.d/nailgun.repo; yum clean all; yum --quiet install -y rabbitmq-server
-
+
ADD etc /etc
ADD start.sh /usr/local/bin/start.sh
diff --git a/docker/rsync/Dockerfile b/docker/rsync/Dockerfile
@@ -5,7 +5,7 @@
FROM fuel/centos
MAINTAINER Matthew Mosesohn mmosesohn@mirantis.com
-
+
-RUN rm -rf /etc/yum.repos.d/*; echo -e "[nailgun]\nname=Nailgun Local Repo\nbaseurl=http://$(route -n | awk '/^0.0.0.0/ { print $2 }'):_PORT_/os/x86_64/\ngpgcheck=0" > /etc/yum.repos.d/nailgun.repo;yum clean all;yum --quiet install -y ruby21-puppet xinetd rsync logrotate
+RUN sleep 15; rm -rf /etc/yum.repos.d/*; echo -e "[nailgun]\nname=Nailgun Local Repo\nbaseurl=http://$(route -n | awk '/^0.0.0.0/ { print $2 }'):_PORT_/os/x86_64/\ngpgcheck=0" > /etc/yum.repos.d/nailgun.repo;yum clean all;yum --quiet install -y ruby21-puppet xinetd rsync logrotate
-
+
ADD etc /etc
ADD start.sh /usr/local/bin/start.sh
diff --git a/docker/rsyslog/Dockerfile b/docker/rsyslog/Dockerfile
--- a/docker/rsyslog/Dockerfile
+++ b/docker/rsyslog/Dockerfile
@@ -2,7 +2,7 @@ FROM fuel/centos
-
+
MAINTAINER Aleksandr Didenko adidenko@mirantis.com
-
+
-RUN rm -rf /etc/yum.repos.d/*; echo -e "[nailgun]\nname=Nailgun Local Repo\nbaseurl=http://$(route -n | awk '/^0.0.0.0/ { print $2 }'):_PORT_/os/x86_64/\ngpgcheck=0" > /etc/yum.repos.d/nailgun.repo; yum clean all;yum --quiet install -y anacron rsyslog
+RUN sleep 15; rm -rf /etc/yum.repos.d/*; echo -e "[nailgun]\nname=Nailgun Local Repo\nbaseurl=http://$(route -n | awk '/^0.0.0.0/ { print $2 }'):_PORT_/os/x86_64/\ngpgcheck=0" > /etc/yum.repos.d/nailgun.repo; yum clean all;yum --quiet install -y anacron rsyslog
-
+
ADD etc /etc
ADD start.sh /usr/local/bin/start.sh
+ rm $(SANDBOX_UBUNTU)/sbin/start.orig)
echo "SANDBOX_UBUNTU_UP: done"
endef
+
--- /dev/null
+##############################################################################
+# Copyright (c) 2015 Ericsson AB and others.
+# stefan.k.berg@ericsson.com
+# jonas.bjurel@ericsson.com
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Apache License, Version 2.0
+# which accompanies this distribution, and is available at
+# http://www.apache.org/licenses/LICENSE-2.0
+##############################################################################
+
+############################################################################
+# BEGIN of variables to customize
+#
+SHELL = /bin/bash
+include ../config.mk
+
+BUILD_DIR := $(shell pwd)
+GIT_DIR := /tmp
+export CONFIG_SPEC_SCRIPT
+export MAVEN_OPTS = -Xmx1024m -XX:MaxPermSize=512m
+MAINTAINER = "Main Tainer <main.tainer@example.org>"
+ODL_SHORT_NAME = odl
+ODL_VERSION = 0.1-1
+DEPEND = openjdk-8-jdk
+TARGET_BUILD_PATH="/tmp/controller/opendaylight/distribution/opendaylight-karaf/target/"
+MAVEN_SPEC = $(BUILD_DIR)/odl_maven/settings.xml
+
+#
+# END of variables to customize
+#############################################################################
+
+.PHONY: all
+all: odl
+
+.PHONY: setup
+setup:
+ @if [ ! -d "$(TOPDIR)/f_odl" ]; then ln -s "$(realpath $(BUILD_DIR))/f_odl" "$(realpath $(TOPDIR))/f_odl"; fi
+
+.PHONY: odl
+odl:
+ifeq ($(ODL_MAIN_REPO),)
+ @echo "No config-spec target for ODL, nothing to build"
+else
+
+ifeq ($(shell if [ -e .odl-build.log ];then cat .odl-build.log; fi;),$(ODL_MAIN_TAG))
+ @cd /tmp && git clone $(ODL_MAIN_REPO) && cd /tmp/controller && git checkout $(ODL_MAIN_TAG)
+ @echo "ODL is up to date"
+else
+ @if [ ! -d "/tmp/controller" ]; then cd /tmp && git clone $(ODL_MAIN_REPO); fi;
+ @cd /tmp/controller && git checkout $(ODL_MAIN_TAG) && mvn -Dmaven.test.skip=true -gs $(MAVEN_SPEC) clean install;
+ @./make-odl-deb.sh -N $(ODL_SHORT_NAME)_`cd /tmp/controller; git rev-parse --short HEAD` -n $(ODL_SHORT_NAME) -v "$(ODL_VERSION)" -t "$(ODL_MAIN_TAG)" -m $(MAINTAINER) -d $(DEPEND) -p $(TARGET_BUILD_PATH)
+ @echo $(ODL_MAIN_TAG) > .odl-build.log
+endif
+endif
+
+.PHONY: clean $(SUBCLEAN)
+clean: $(SUBCLEAN)
+ @rm -Rf /tmp/controller
+ @rm -f .odl-build.log
+ @./make-odl-deb.sh -C
+
+.PHONY: release
+release:
--- /dev/null
+##############################################################################
+# Copyright (c) 2015 Ericsson AB and others.
+# stefan.k.berg@ericsson.com
+# jonas.bjurel@ericsson.com
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Apache License, Version 2.0
+# which accompanies this distribution, and is available at
+# http://www.apache.org/licenses/LICENSE-2.0
+##############################################################################
+
+This directory builds the OpenDaylight debian package by cloning the
+opendaylight.org repo, building the odl tag specified in
+"fuel-build/config-spec" and constructing a debian package source tree under
+"f_odl", which automatically is linked into "fuel_build/." for further build processing.
+
+The opendaylight has the following structure:
+.
++--------+-------------+-----------+
+| | | |
+| Makefile make-odl-deb.sh README
+| (this file)
+|
++----------+----------+
+ | |
+ odl_maven/ f_odl/
+
+Makefile:
+Invoked by the git root Makefile, it builds the clones the odl repo from
+odl, checkout the tag/branch indicated in "fuelbuild/config-spec", builds
+odl, and calls "make-odl-deb.sh" to create a debian package source tree.
+
+make-odl-deb.sh:
+Creates the odl debian package source tree in "f_odl" from the odl build
+results.
+
+odl_maven/:
+Contains needed control files for maven OpenDaylight build
+
+f_odl/:
+Contains buildscripts and the generated odl debian package source tree produced
+by the odl build (make-odl-deb.sh) which is later used by the root build system.
+
+NOTE on the controller/ git repo clone:
+The git controller repo clone Contains all artifacts from the odl build, it only
+exists in /tmp inside the build docker container and is not visible anywhere on
+the build host
+
+Note on build caching:
+The latest build results are cached, and will not be rebuilt unless the fuel-build/
+config-spec is changed in respect to odl version or if make clean is applied.
+./.odl-build.log and ./.odl-build.history are used to keep adequate bookmaking to
+track caching and needed cleanout.
--- /dev/null
+##############################################################################
+# Copyright (c) 2015 Ericsson AB and others.
+# stefan.k.berg@ericsson.com
+# jonas.bjurel@ericsson.com
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Apache License, Version 2.0
+# which accompanies this distribution, and is available at
+# http://www.apache.org/licenses/LICENSE-2.0
+##############################################################################
+
+include $(BUILD_BASE)/config.mk
+ODL_NAME_SHORT := odl
+PACKAGE := odl_$(shell cd /tmp/controller; git rev-parse --short HEAD)
+VERSION := 0.1-1
+DEB_NAME := $(PACKAGE)_$(VERSION)
+
+.PHONY: all
+all: release/pool/main/$(DEB_NAME).deb
+
+release/pool/main/$(DEB_NAME).deb:
+ifeq ($(ODL_MAIN_REPO),)
+ @echo "No config-spec target for ODL, nothing to build"
+else
+ @mkdir -p tmp/src
+ @mkdir -p release/pool/main
+ @cp -rp $(DEB_NAME) tmp/src
+ @gzip -f9 tmp/src/$(DEB_NAME)/usr/share/doc/$(ODL_NAME_SHORT)/changelog.Debian
+ @fakeroot dpkg-deb --build tmp/src/$(DEB_NAME)
+ @lintian tmp/src/$(DEB_NAME).deb
+ @cp tmp/src/$(DEB_NAME).deb release/pool/main
+endif
+
+.PHONY: clean
+clean:
+ @rm -rf tmp
+ @rm -rf release
+ @rm -f $(DEB_DEST)/$(DEB_NAME).deb
+
+
+.PHONY: release
+release:release/pool/main/$(DEB_NAME).deb
+ifneq ($(ODL_MAIN_REPO),)
+ @cp release/pool/main/$(DEB_NAME).deb $(DEB_DEST)
+ @cp -Rvp puppet/modules/* $(PUPPET_DEST)
+endif
--- /dev/null
+##############################################################################
+# Copyright (c) 2015 Ericsson AB and others.
+# stefan.k.berg@ericsson.com
+# jonas.bjurel@ericsson.com
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Apache License, Version 2.0
+# which accompanies this distribution, and is available at
+# http://www.apache.org/licenses/LICENSE-2.0
+##############################################################################
+
+This directory adds the OpenDaylight (odl) package and related puppet
+deployment manifest such that it gets built into the .iso image an deployed
+on the stack controller cluster.
+
+The f_odl has the following structure:
+.
++--------+----------+-----------+------------+
+ | | | |
+ puppet/ Makefile README odl_<change_id>
+ | (this file) /<version>
+ | |
+ | odl deb pkg src
+ modules/
+ |
+ |
+ |
+ opnfv/
+ |
+ |
+ |
+ manifests/
+ |
+ |
+ |
+ odl.pp
+
+Makefile:
+Invoked by the git root Makefile, it builds the odl debian package from the
+debian pkg source directory (inside this directory) and pushes it together
+with the manifests to the fuel build source artifact directory, such that it
+eventually gets built into the new fuel .iso
+
+odl.pp:
+Controls the installation and configuration of odl
+
+odl deb pkg src:
+Is the debian package source directory tree including all needed odl artifacts
+and debian pakage meta data. This debian source package tree is built from
+fuel-build/opendaylight and doesnt exist before it has bee built.
--- /dev/null
+class opnfv::odl {
+ if $::osfamily == 'Debian' {
+
+
+ case $::fuel_settings['role'] {
+ /controller/: {
+ package { 'odl':
+ ensure => installed,
+ }
+ }
+ }
+ }
+}
--- /dev/null
+##############################################################################
+# Copyright (c) 2015 Ericsson AB and others.
+# stefan.k.berg@ericsson.com
+# jonas.bjurel@ericsson.com
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Apache License, Version 2.0
+# which accompanies this distribution, and is available at
+# http://www.apache.org/licenses/LICENSE-2.0
+##############################################################################
+
+In order to test the functionality without performing a full deployment, run "puppet apply" on the
+fake_init.pp which will call only the opnfv::odl class.
--- /dev/null
+##############################################################################
+# Copyright (c) 2015 Ericsson AB and others.
+# stefan.k.berg@ericsson.com
+# jonas.bjurel@ericsson.com
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Apache License, Version 2.0
+# which accompanies this distribution, and is available at
+# http://www.apache.org/licenses/LICENSE-2.0
+##############################################################################
+
+$fuel_settings = parseyaml($astute_settings_yaml)
+
+include opnfv::odl
--- /dev/null
+#!/bin/bash
+set -e
+##############################################################################
+# Copyright (c) 2015 Ericsson AB and others.
+# stefan.k.berg@ericsson.com
+# jonas.bjurel@ericsson.com
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Apache License, Version 2.0
+# which accompanies this distribution, and is available at
+# http://www.apache.org/licenses/LICENSE-2.0
+##############################################################################
+
+##############################################################################
+# Default variable declarations
+
+COMMAND=
+PACKAGE_NAME=
+PACKAGE_SHORT_NAME=
+PACKAGE_VERSION=
+TARGET_BUILD_PATH=
+DEPENDENCIES=
+MAINTAINER=
+ARCH="amd64"
+BUILD_HISTORY=".odl-build-history"
+
+##############################################################################
+# subroutine: usage
+# Description: Prints out usage of this script
+
+usage ()
+{
+cat <<EOF
+usage: $0 options
+
+$0 creates a ${PACKAGE_NAME} Debian package
+
+OPTIONS:
+ -n Package shoer name
+ -N Package name
+ -v Version
+ -t Tag
+ -p Target build path, the path where the built tar ball is to be fetched
+ -m Maintainer
+ -d Package dependencies
+ -h Prints this message
+ -C Clean
+
+E.g.: $0 -n my/deb/src/dest/path -N my-package -v 1.0-1 -t myTag -p path/to/the/source -m "Main Tainer <main.tainer.exampe.org> -d myJavaDependence
+EOF
+}
+
+##############################################################################
+# subroutine: clean
+# Description: Cleans up all artifacts from earlier builds
+
+clean ()
+{
+if [ -e $BUILD_HISTORY ]; then
+ while read line
+ do
+ rm -rf $line
+ done < $BUILD_HISTORY
+ rm ${BUILD_HISTORY}
+ exit 0
+fi
+}
+
+##############################################################################
+# make-DEBIAN_control
+# Description: constructs the Debian pack control file
+
+make-DEBIAN_control ()
+{
+cat <<EOF
+Package: $PACKAGE_SHORT_NAME
+Version: $PACKAGE_VERSION
+Section: base
+Priority: optional
+Architecture: $ARCH
+Depends: $DEPENDENCIES
+Maintainer: $MAINTAINER
+Description: OpenDaylight deamon
+ This is a daemon for the opendaylight/odl controller service.
+EOF
+}
+
+##############################################################################
+# subroutine: make-DEBIAN_conffiles
+# Description: Constructs the Debian package config files assignment
+
+make-DEBIAN_conffiles ()
+{
+cat <<EOF
+/etc/odl/etc/all.policy
+/etc/odl/etc/config.properties
+/etc/odl/etc/custom.properties
+/etc/odl/etc/distribution.info
+/etc/odl/etc/equinox-debug.properties
+/etc/odl/etc/java.util.logging.properties
+/etc/odl/etc/jmx.acl.cfg
+/etc/odl/etc/jmx.acl.java.lang.Memory.cfg
+/etc/odl/etc/jmx.acl.org.apache.karaf.bundle.cfg
+/etc/odl/etc/jmx.acl.org.apache.karaf.config.cfg
+/etc/odl/etc/jmx.acl.org.apache.karaf.security.jmx.cfg
+/etc/odl/etc/jmx.acl.osgi.compendium.cm.cfg
+/etc/odl/etc/jre.properties
+/etc/odl/etc/keys.properties
+/etc/odl/etc/org.apache.felix.fileinstall-deploy.cfg
+/etc/odl/etc/org.apache.karaf.command.acl.bundle.cfg
+/etc/odl/etc/org.apache.karaf.command.acl.config.cfg
+/etc/odl/etc/org.apache.karaf.command.acl.feature.cfg
+/etc/odl/etc/org.apache.karaf.command.acl.jaas.cfg
+/etc/odl/etc/org.apache.karaf.command.acl.kar.cfg
+/etc/odl/etc/org.apache.karaf.command.acl.shell.cfg
+/etc/odl/etc/org.apache.karaf.command.acl.system.cfg
+/etc/odl/etc/org.apache.karaf.features.cfg
+/etc/odl/etc/org.apache.karaf.features.obr.cfg
+/etc/odl/etc/org.apache.karaf.features.repos.cfg
+/etc/odl/etc/org.apache.karaf.jaas.cfg
+/etc/odl/etc/org.apache.karaf.kar.cfg
+/etc/odl/etc/org.apache.karaf.log.cfg
+/etc/odl/etc/org.apache.karaf.management.cfg
+/etc/odl/etc/org.apache.karaf.shell.cfg
+/etc/odl/etc/org.ops4j.pax.logging.cfg
+/etc/odl/etc/org.ops4j.pax.url.mvn.cfg
+/etc/odl/etc/regions-config.xml
+/etc/odl/etc/shell.init.script
+/etc/odl/etc/startup.properties
+/etc/odl/etc/system.properties
+/etc/odl/etc/users.properties
+/etc/odl/configuration/context.xml
+/etc/odl/configuration/logback.xml
+/etc/odl/configuration/tomcat-logging.properties
+/etc/odl/configuration/tomcat-server.xml
+EOF
+}
+
+##############################################################################
+# subroutine: make-DEBIAN_postinst
+# Description: Constructs the Debian package post installation script
+
+make-DEBIAN_postinst ()
+{
+cat <<EOF
+#!/bin/bash -e
+ln -s /etc/${PACKAGE_SHORT_NAME}/* ${TARGET_INSTALL_PATH}
+echo "OpenDaylight $TAG version $PACKAGE_VERSION has been installed"
+EOF
+}
+
+##############################################################################
+# subroutine: make-DEBIAN_bin
+# Description: Constructs the bin script (normally under /usr/bin)
+
+make-DEBIAN_bin ()
+{
+cat <<EOF
+#!/bin/bash -e
+${TARGET_INSTALL_PATH}bin/karaf $@
+EOF
+}
+
+##############################################################################
+# subroutine: make-DEBIAN_copyright
+# Description: Constructs the copyright text (normally under /usr/share/doc...)
+
+make-DEBIAN_copyright ()
+{
+cat <<EOF
+OpenDaylight - an open source SDN controller
+Licensed to the Apache Software Foundation (ASF) under one or more
+contributor license agreements. See the NOTICE file distributed with
+this work for additional information regarding copyright ownership.
+The ASF licenses this file to You under the Apache License, Version 2.0
+(the "License"); you may not use this file except in compliance with
+the License. You may obtain a copy of the License at
+
+http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing, software
+distributed under the License is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+See the License for the specific language governing permissions and
+limitations under the License.
+EOF
+}
+
+##############################################################################
+# subroutine: make-DEBIAN_changelog
+# Description: Constructs the changelog text (normally under /usr/share/doc...)
+
+make-DEBIAN_changelog ()
+{
+cat <<EOF
+$PACKAGE_SHORT_NAME ($PACKAGE_VERSION) precise-proposed; urgency=low
+
+ * Derived from $PACKAGE_NAME $PACHAGE_VERSION
+
+ -- $MAINTAINER $(date)
+EOF
+}
+
+##############################################################################
+# MAIN
+
+while getopts "N:n:v:d:Chm:t:p:" OPTION
+do
+ case $OPTION in
+ h)
+ usage
+ exit 0
+ ;;
+
+ N)
+ PACKAGE_NAME=$OPTARG
+ COMMAND+="-N ${PACKAGE_NAME} "
+ ;;
+
+ n)
+ PACKAGE_SHORT_NAME=$OPTARG
+ COMMAND+="-n ${PACKAGE_SHORT_NAME} "
+ ;;
+
+ v)
+ PACKAGE_VERSION=$OPTARG
+ COMMAND+="-v ${PACKAGE_VERSION} "
+ ;;
+
+ p)
+ TARGET_BUILD_PATH=$OPTARG
+ COMMAND+="-p ${TARGET_BUILD_PATH} "
+ ;;
+
+ t)
+ TAG=$OPTARG
+ COMMAND+="-t ${TAG} "
+ ;;
+
+ m)
+ MAINTAINER=$OPTARG
+ COMMAND+="-m ${MAINTAINER} "
+ ;;
+
+ d)
+ DEPENDENCIES=$OPTARG
+ COMMAND+="-d ${DEPENDENCIES} "
+ ;;
+
+ A)
+ ARCH=$OPTARG
+ COMMAND+="-A ${ARCH} "
+ ;;
+
+ C)
+ COMMAND+="-C "
+ clean
+ exit 0
+ ;;
+ esac
+done
+
+# Constructing script variables
+DEB_PACK_BASE_PATH="f_${PACKAGE_SHORT_NAME}/${PACKAGE_NAME}_${PACKAGE_VERSION}/"
+echo ${DEB_PACK_BASE_PATH} >> "$BUILD_HISTORY"
+TARGET_INSTALL_PATH="/usr/share/java/${PACKAGE_SHORT_NAME}/"
+DEB_PACK_CONTENT_PATH="${DEB_PACK_BASE_PATH}usr/share/java/${PACKAGE_SHORT_NAME}/"
+DEB_PACK_CONFIG_PATH="${DEB_PACK_BASE_PATH}etc/${PACKAGE_SHORT_NAME}"
+TARGET_TAR=$(ls ${TARGET_BUILD_PATH}*.tar.gz)
+TARGET_TAR="${TARGET_TAR##*/}"
+TAR_PATH="${TARGET_TAR%.*}"
+TAR_PATH="${TAR_PATH%.*}"
+if [ -e $DEB_PACK_BASE_PATH ]; then
+ rm -R $DEB_PACK_BASE_PATH
+fi
+
+# Create Deb pack content and configuration
+mkdir -p ${DEB_PACK_CONTENT_PATH}
+cp ${TARGET_BUILD_PATH}${TARGET_TAR} ${DEB_PACK_CONTENT_PATH}
+tar -xzf ${DEB_PACK_CONTENT_PATH}${TARGET_TAR} -C ${DEB_PACK_CONTENT_PATH}
+rm ${DEB_PACK_CONTENT_PATH}${TARGET_TAR}
+mv ${DEB_PACK_CONTENT_PATH}${TAR_PATH}/* ${DEB_PACK_CONTENT_PATH}.
+rm -R ${DEB_PACK_CONTENT_PATH}${TAR_PATH}
+
+# Crate and populate Deb pack config target
+mkdir -p ${DEB_PACK_CONFIG_PATH}/etc
+mv ${DEB_PACK_CONTENT_PATH}etc/* ${DEB_PACK_CONFIG_PATH}/etc/
+rm -R ${DEB_PACK_CONTENT_PATH}etc
+mkdir -p ${DEB_PACK_CONFIG_PATH}/configuration
+mv ${DEB_PACK_CONTENT_PATH}configuration/* ${DEB_PACK_CONFIG_PATH}/configuration/
+rm -R ${DEB_PACK_CONTENT_PATH}configuration
+
+# Set package permisions
+find ${DEB_PACK_CONTENT_PATH} -type d -print -exec chmod 755 {} \;
+find ${DEB_PACK_CONFIG_PATH}/etc/ -type f -print -exec chmod 644 {} \;
+find ${DEB_PACK_CONFIG_PATH}/etc/ -type d -print -exec chmod 755 {} \;
+
+# Create package usr/bin odl script
+mkdir "${DEB_PACK_BASE_PATH}usr/bin"
+chmod 755 "${DEB_PACK_BASE_PATH}usr/bin"
+make-DEBIAN_bin > "${DEB_PACK_BASE_PATH}usr/bin/odl"
+chmod 755 "${DEB_PACK_BASE_PATH}usr/bin/odl"
+
+# Create Deb pack install meta-data
+mkdir "${DEB_PACK_BASE_PATH}DEBIAN"
+make-DEBIAN_control > "${DEB_PACK_BASE_PATH}DEBIAN/control"
+make-DEBIAN_conffiles > "${DEB_PACK_BASE_PATH}DEBIAN/conffiles"
+mkdir -p "${DEB_PACK_BASE_PATH}usr/share/doc/${PACKAGE_SHORT_NAME}"
+make-DEBIAN_copyright > "${DEB_PACK_BASE_PATH}usr/share/doc/${PACKAGE_SHORT_NAME}/copyright"
+make-DEBIAN_changelog > "${DEB_PACK_BASE_PATH}usr/share/doc/${PACKAGE_SHORT_NAME}/changelog.Debian"
+
+# Create Deb pack post install symlinks and usr/bin scripts
+make-DEBIAN_postinst > "${DEB_PACK_BASE_PATH}DEBIAN/postinst"
+chmod 755 "${DEB_PACK_BASE_PATH}DEBIAN/postinst"
+mkdir -p "${DEB_PACK_BASE_PATH}usr/bin"
--- /dev/null
+<settings xmlns="http://maven.apache.org/SETTINGS/1.0.0"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://maven.apache.org/SETTINGS/1.0.0 http://maven.apache.org/xsd/settings-1.0.0.xsd">
+
+ <profiles>
+ <profile>
+ <id>opendaylight-release</id>
+ <repositories>
+ <repository>
+ <releases>
+ <enabled>true</enabled>
+ <updatePolicy>never</updatePolicy>
+ </releases>
+ <snapshots>
+ <enabled>false</enabled>
+ </snapshots>
+ <id>opendaylight-mirror</id>
+ <name>opendaylight-mirror</name>
+ <url>http://nexus.opendaylight.org/content/groups/public/</url>
+ </repository>
+ </repositories>
+ </profile>
+
+ <profile>
+ <id>opendaylight-snapshots</id>
+ <repositories>
+ <repository>
+ <releases>
+ <enabled>false</enabled>
+ </releases>
+ <snapshots>
+ <enabled>true</enabled>
+ </snapshots>
+ <id>opendaylight-snapshot</id>
+ <name>opendaylight-snapshot</name>
+ <url>http://nexus.opendaylight.org/content/repositories/opendaylight.snapshot/</url>
+ </repository>
+ </repositories>
+ </profile>
+ </profiles>
+
+ <activeProfiles>
+ <activeProfile>opendaylight-release</activeProfile>
+ <activeProfile>opendaylight-snapshots</activeProfile>
+ </activeProfiles>
+</settings>
.PHONY: $(SUBDIRS) $(SUBCLEAN) clean
$(SUBDIRS):
@mkdir -p release/packages
- ORIGISO=$(ORIGISO) VERSION=$(VERSION) $(MAKE) -C $@ -f Makefile release
+ ORIGISO=$(ORIGISO) REVSTATE=$(REVSTATE) $(MAKE) -C $@ -f Makefile release
release: $(SUBDIRS)
@echo $(ORIGISO)
release:
../tools/deb_unpack python-nova_*.deb $(ORIGISO)
patch -s -p0 < nova-console.patch
- ../tools/deb_pack $(VERSION)
+ ../tools/deb_pack $(REVSTATE)
@cp *.deb ../release/packages
@cat patch-replacements >> ../release/patch-replacements
! consolelog.type = "file"
! consolelog.source_path = self._get_console_log_path(instance)
! guest.add_device(consolelog)
-
+
consolepty = vconfig.LibvirtConfigGuestSerial()
else:
--- 3959,3971 ----
! # guest.add_device(consolelog)
! pass
! # Disabled by OPNFV END
-
+
consolepty = vconfig.LibvirtConfigGuestSerial()
else:
../tools/deb_unpack python-oslo.messaging_1.3.0-fuel5.1~mira4_all.deb $(ORIGISO)
@mkdir -p package/etc
@echo "Hello, world" > package/etc/hello.txt
- ../tools/deb_pack $(VERSION)
+ ../tools/deb_pack $(REVSTATE)
@cp *.deb ../release/packages
@cat patch-replacements >> ../release/patch-replacements