summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--common/puppet-opnfv/manifests/compute.pp148
-rw-r--r--common/puppet-opnfv/manifests/controller_networker.pp471
-rw-r--r--common/puppet-opnfv/manifests/odl_service.pp24
-rw-r--r--common/puppet-opnfv/manifests/repo.pp18
-rw-r--r--common/puppet-opnfv/manifests/templates/dockerfile/Dockerfile2
-rw-r--r--foreman/build/Makefile111
-rw-r--r--foreman/build/c7-opnfv-x86_64-comps.xml277
-rw-r--r--foreman/build/cache.mk78
-rw-r--r--foreman/build/config.mk0
-rw-r--r--foreman/build/isolinux.cfg120
-rwxr-xr-x[-rw-r--r--]foreman/ci/build.sh398
-rw-r--r--foreman/include/build.sh.debug1
-rw-r--r--fuel/build/Makefile1
-rw-r--r--fuel/build/f_odl_docker/puppet/modules/opnfv/manifests/odl_docker.pp14
-rwxr-xr-xfuel/build/f_odl_docker/puppet/modules/opnfv/scripts/start_odl_container.sh15
-rwxr-xr-xfuel/build/f_odl_docker/scripts/start_odl_container.sh88
16 files changed, 1501 insertions, 265 deletions
diff --git a/common/puppet-opnfv/manifests/compute.pp b/common/puppet-opnfv/manifests/compute.pp
index fdef9c7..7bba609 100644
--- a/common/puppet-opnfv/manifests/compute.pp
+++ b/common/puppet-opnfv/manifests/compute.pp
@@ -11,68 +11,128 @@
# 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.
+#
+#Provides a manifest to configure OpenStack compute node in HA or non-HA
+#environment, with Ceph configured as Cinder backend storage.
+#ha_flag set to true will use virtual IP addresses (VIPs provided by
+#global params) as the provider to the compute node for HA
class opnfv::compute {
- if ($odl_flag != '') and str2bool($odl_flag) {
+ if ($odl_flag != '') and str2bool($odl_flag) {
$ml2_mech_drivers = ['opendaylight']
$this_agent = 'opendaylight'
}
else {
- $ml2_mech_drivers = ['openvswitch','l2population']
+ $ml2_mech_drivers = ['openvswitch','l2population']
$this_agent = 'ovs'
}
+ ##Common Parameters
if $ovs_tunnel_if == '' { fail('ovs_tunnel_if is empty') }
- if $private_ip == '' { fail('private_ip is empty') }
- if $odl_control_ip == '' { $odl_control_ip = $private_ip }
-
- if $mysql_ip == '' { fail('mysql_ip is empty') }
- if $amqp_ip == '' { fail('mysql_ip is empty') }
-
- if $admin_password == '' { fail('admin_password is empty') }
-
- if $nova_user_password == '' { fail('nova_user_password is empty') }
- if $nova_db_password == '' { fail('nova_db_password is empty') }
-
- if $neutron_user_password == '' { fail('nova_user_password is empty') }
- if $neutron_db_password == '' { fail('nova_db_password is empty') }
- if $ceilometer_user_password == '' { fail('ceilometer_user_password is empty') }
- if $ceilometer_metering_secret == '' { fail('ceilometer_user_password is empty') }
+ if !$rbd_secret_uuid { $rbd_secret_uuid = '3b519746-4021-4f72-957e-5b9d991723be' }
+ if !$private_subnet { fail('private_subnet is empty')}
+ if !$ceph_public_network { $ceph_public_network = $private_subnet }
+ if !$ceph_fsid { $ceph_fsid = '904c8491-5c16-4dae-9cc3-6ce633a7f4cc' }
+ if !$ceph_images_key { $ceph_images_key = 'AQAfHBdUKLnUFxAAtO7WPKQZ8QfEoGqH0CLd7A==' }
+ if !$ceph_osd_journal_size { $ceph_osd_journal_size = '1000' }
+ if !$ceph_osd_pool_size { $ceph_osd_pool_size = '1' }
+ if !$ceph_volumes_key { $ceph_volumes_key = 'AQAfHBdUsFPTHhAAfqVqPq31FFCvyyO7oaOQXw==' }
+
+
+ ##Most users will only care about a single user/password for all services
+ ##so lets create one variable that can be used instead of separate usernames/passwords
+ if !$single_username { $single_username = 'octopus' }
+ if !$single_password { $single_password = 'octopus' }
+
+ if !$admin_password { $admin_password = $single_password }
+ if !$neutron_db_password { $neutron_db_password = $single_password }
+ if !$neutron_user_password { $neutron_user_password = $single_password }
+
+ if !$ceilometer_user_password { $ceilometer_user_password = $single_password }
+ if !$ceilometer_metering_secret { $ceilometer_metering_secret = $single_password }
+
+ ##HA Global params
+ if $ha_flag {
+ if !$keystone_private_vip { fail('keystone_private_vip is empty') }
+ if !$glance_private_vip { fail('glance_private_vip is empty') }
+ if !$nova_private_vip { fail('nova_private_vip is empty') }
+ if !$nova_db_password { $nova_db_password = $single_password }
+ if !$nova_user_password { $nova_user_password = $single_password }
+ if !$controllers_ip_array { fail('controllers_ip_array is empty') }
+ if !$controllers_hostnames_array { fail('controllers_hostnames_array is empty') }
+ $controllers_ip_array = split($controllers_ip_array, ',')
+ $controllers_hostnames_array = split($controllers_hostnames_array, ',')
+ if !$odl_control_ip { $odl_control_ip = $controllers_ip_array[0] }
+ if !$db_vip { fail('db_vip is empty') }
+ $mysql_ip = $db_vip
+ if !$amqp_vip { fail('amqp_vip is empty') }
+ $amqp_ip = $amqp_vip
+ if !$amqp_username { $amqp_username = $single_username }
+ if !$amqp_password { $amqp_password = $single_password }
+ if !$ceph_mon_initial_members { $ceph_mon_initial_members = $controllers_hostnames_array }
+ if !$ceph_mon_host { $ceph_mon_host = $controllers_ip_array }
+ if !$neutron_private_vip { fail('neutron_private_vip is empty') }
+ } else {
+ ##non HA params
+ if !$private_ip { fail('private_ip is empty') }
+ $keystone_private_vip = $private_ip
+ $glance_private_vip = $private_ip
+ $nova_private_vip = $private_ip
+ $neutron_private_vip = $private_ip
+ if !$nova_db_password { fail('nova_db_password is empty') }
+ if !$nova_user_password { fail('nova_user_password is empty') }
+ if !$odl_control_ip { $odl_control_ip = $private_ip }
+ if !$mysql_ip { $mysql_ip = $private_ip }
+ if !$amqp_ip { $amqp_ip = $private_ip }
+ if !$amqp_username { $amqp_username = 'guest' }
+ if !$amqp_password { $amqp_password = 'guest' }
+ if !$ceph_mon_host { $ceph_mon_host= ["$private_ip"] }
+ if !$ceph_mon_initial_members { $ceph_mon_initial_members = ["$::hostname"] }
+ }
class { "quickstack::neutron::compute":
- auth_host => $private_ip,
- glance_host => $private_ip,
+ auth_host => $keystone_private_vip,
+ glance_host => $glance_private_vip,
libvirt_images_rbd_pool => 'volumes',
libvirt_images_rbd_ceph_conf => '/etc/ceph/ceph.conf',
libvirt_inject_password => 'false',
libvirt_inject_key => 'false',
libvirt_images_type => 'rbd',
- nova_host => $private_ip,
- nova_db_password => $nova_db_password,
- nova_user_password => $nova_user_password,
+ nova_host => $nova_private_vip,
+ nova_db_password => $nova_db_password,
+ nova_user_password => $nova_user_password,
private_network => '',
- private_iface => '',
+ private_iface => $ovs_tunnel_if,
private_ip => '',
rbd_user => 'volumes',
- rbd_secret_uuid => '',
+ rbd_secret_uuid => $rbd_secret_uuid,
network_device_mtu => $quickstack::params::network_device_mtu,
- admin_password => $admin_password,
- ssl => false,
-
- mysql_host => $mysql_ip,
- mysql_ca => $quickstack::params::mysql_ca,
- amqp_host => $amqp_ip,
- amqp_username => 'guest',
- amqp_password => 'guest',
- #amqp_nssdb_password => $quickstack::params::amqp_nssdb_password,
-
- ceilometer => 'true',
- ceilometer_metering_secret => $ceilometer_metering_secret,
- ceilometer_user_password => $ceilometer_user_password,
-
- cinder_backend_gluster => $quickstack::params::cinder_backend_gluster,
+ admin_password => $admin_password,
+ ssl => false,
+
+ mysql_host => $mysql_ip,
+ mysql_ca => '/etc/ipa/ca.crt',
+ amqp_host => $amqp_ip,
+ amqp_username => $amqp_username,
+ amqp_password => $amqp_password,
+
+ ceilometer => 'false',
+ ceilometer_metering_secret => $ceilometer_metering_secret,
+ ceilometer_user_password => $ceilometer_user_password,
+
+ cinder_backend_gluster => $quickstack::params::cinder_backend_gluster,
+ cinder_backend_rbd => 'true',
+ glance_backend_rbd => 'true',
+ ceph_cluster_network => $ceph_public_network,
+ ceph_fsid => $ceph_fsid,
+ ceph_images_key => $ceph_images_key,
+ ceph_mon_host => $ceph_mon_host,
+ ceph_mon_initial_members => $ceph_mon_initial_members,
+ ceph_osd_pool_default_size => $ceph_osd_pool_size,
+ ceph_osd_journal_size => $ceph_osd_journal_size,
+ ceph_volumes_key => $ceph_volumes_key,
agent_type => $this_agent,
enable_tunneling => true,
@@ -82,21 +142,17 @@ class opnfv::compute {
neutron_db_password => $neutron_db_password,
neutron_user_password => $neutron_user_password,
- neutron_host => $private_ip,
+ neutron_host => $neutron_private_vip,
- #ovs_bridge_mappings = $quickstack::params::ovs_bridge_mappings,
- #ovs_bridge_uplinks = $quickstack::params::ovs_bridge_uplinks,
- #ovs_vlan_ranges = $quickstack::params::ovs_vlan_ranges,
ovs_tunnel_iface => $ovs_tunnel_if,
ovs_tunnel_network => '',
- ovs_l2_population => 'True',
+ ovs_l2_population => 'false',
tenant_network_type => 'vxlan',
tunnel_id_ranges => '1:1000',
- #ovs_vxlan_udp_port = $quickstack::params::ovs_vxlan_udp_port,
ovs_tunnel_types => ['vxlan'],
- verbose => $quickstack::params::verbose,
+ verbose => 'true',
security_group_api => 'neutron',
}
diff --git a/common/puppet-opnfv/manifests/controller_networker.pp b/common/puppet-opnfv/manifests/controller_networker.pp
index 1c65779..c4e7423 100644
--- a/common/puppet-opnfv/manifests/controller_networker.pp
+++ b/common/puppet-opnfv/manifests/controller_networker.pp
@@ -11,140 +11,361 @@
# 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.
-
+#
+#Provides HA or non-HA setup for OpenStack Controller with ODL integration
+#Mandatory common and HA variables are needed to setup each Controller
+#ha_flag set to true will provide OpenStack HA of the following services:
+#rabbitmq, galera mariadb, keystone, glance, nova, cinder, horizon, neutron
+#includes all sub-services of those features (i.e. neutron-server, neutron-lg-agent, etc)
class opnfv::controller_networker {
- ###use 8081 as a default work around swift service
- if $odl_rest_port == '' {$odl_rest_port = '8081'}
-
+ if $odl_rest_port == '' { $odl_rest_port= '8081'}
if ($odl_flag != '') and str2bool($odl_flag) {
$ml2_mech_drivers = ['opendaylight']
$this_agent = 'opendaylight'
- class {"opendaylight":
- odl_rest_port => $odl_rest_port,
- extra_features => ['odl-base-all', 'odl-aaa-authn', 'odl-restconf', 'odl-nsf-all', 'odl-adsal-northbound', 'odl-mdsal-apidocs', 'odl-ovsdb-openstack', 'odl-ovsdb-northbound', 'odl-dlux-core'],
- }
- }
- else {
+ } else {
$ml2_mech_drivers = ['openvswitch','l2population']
$this_agent = 'ovs'
}
- if $ovs_tunnel_if == '' { fail('ovs_tunnel_if is empty') }
+
+ ##Mandatory Common variables
if $admin_email == '' { fail('admin_email is empty') }
- if $admin_password == '' { fail('admin_password is empty') }
-
- if $public_ip == '' { fail('public_ip is empty') }
- if $private_ip == '' { fail('private_ip is empty') }
-
- if $odl_control_ip == '' { $odl_control_ip = $private_ip }
-
- if $mysql_ip == '' { fail('mysql_ip is empty') }
- if $mysql_root_password == '' { fail('mysql_root_password is empty') }
- if $amqp_ip == '' { fail('amqp_ip is empty') }
-
- if $memcache_ip == '' { fail('memcache_ip is empty') }
- if $neutron_ip == '' { fail('neutron_ip is empty') }
-
- if $keystone_admin_token == '' { fail('keystone_admin_token is empty') }
- if $keystone_db_password == '' { fail('keystone_db_password is empty') }
-
- if $horizon_secret_key == '' { fail('horizon_secret_key is empty') }
- #if $trystack_db_password == '' { fail('trystack_db_password is empty') }
-
- if $nova_user_password == '' { fail('nova_user_password is empty') }
- if $nova_db_password == '' { fail('nova_db_password is empty') }
-
- if $cinder_user_password == '' { fail('cinder_user_password is empty') }
- if $cinder_db_password == '' { fail('cinder_db_password is empty') }
-
- if $glance_user_password == '' { fail('glance_user_password is empty') }
- if $glance_db_password == '' { fail('glance_db_password is empty') }
-
- if $neutron_user_password == '' { fail('neutron_user_password is empty') }
- if $neutron_db_password == '' { fail('neutron_db_password is empty') }
- if $neutron_metadata_shared_secret == '' { fail('neutron_metadata_shared_secret is empty') }
-
- if $ceilometer_user_password == '' { fail('ceilometer_user_password is empty') }
- if $ceilometer_metering_secret == '' { fail('ceilometer_user_password is empty') }
-
- if $heat_user_password == '' { fail('heat_user_password is empty') }
- if $heat_db_password == '' { fail('heat_db_password is empty') }
- if $heat_auth_encrypt_key == '' { fail('heat_auth_encrypt_key is empty') }
-
- if $swift_user_password == '' { fail('swift_user_password is empty') }
- if $swift_shared_secret == '' { fail('swift_shared_secret is empty') }
- if $swift_admin_password == '' { fail('swift_admin_password is empty') }
-
- class { "quickstack::neutron::controller_networker":
- admin_email => $admin_email,
- admin_password => $admin_password,
- agent_type => $this_agent,
- enable_tunneling => true,
- ovs_tunnel_iface => $ovs_tunnel_if,
- ovs_tunnel_network => '',
- ovs_tunnel_types => ['vxlan'],
- ovs_l2_population => 'True',
- external_network_bridge => 'br-ex',
- tenant_network_type => 'vxlan',
- tunnel_id_ranges => '1:1000',
- controller_admin_host => $private_ip,
- controller_priv_host => $private_ip,
- controller_pub_host => $public_ip,
- ssl => false,
- #support_profile => $quickstack::params::support_profile,
- #freeipa => $quickstack::params::freeipa,
-
- mysql_host => $mysql_ip,
- mysql_root_password => $mysql_root_password,
- #amqp_provider => $amqp_provider,
- amqp_host => $amqp_ip,
- amqp_username => 'guest',
- amqp_password => 'guest',
- #amqp_nssdb_password => $quickstack::params::amqp_nssdb_password,
-
- keystone_admin_token => $keystone_admin_token,
- keystone_db_password => $keystone_db_password,
-
- ceilometer_metering_secret => $ceilometer_metering_secret,
- ceilometer_user_password => $ceilometer_user_password,
-
- cinder_backend_gluster => $quickstack::params::cinder_backend_gluster,
- cinder_backend_gluster_name => $quickstack::params::cinder_backend_gluster_name,
- cinder_gluster_shares => $quickstack::params::cinder_gluster_shares,
- cinder_user_password => $cinder_user_password,
- cinder_db_password => $cinder_db_password,
-
- glance_db_password => $glance_db_password,
- glance_user_password => $glance_user_password,
-
- heat_cfn => true,
- heat_cloudwatch => true,
- heat_db_password => $heat_db_password,
- heat_user_password => $heat_user_password,
- heat_auth_encrypt_key => $heat_auth_encrypt_key,
-
- horizon_secret_key => $horizon_secret_key,
- horizon_ca => $quickstack::params::horizon_ca,
- horizon_cert => $quickstack::params::horizon_cert,
- horizon_key => $quickstack::params::horizon_key,
+ if $ovs_tunnel_if == '' { fail('ovs_tunnel_if is empty') }
+
+ ##Most users will only care about a single user/password for all services
+ ##so lets create one variable that can be used instead of separate usernames/passwords
+ if !$single_username { $single_username = 'octopus' }
+ if !$single_password { $single_password = 'octopus' }
+
+ if !$keystone_admin_token { $keystone_admin_token = $single_password }
+ if !$neutron_metadata_shared_secret { $neutron_metadata_shared_secret = $single_password }
+ if !$mysql_root_password { $mysql_root_password = $single_password }
+ if !$admin_password { $admin_password = $single_password }
+
+ ##Check for HA, if not leave old functionality alone
+ if $ha_flag and str2bool($ha_flag) {
+ ##Mandatory HA variables
+ if !$controllers_ip_array { fail('controllers_ip_array is empty') }
+ $controllers_ip_array = split($controllers_ip_array, ',')
+ if !$controllers_hostnames_array { fail('controllers_hostnames_array is empty') }
+ $controllers_hostnames_array = split($controllers_hostnames_array, ',')
+ if !$amqp_vip { fail('amqp_vip is empty') }
+ if !$private_subnet { fail('private_subnet is empty')}
+ if !$cinder_admin_vip { fail('cinder_admin_vip is empty') }
+ if !$cinder_private_vip { fail('cinder_private_vip is empty') }
+ if !$cinder_public_vip { fail('cinder_public_vip is empty') }
+ if !$db_vip { fail('db_vip is empty') }
+ if !$glance_admin_vip { fail('glance_admin_vip is empty') }
+ if !$glance_private_vip { fail('glance_private_vip is empty') }
+ if !$glance_public_vip { fail('glance_public_vip is empty') }
+ if !$horizon_admin_vip { fail('horizon_admin_vip is empty') }
+ if !$horizon_private_vip { fail('horizon_private_vip is empty') }
+ if !$horizon_public_vip { fail('horizon_public_vip is empty') }
+ if !$keystone_admin_vip { fail('keystone_admin_vip is empty') }
+ if !$keystone_private_vip { fail('keystone_private_vip is empty') }
+ if !$keystone_public_vip { fail('keystone_public_vip is empty') }
+ if !$loadbalancer_vip { fail('loadbalancer_vip is empty') }
+ if !$neutron_admin_vip { fail('neutron_admin_vip is empty') }
+ if !$neutron_private_vip { fail('neutron_private_vip is empty') }
+ if !$neutron_public_vip { fail('neutron_public_vip is empty') }
+ if !$nova_admin_vip { fail('nova_admin_vip is empty') }
+ if !$nova_private_vip { fail('nova_private_vip is empty') }
+ if !$nova_public_vip { fail('nova_public_vip is empty') }
+
+
+ ##Optional HA variables
+ if !$amqp_username { $amqp_username = $single_username }
+ if !$amqp_password { $amqp_password = $single_password }
+ if !$ceph_fsid { $ceph_fsid = '904c8491-5c16-4dae-9cc3-6ce633a7f4cc' }
+ if !$ceph_images_key { $ceph_images_key = 'AQAfHBdUKLnUFxAAtO7WPKQZ8QfEoGqH0CLd7A==' }
+ if !$ceph_mon_host { $ceph_mon_host= $controllers_ip_array }
+ if !$ceph_mon_initial_members { $ceph_mon_initial_members = $controllers_hostnames_array}
+ if !$ceph_osd_journal_size { $ceph_osd_journal_size = '1000' }
+ if !$ceph_osd_pool_size { $ceph_osd_pool_size = '1' }
+ if !$ceph_public_network { $ceph_public_network = $private_subnet }
+ if !$ceph_volumes_key { $ceph_volumes_key = 'AQAfHBdUsFPTHhAAfqVqPq31FFCvyyO7oaOQXw==' }
+ if !$cinder_db_password { $cinder_db_password = $single_password }
+ if !$cinder_user_password { $cinder_user_password = $single_password }
+ if !$cluster_control_ip { $cluster_control_ip = $controllers_ip_array[0] }
+ if !$horizon_secret { $horizon_secret = $single_password }
+ if !$glance_db_password { $glance_db_password = $single_password }
+ if !$keystone_db_password { $keystone_db_password = $single_password }
+ if !$keystone_user_password { $keystone_user_password = $single_password }
+ if !$lb_backend_server_addrs { $lb_backend_server_addrs = $controllers_ip_array }
+ if !$lb_backend_server_names { $lb_backend_server_names = $controllers_hostnames_array }
+ if !$neutron_db_password { $neutron_db_password = $single_password }
+ if !$neutron_user_password { $neutron_user_password = $single_password }
+ if !$nova_db_password { $nova_db_password = $single_password }
+ if !$nova_user_password { $nova_user_password = $single_password }
+ if !$pcmk_server_addrs {$pcmk_server_addrs = $controllers_ip_array}
+ if !$pcmk_server_names {$pcmk_server_names = ["pcmk-${controllers_hostnames_array[0]}", "pcmk-${controllers_hostnames_array[1]}", "pcmk-${controllers_hostnames_array[2]}"] }
+ if !$rbd_secret_uuid { $rbd_secret_uuid = '3b519746-4021-4f72-957e-5b9d991723be' }
+
+ ##we assume here that if not provided, the first controller is where ODL will reside
+ ##this is fine for now as we will replace ODL with ODL HA when it is ready
+ if $odl_control_ip == '' { $odl_control_ip = $controllers_ip_array[0] }
+
+
+ class { "quickstack::openstack_common": }
+ ->
+ class { "quickstack::pacemaker::params":
+ amqp_password => $amqp_password,
+ amqp_username => $amqp_username,
+ amqp_vip => $amqp_vip,
+ ceph_cluster_network => $private_subnet,
+ ceph_fsid => $ceph_fsid,
+ ceph_images_key => $ceph_images_key,
+ ceph_mon_host => $ceph_mon_host,
+ ceph_mon_initial_members => $ceph_mon_initial_members,
+ ceph_osd_journal_size => $ceph_osd_journal_size,
+ ceph_osd_pool_size => $ceph_osd_pool_size,
+ ceph_public_network => $ceph_public_network,
+ ceph_volumes_key => $ceph_volumes_key,
+ cinder_admin_vip => $cinder_admin_vip,
+ cinder_db_password => $cinder_db_password,
+ cinder_private_vip => $cinder_private_vip,
+ cinder_public_vip => $cinder_public_vip,
+ cinder_user_password => $cinder_user_password,
+ cluster_control_ip => $cluster_control_ip,
+ db_vip => $db_vip,
+ glance_admin_vip => $glance_admin_vip,
+ glance_db_password => $glance_db_password,
+ glance_private_vip => $glance_private_vip,
+ glance_public_vip => $glance_public_vip,
+ glance_user_password => $glance_user_password,
+ heat_cfn_enabled => 'false',
+ horizon_admin_vip => $horizon_admin_vip,
+ horizon_private_vip => $horizon_private_vip,
+ horizon_public_vip => $horizon_public_vip,
+ include_ceilometer => 'false',
+ include_cinder => 'true',
+ include_glance => 'true',
+ include_heat => 'false',
+ include_horizon => 'true',
+ include_keystone => 'true',
+ include_neutron => 'true',
+ include_nosql => 'false',
+ include_nova => 'true',
+ include_swift => 'false',
+ keystone_admin_vip => $keystone_admin_vip,
+ keystone_db_password => $keystone_db_password,
+ keystone_private_vip => $keystone_private_vip,
+ keystone_public_vip => $keystone_public_vip,
+ keystone_user_password => $keystone_user_password,
+ lb_backend_server_addrs => $lb_backend_server_addrs,
+ lb_backend_server_names => $lb_backend_server_names,
+ loadbalancer_vip => $loadbalancer_vip,
+ neutron => 'true',
+ neutron_admin_vip => $neutron_admin_vip,
+ neutron_db_password => $neutron_db_password,
+ neutron_metadata_proxy_secret => $neutron_metadata_proxy_secret,
+ neutron_private_vip => $neutron_private_vip,
+ neutron_public_vip => $neutron_public_vip,
+ neutron_user_password => $neutron_user_password,
+ nova_admin_vip => $nova_admin_vip,
+ nova_db_password => $nova_db_password,
+ nova_private_vip => $nova_private_vip,
+ nova_public_vip => $nova_public_vip,
+ nova_user_password => $nova_user_password,
+ pcmk_iface => $ovs_tunnel_if,
+ pcmk_server_addrs => $pcmk_server_addrs,
+ pcmk_server_names => $pcmk_server_names,
+ private_iface => $ovs_tunnel_if,
+ }
+ ->
+ class { "quickstack::pacemaker::common": }
+ ->
+ class { "quickstack::pacemaker::load_balancer": }
+ ->
+ class { "quickstack::pacemaker::galera":
+ mysql_root_password => $mysql_root_password,
+ wsrep_cluster_members => $controllers_ip_array,
+ }
+ ->
+ class { "quickstack::pacemaker::qpid": }
+ ->
+ class { "quickstack::pacemaker::rabbitmq": }
+ ->
+ class { "quickstack::pacemaker::keystone":
+ admin_email => $admin_email,
+ admin_password => $admin_password,
+ admin_token => $keystone_admin_token,
+ cinder => 'true',
+ heat => 'false',
+ heat_cfn => 'false',
+ keystonerc => 'true',
+ use_syslog => 'true',
+ verbose => 'true',
+ }
+ ->
+ class { "quickstack::pacemaker::swift": }
+ ->
+ class { "quickstack::pacemaker::glance":
+ backend => 'rbd',
+ debug => true,
+ pcmk_fs_manage => 'false',
+ use_syslog => true,
+ verbose => true
+ }
+ ->
+ class { "quickstack::pacemaker::nova":
+ neutron_metadata_proxy_secret => $neutron_metadata_shared_secret,
+ }
+ ->
+ class { "quickstack::pacemaker::cinder":
+ backend_rbd => true,
+ rbd_secret_uuid => $rbd_secret_uuid,
+ use_syslog => true,
+ verbose => true,
+ volume => true,
+ }
+ ->
+ class { "quickstack::pacemaker::heat": }
+ ->
+ class { "quickstack::pacemaker::constraints": }
+
+ class { "quickstack::pacemaker::nosql": }
+
+ class { "quickstack::pacemaker::memcached": }
+
+ class { "quickstack::pacemaker::ceilometer":
+ ceilometer_metering_secret => $single_password,
+ }
+
+ class { "quickstack::pacemaker::horizon":
+ horizon_ca => '/etc/ipa/ca.crt',
+ horizon_cert => '/etc/pki/tls/certs/PUB_HOST-horizon.crt',
+ horizon_key => '/etc/pki/tls/private/PUB_HOST-horizon.key',
+ secret_key => $horizon_secret,
+ verbose => 'true',
+ }
+
+ class { "quickstack::pacemaker::neutron":
+ agent_type => $this_agent,
+ enable_tunneling => 'true',
+ ml2_mechanism_drivers => $ml2_mech_drivers,
+ ml2_network_vlan_ranges => ["physnet1:10:50"],
+ odl_controller_ip => $odl_control_ip,
+ odl_controller_port => $odl_rest_port,
+ ovs_tunnel_iface => $ovs_tunnel_if,
+ ovs_tunnel_types => ["vxlan"],
+ verbose => 'true',
+ }
+
+ } else {
+
+ if $public_ip == '' { fail('public_ip is empty') }
+ if $private_ip == '' { fail('private_ip is empty') }
+
+ if $odl_control_ip == '' { $odl_control_ip = $private_ip }
+
+ if $mysql_ip == '' { fail('mysql_ip is empty') }
+ if $mysql_root_password == '' { fail('mysql_root_password is empty') }
+ if $amqp_ip == '' { fail('amqp_ip is empty') }
+
+ if $memcache_ip == '' { fail('memcache_ip is empty') }
+ if $neutron_ip == '' { fail('neutron_ip is empty') }
+
+ if $keystone_db_password == '' { fail('keystone_db_password is empty') }
+
+ if $horizon_secret_key == '' { fail('horizon_secret_key is empty') }
+
+ if $nova_user_password == '' { fail('nova_user_password is empty') }
+ if $nova_db_password == '' { fail('nova_db_password is empty') }
+
+ if $cinder_user_password == '' { fail('cinder_user_password is empty') }
+ if $cinder_db_password == '' { fail('cinder_db_password is empty') }
+
+ if $glance_user_password == '' { fail('glance_user_password is empty') }
+ if $glance_db_password == '' { fail('glance_db_password is empty') }
+
+ if $neutron_user_password == '' { fail('neutron_user_password is empty') }
+ if $neutron_db_password == '' { fail('neutron_db_password is empty') }
+ if $neutron_metadata_shared_secret == '' { fail('neutron_metadata_shared_secret is empty') }
+
+ if $ceilometer_user_password == '' { fail('ceilometer_user_password is empty') }
+ if $ceilometer_metering_secret == '' { fail('ceilometer_user_password is empty') }
+
+ if $heat_user_password == '' { fail('heat_user_password is empty') }
+ if $heat_db_password == '' { fail('heat_db_password is empty') }
+ if $heat_auth_encrypt_key == '' { fail('heat_auth_encrypt_key is empty') }
+
+ if $swift_user_password == '' { fail('swift_user_password is empty') }
+ if $swift_shared_secret == '' { fail('swift_shared_secret is empty') }
+ if $swift_admin_password == '' { fail('swift_admin_password is empty') }
+
+ class { "quickstack::neutron::controller_networker":
+ admin_email => $admin_email,
+ admin_password => $admin_password,
+ agent_type => $this_agent,
+ enable_tunneling => true,
+ ovs_tunnel_iface => $ovs_tunnel_if,
+ ovs_tunnel_network => '',
+ ovs_tunnel_types => ['vxlan'],
+ ovs_l2_population => 'True',
+ external_network_bridge => 'br-ex',
+ tenant_network_type => 'vxlan',
+ tunnel_id_ranges => '1:1000',
+ controller_admin_host => $private_ip,
+ controller_priv_host => $private_ip,
+ controller_pub_host => $public_ip,
+ ssl => false,
+ #support_profile => $quickstack::params::support_profile,
+ #freeipa => $quickstack::params::freeipa,
+
+ mysql_host => $mysql_ip,
+ mysql_root_password => $mysql_root_password,
+ #amqp_provider => $amqp_provider,
+ amqp_host => $amqp_ip,
+ amqp_username => 'guest',
+ amqp_password => 'guest',
+ #amqp_nssdb_password => $quickstack::params::amqp_nssdb_password,
+
+ keystone_admin_token => $keystone_admin_token,
+ keystone_db_password => $keystone_db_password,
+
+ ceilometer_metering_secret => $ceilometer_metering_secret,
+ ceilometer_user_password => $ceilometer_user_password,
+
+ cinder_backend_gluster => $quickstack::params::cinder_backend_gluster,
+ cinder_backend_gluster_name => $quickstack::params::cinder_backend_gluster_name,
+ cinder_gluster_shares => $quickstack::params::cinder_gluster_shares,
+ cinder_user_password => $cinder_user_password,
+ cinder_db_password => $cinder_db_password,
+
+ glance_db_password => $glance_db_password,
+ glance_user_password => $glance_user_password,
+
+ heat_cfn => true,
+ heat_cloudwatch => true,
+ heat_db_password => $heat_db_password,
+ heat_user_password => $heat_user_password,
+ heat_auth_encrypt_key => $heat_auth_encrypt_key,
+
+ horizon_secret_key => $horizon_secret_key,
+ horizon_ca => $quickstack::params::horizon_ca,
+ horizon_cert => $quickstack::params::horizon_cert,
+ horizon_key => $quickstack::params::horizon_key,
- ml2_mechanism_drivers => $ml2_mech_drivers,
-
- #neutron => true,
- neutron_metadata_proxy_secret => $neutron_metadata_shared_secret,
- neutron_db_password => $neutron_db_password,
- neutron_user_password => $neutron_user_password,
-
- nova_db_password => $nova_db_password,
- nova_user_password => $nova_user_password,
-
- odl_controller_ip => $odl_control_ip,
- odl_controller_port => $odl_rest_port,
- swift_shared_secret => $swift_shared_secret,
- swift_admin_password => $swift_admin_password,
- swift_ringserver_ip => '192.168.203.1',
- swift_storage_ips => ["192.168.203.2","192.168.203.3","192.168.203.4"],
- swift_storage_device => 'device1',
- }
+ ml2_mechanism_drivers => $ml2_mech_drivers,
+
+ #neutron => true,
+ neutron_metadata_proxy_secret => $neutron_metadata_shared_secret,
+ neutron_db_password => $neutron_db_password,
+ neutron_user_password => $neutron_user_password,
+
+ nova_db_password => $nova_db_password,
+ nova_user_password => $nova_user_password,
+ odl_controller_ip => $odl_control_ip,
+ odl_controller_port => $odl_rest_port,
+
+ swift_shared_secret => $swift_shared_secret,
+ swift_admin_password => $swift_admin_password,
+ swift_ringserver_ip => '192.168.203.1',
+ swift_storage_ips => ["192.168.203.2","192.168.203.3","192.168.203.4"],
+ swift_storage_device => 'device1',
+ }
+
+ }
}
diff --git a/common/puppet-opnfv/manifests/odl_service.pp b/common/puppet-opnfv/manifests/odl_service.pp
new file mode 100644
index 0000000..bbe8218
--- /dev/null
+++ b/common/puppet-opnfv/manifests/odl_service.pp
@@ -0,0 +1,24 @@
+#Copyright 2015 Open Platform for NFV Project, Inc. and its contributors
+#
+# Licensed 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.
+#
+#Class installs opendaylight with a default rest port of 8081
+#This is to work around OpenStack Swift which also uses common port 8080
+
+class opnfv::odl_service {
+ if !$odl_rest_port { $odl_rest_port = '8081'}
+ class {"opendaylight":
+ extra_features => ['odl-base-all', 'odl-aaa-authn', 'odl-restconf', 'odl-nsf-all', 'odl-adsal-northbound', 'odl-mdsal-apidocs', 'odl-ovsdb-openstack', 'odl-ovsdb-northbound', 'odl-dlux-core'],
+ odl_rest_port => $odl_rest_port,
+ }
+}
diff --git a/common/puppet-opnfv/manifests/repo.pp b/common/puppet-opnfv/manifests/repo.pp
index b11098c..8d8a025 100644
--- a/common/puppet-opnfv/manifests/repo.pp
+++ b/common/puppet-opnfv/manifests/repo.pp
@@ -32,5 +32,23 @@ class opnfv::repo {
enabled => 1,
gpgcheck => 0,
}
+
+ yumrepo {
+ "ceph":
+ baseurl => "http://ceph.com/rpm-giant/el7/\$basearch",
+ descr => "Ceph packages for \$basearch",
+ enabled => 1,
+ gpgcheck => 0;
+ "Ceph-noarch":
+ baseurl => "http://ceph.com/rpm-giant/el7/noarch",
+ descr => "Ceph noarch packages",
+ enabled => 1,
+ gpgcheck => 0;
+ "ceph-source":
+ baseurl => "http://ceph.com/rpm-giant/el7/SRPMS",
+ descr => "Ceph source packages",
+ enabled => 1,
+ gpgcheck => 0;
+ }
}
}
diff --git a/common/puppet-opnfv/manifests/templates/dockerfile/Dockerfile b/common/puppet-opnfv/manifests/templates/dockerfile/Dockerfile
index 6b2f241..5241a80 100644
--- a/common/puppet-opnfv/manifests/templates/dockerfile/Dockerfile
+++ b/common/puppet-opnfv/manifests/templates/dockerfile/Dockerfile
@@ -79,4 +79,4 @@ EXPOSE 52150
EXPOSE 36826
# set the ENTRYPOINT - An entry point allows us to run this container as an exectuable
-CMD ["/etc/init.d/start_odl_docker.sh"]
+CMD ["/etc/init.d/start_odl_docker_container.sh"]
diff --git a/foreman/build/Makefile b/foreman/build/Makefile
new file mode 100644
index 0000000..c08844f
--- /dev/null
+++ b/foreman/build/Makefile
@@ -0,0 +1,111 @@
+##############################################################################
+# Copyright (c) 2015 Ericsson AB and others.
+# stefan.k.berg@ericsson.com
+# jonas.bjurel@ericsson.com
+# dradez@redhat.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
+##############################################################################
+
+SHELL = /bin/bash
+############################################################################
+# BEGIN of variables to customize
+#
+#Input args
+export UNIT_TEST = FALSE
+export INTERACTIVE = TRUE
+export ISOSRC = file:$(shell pwd)/CentOS-7.0-1406-x86_64-Minimal.iso
+export ISOCACHE = $(shell pwd)/$(shell basename $(ISOSRC))
+export PRODNO = "OPNFV_BGS"
+export REVSTATE = "P0000"
+export NEWISO = $(shell pwd)/release/OPNFV-CentOS-7-x86_64-${REVSTATE}.iso
+export VBOXRPM = $(shell pwd)/VirtualBox-4.3-4.3.26_98988_fedora18-1.x86_64.rpm
+export VAGRANTRPM = $(shell pwd)/vagrant_1.7.2_x86_64.rpm
+
+# Note! Invoke with "make REVSTATE=RXXXX all" to make release build!
+# Invoke with ICOCACHE=/full/path/to/iso if cached ISO is in non-standard location.
+
+#Build variables
+export BUILD_BASE := $(shell pwd)
+export CACHE_DIR := $(BUILD_BASE)/cache
+export VERSION_FILE := $(BUILD_BASE)/.versions
+export TOPDIR := $(shell pwd)
+
+CENTDIR := $(TOPDIR)/centiso
+#
+# END of variables to customize
+#############################################################################
+
+SUBCLEAN = $(addsuffix .clean,$(SUBDIRS))
+
+
+.PHONY: all
+all: iso
+ @echo "Versions of cached build results built by" $(shell hostname) "at" $(shell date -u) > $(VERSION_FILE)
+ @echo "cache.mk" $(shell md5sum $(BUILD_BASE)/cache.mk | cut -f1 -d " ") >> $(VERSION_FILE)
+ @echo "config.mk" $(shell md5sum $(BUILD_BASE)/config.mk | cut -f1 -d " ") >> $(VERSION_FILE)
+
+############################################################################
+# BEGIN of Include definitions
+#
+include config.mk
+include cache.mk
+#
+# END Include definitions
+#############################################################################
+
+$(ISOCACHE):
+ #cp ~/Downloads/opnfv_iso/CentOS-7.0-1406-x86_64-Minimal.iso $(ISOCACHE)
+
+.PHONY: mount-centiso umount-centiso
+mount-centiso: $(ISOCACHE)
+ @echo "Mounting CentOS ISO in $(CENTDIR)"
+ @mkdir -p $(CENTDIR)
+ @fuseiso $(ISOCACHE) $(CENTDIR)
+
+umount-centiso:
+ @set +e
+ @echo "Unmounting CentOS ISO from $(CENTDIR)"
+ @fusermount -u $(CENTDIR)
+ @rmdir $(CENTDIR)
+ @set -e
+
+.PHONY: build-clean $(SUBCLEAN)
+build-clean: $(SUBCLEAN)
+ @rm -Rf centos
+ @rm -Rf release
+ @rm -Rf newiso
+ @rm -f $(NEWISO)
+
+.PHONY: clean $(SUBCLEAN)
+clean: clean-cache $(SUBCLEAN)
+ @rm -f *.iso
+ @rm -Rf release
+ @rm -Rf newiso
+ @rm -f $(NEWISO)
+ @rm -f $(BUILD_BASE)/.versions
+
+$(SUBCLEAN): %.clean:
+ $(MAKE) -C $* -f Makefile clean
+
+# Todo: Make things smarter - we shouldn't need to clean everything
+# betwen make invocations.
+.PHONY: iso
+iso: build-clean mount-centiso $(ISOCACHE) $(VBOXRPM) $(VAGRANTRPM)
+ @mkdir centos release
+ cp -r $(CENTDIR)/* centos
+ @make umount-centiso
+ # modify the installer iso's contents
+ @rm -rf centos/repodata
+ @cp -f isolinux.cfg centos/isolinux/isolinux.cfg
+ @cp $(VBOXRPM) centos/Packages
+ @cp $(VAGRANTRPM) centos/Packages
+ # regenerate yum repo data
+ @echo "Generating new yum metadata"
+ createrepo centos/Packages -g ../../c7-opnfv-x86_64-comps.xml -o centos
+ # build the iso
+ @echo "Building OPNFV iso"
+ mkisofs -b isolinux/isolinux.bin -no-emul-boot -boot-load-size 4 -boot-info-table -V "OPNFV CentOS 7 x86_64" -R -J -v -T -o $(NEWISO) centos
+ @printf "\n\nISO is built at $(NEWISO)\n\n"
diff --git a/foreman/build/c7-opnfv-x86_64-comps.xml b/foreman/build/c7-opnfv-x86_64-comps.xml
new file mode 100644
index 0000000..3d0266e
--- /dev/null
+++ b/foreman/build/c7-opnfv-x86_64-comps.xml
@@ -0,0 +1,277 @@
+<?xml version='1.0' encoding='UTF-8'?>
+<!DOCTYPE comps PUBLIC "-//CentOS//DTD Comps info//EN" "comps.dtd">
+<comps>
+
+ <group>
+ <id>core</id>
+ <name>Core</name>
+ <name xml:lang='af'>Kern</name>
+ <name xml:lang='am'>ማዕከላዊ ቦታ</name>
+ <name xml:lang='ar'>اللبّ</name>
+ <name xml:lang='as'>ভিত্তি</name>
+ <name xml:lang='bal'>هستگ</name>
+ <name xml:lang='be'>Падмурак</name>
+ <name xml:lang='bg'>Основа</name>
+ <name xml:lang='bn'>কোর</name>
+ <name xml:lang='bn_IN'>কোর</name>
+ <name xml:lang='bs'>Jezgra</name>
+ <name xml:lang='ca'>Nucli</name>
+ <name xml:lang='cs'>Úplný základ</name>
+ <name xml:lang='cy'>Craidd</name>
+ <name xml:lang='da'>Grundlæggende</name>
+ <name xml:lang='de'>Kern</name>
+ <name xml:lang='el'>Πυρήνας</name>
+ <name xml:lang='en_GB'>Core</name>
+ <name xml:lang='es'>Núcleo</name>
+ <name xml:lang='et'>Tuum</name>
+ <name xml:lang='fa'>اصل</name>
+ <name xml:lang='fi'>Keskeiset</name>
+ <name xml:lang='fr'>Core</name>
+ <name xml:lang='gl'>Núcleo</name>
+ <name xml:lang='gu'>મૂળ</name>
+ <name xml:lang='he'>ליבה</name>
+ <name xml:lang='hi'>कोर</name>
+ <name xml:lang='hr'>Jezgra</name>
+ <name xml:lang='hu'>Mag</name>
+ <name xml:lang='hy'>Հիմք</name>
+ <name xml:lang='ia'>Nucleo</name>
+ <name xml:lang='id'>Inti</name>
+ <name xml:lang='ilo'>Bugas</name>
+ <name xml:lang='is'>Lágmarkskerfi</name>
+ <name xml:lang='it'>Principale</name>
+ <name xml:lang='ja'>コア</name>
+ <name xml:lang='ka'>ბირთვი</name>
+ <name xml:lang='kn'>ಅಂತಸ್ಸಾರ</name>
+ <name xml:lang='ko'>핵심</name>
+ <name xml:lang='lv'>Pamatsistēma</name>
+ <name xml:lang='mai'>कोर</name>
+ <name xml:lang='mk'>Основни</name>
+ <name xml:lang='ml'>കോറ്‍</name>
+ <name xml:lang='mr'>कोर</name>
+ <name xml:lang='ms'>Teras</name>
+ <name xml:lang='nb'>Kjerne</name>
+ <name xml:lang='ne'>कोर</name>
+ <name xml:lang='nl'>Kern</name>
+ <name xml:lang='no'>Kjerne</name>
+ <name xml:lang='nso'>Bogare</name>
+ <name xml:lang='or'>ପ୍ରମୂଖ</name>
+ <name xml:lang='pa'>ਮੂਲ</name>
+ <name xml:lang='pl'>Rdzeń</name>
+ <name xml:lang='pt'>Núcleo</name>
+ <name xml:lang='pt_BR'>Núcleo</name>
+ <name xml:lang='ro'>Nucleu</name>
+ <name xml:lang='ru'>Основа</name>
+ <name xml:lang='si'>න්‍යෂ්ඨිය</name>
+ <name xml:lang='sk'>Jadro</name>
+ <name xml:lang='sl'>Jedro</name>
+ <name xml:lang='sq'>Bërthama</name>
+ <name xml:lang='sr'>Срж</name>
+ <name xml:lang='sr@latin'>Srž</name>
+ <name xml:lang='sr@Latn'>Srž</name>
+ <name xml:lang='sv'>Grund</name>
+ <name xml:lang='ta'>கோர்</name>
+ <name xml:lang='te'>అంతర్భాగం</name>
+ <name xml:lang='tg'>Система</name>
+ <name xml:lang='th'>แกนหลัก</name>
+ <name xml:lang='tr'>Çekirdek</name>
+ <name xml:lang='uk'>Основа</name>
+ <name xml:lang='ur'>مرکز</name>
+ <name xml:lang='vi'>Lõi</name>
+ <name xml:lang='zh_CN'>核心</name>
+ <name xml:lang='zh_TW'>核心</name>
+ <name xml:lang='zu'>Okuyikhona</name>
+ <description>Smallest possible installation.</description>
+ <description xml:lang='as'>ন্যূনতম ইনস্টল।</description>
+ <description xml:lang='bn'>ন্যূনতম ইনস্টলেশন।</description>
+ <description xml:lang='bn_IN'>ন্যূনতম ইনস্টলেশন।</description>
+ <description xml:lang='cs'>Nejmenší možná instalace.</description>
+ <description xml:lang='de'>Kleinstmögliche Installation.</description>
+ <description xml:lang='es'>La instalación más pequeña posible.</description>
+ <description xml:lang='fr'>Plus petite installation possible.</description>
+ <description xml:lang='gu'>નાનામાં નાના શક્ય સ્થાપન.</description>
+ <description xml:lang='hi'>लघुतम संभावित संस्थापन.</description>
+ <description xml:lang='ia'>Le minime possibile installation.</description>
+ <description xml:lang='it'>Minima installazione possibile.</description>
+ <description xml:lang='ja'>最小限のインストール</description>
+ <description xml:lang='kn'>ಅತ್ಯಲ್ಪಸಾಧ್ಯ ಅನುಸ್ಥಾಪನೆ.</description>
+ <description xml:lang='ko'>가능한 최소 설치</description>
+ <description xml:lang='ml'>സാധ്യമായ ഏറ്റവും ചെറിയ ഇന്‍സ്റ്റലേഷന്‍.</description>
+ <description xml:lang='mr'>शक्यतया सर्वात लहान प्रतिष्ठापन.</description>
+ <description xml:lang='or'>କ୍ଷୁଦ୍ରତମ ସମ୍ଭାବ୍ଯ ସ୍ଥାପନା।</description>
+ <description xml:lang='pa'>ਘੱਟੋ-ਘੱਟ ਸੰਭਵ ਇੰਸਟਾਲੇਸ਼ਨ।</description>
+ <description xml:lang='pl'>Najmniejsza możliwa instalacja.</description>
+ <description xml:lang='pt_BR'>Menor instalação possível</description>
+ <description xml:lang='ru'>Минимально возможная установка</description>
+ <description xml:lang='sv'>Minsta möjliga installation</description>
+ <description xml:lang='ta'>மிகச் சிறிய செயல்படுத்தக்கூடிய நிறுவல்.</description>
+ <description xml:lang='te'>సాధ్యమగు అతిచిన్న సంస్థాపన.</description>
+ <description xml:lang='uk'>Мінімально можливе встановлення.</description>
+ <description xml:lang='zh_CN'>最小可能安装。</description>
+ <description xml:lang='zh_TW'>最小型安裝。</description>
+ <default>false</default>
+ <uservisible>false</uservisible>
+ <packagelist>
+ <packagereq type="default">aic94xx-firmware</packagereq>
+ <packagereq type="default">alsa-firmware</packagereq>
+ <packagereq type="default">bfa-firmware</packagereq>
+ <packagereq type="default">dracut-config-rescue</packagereq>
+ <packagereq type="default">ivtv-firmware</packagereq>
+ <packagereq type="default">iwl1000-firmware</packagereq>
+ <packagereq type="default">iwl100-firmware</packagereq>
+ <packagereq type="default">iwl105-firmware</packagereq>
+ <packagereq type="default">iwl135-firmware</packagereq>
+ <packagereq type="default">iwl2000-firmware</packagereq>
+ <packagereq type="default">iwl2030-firmware</packagereq>
+ <packagereq type="default">iwl3160-firmware</packagereq>
+ <packagereq type="default">iwl3945-firmware</packagereq>
+ <packagereq type="default">iwl4965-firmware</packagereq>
+ <packagereq type="default">iwl5000-firmware</packagereq>
+ <packagereq type="default">iwl5150-firmware</packagereq>
+ <packagereq type="default">iwl6000-firmware</packagereq>
+ <packagereq type="default">iwl6000g2a-firmware</packagereq>
+ <packagereq type="default">iwl6000g2b-firmware</packagereq>
+ <packagereq type="default">iwl6050-firmware</packagereq>
+ <packagereq type="default">iwl7260-firmware</packagereq>
+ <packagereq type="default">kernel-tools</packagereq>
+ <packagereq type="default">libertas-sd8686-firmware</packagereq>
+ <packagereq type="default">libertas-sd8787-firmware</packagereq>
+ <packagereq type="default">libertas-usb8388-firmware</packagereq>
+ <packagereq type="default">linux-firmware</packagereq>
+ <packagereq type="default">microcode_ctl</packagereq>
+ <packagereq type="default">NetworkManager</packagereq>
+ <packagereq type="default">NetworkManager-tui</packagereq>
+ <packagereq type="default">postfix</packagereq>
+ <packagereq type="default">ql2100-firmware</packagereq>
+ <packagereq type="default">ql2200-firmware</packagereq>
+ <packagereq type="default">ql23xx-firmware</packagereq>
+ <packagereq type="mandatory">audit</packagereq>
+ <packagereq type="mandatory">basesystem</packagereq>
+ <packagereq type="mandatory">bash</packagereq>
+ <packagereq type="mandatory">biosdevname</packagereq>
+ <packagereq type="mandatory">btrfs-progs</packagereq>
+ <packagereq type="mandatory">coreutils</packagereq>
+ <packagereq type="mandatory">cronie</packagereq>
+ <packagereq type="mandatory">curl</packagereq>
+ <packagereq type="mandatory">dhclient</packagereq>
+ <packagereq type="mandatory">e2fsprogs</packagereq>
+ <packagereq type="mandatory">filesystem</packagereq>
+ <packagereq type="mandatory">glibc</packagereq>
+ <packagereq type="mandatory">hostname</packagereq>
+ <packagereq type="mandatory">initscripts</packagereq>
+ <packagereq type="mandatory">iproute</packagereq>
+ <packagereq type="mandatory">iprutils</packagereq>
+ <packagereq type="mandatory">iptables</packagereq>
+ <packagereq type="mandatory">iputils</packagereq>
+ <packagereq type="mandatory">irqbalance</packagereq>
+ <packagereq type="mandatory">kbd</packagereq>
+ <packagereq type="mandatory">kexec-tools</packagereq>
+ <packagereq type="mandatory">less</packagereq>
+ <packagereq type="mandatory">man-db</packagereq>
+ <packagereq type="mandatory">ncurses</packagereq>
+ <packagereq type="mandatory">openssh-clients</packagereq>
+ <packagereq type="mandatory">openssh-server</packagereq>
+ <packagereq type="mandatory">parted</packagereq>
+ <packagereq type="mandatory">passwd</packagereq>
+ <packagereq type="mandatory">plymouth</packagereq>
+ <packagereq type="mandatory">policycoreutils</packagereq>
+ <packagereq type="mandatory">procps-ng</packagereq>
+ <packagereq type="mandatory">rootfiles</packagereq>
+ <packagereq type="mandatory">rpm</packagereq>
+ <packagereq type="mandatory">rsyslog</packagereq>
+ <packagereq type="mandatory">selinux-policy-targeted</packagereq>
+ <packagereq type="mandatory">setup</packagereq>
+ <packagereq type="mandatory">shadow-utils</packagereq>
+ <packagereq type="mandatory">sudo</packagereq>
+ <packagereq type="mandatory">systemd</packagereq>
+ <packagereq type="mandatory">tar</packagereq>
+ <packagereq type="mandatory">tuned</packagereq>
+ <packagereq type="mandatory">util-linux</packagereq>
+ <packagereq type="mandatory">vagrant</packagereq>
+ <packagereq type="mandatory">vim-minimal</packagereq>
+ <packagereq type="mandatory">VirtualBox</packagereq>
+ <packagereq type="mandatory">xfsprogs</packagereq>
+ <packagereq type="mandatory">yum</packagereq>
+ <packagereq type="optional">dracut-config-generic</packagereq>
+ <packagereq type="optional">dracut-fips-aesni</packagereq>
+ <packagereq type="optional">dracut-fips</packagereq>
+ <packagereq type="optional">dracut-network</packagereq>
+ <packagereq type="optional">openssh-keycat</packagereq>
+ <packagereq type="optional">selinux-policy-mls</packagereq>
+ <packagereq type="optional">tboot</packagereq>
+ </packagelist>
+ </group>
+
+ <environment>
+ <id>opnfv_provisioning</id>
+ <name>OPNVF Provisioning Server Install</name>
+ <name xml:lang='as'>নূন্যতম ইনস্টল</name>
+ <name xml:lang='bn_IN'>ন্যূনতম ইনস্টল</name>
+ <name xml:lang='cs'>Minimální instalace</name>
+ <name xml:lang='de'>Minimale Installation</name>
+ <name xml:lang='es'>Instalación mínima</name>
+ <name xml:lang='fr'>Installation minimale</name>
+ <name xml:lang='gu'>ન્યૂનતમ સ્થાપન</name>
+ <name xml:lang='hi'>न्यूनतम संस्थापन</name>
+ <name xml:lang='it'>Installazione minima</name>
+ <name xml:lang='ja'>最小限のインストール</name>
+ <name xml:lang='kn'>ಕನಿಷ್ಟ ಅನುಸ್ಥಾಪನೆ</name>
+ <name xml:lang='ko'>최소 설치</name>
+ <name xml:lang='ml'>ഏറ്റവും കുറഞ്ഞ ഇന്‍സ്റ്റോള്‍</name>
+ <name xml:lang='mr'>किमान इंस्टॉल</name>
+ <name xml:lang='or'>ସର୍ବନିମ୍ନ ସ୍ଥାପନ</name>
+ <name xml:lang='pa'>ਘੱਟ ਤੋਂ ਘੱਟ ਇੰਸਟਾਲ</name>
+ <name xml:lang='pl'>Minimalna instalacja</name>
+ <name xml:lang='pt_BR'>Instalações Mínimas</name>
+ <name xml:lang='ru'>Минимальная установка</name>
+ <name xml:lang='ta'>குறைந்தபட்ச நிறுவல்</name>
+ <name xml:lang='te'>కనీసపు సంస్థాపన</name>
+ <name xml:lang='uk'>Мінімальна система</name>
+ <name xml:lang='zh_CN'>最小安装</name>
+ <name xml:lang='zh_TW'>最小型安裝</name>
+ <description>Basic functionality.</description>
+ <description xml:lang='as'>মৌলি কাৰ্য্যকৰীতা।</description>
+ <description xml:lang='bn_IN'>প্রাথমিক বৈশিষ্ট্য।</description>
+ <description xml:lang='cs'>Základní funkcionalita.</description>
+ <description xml:lang='de'>Grundlegende Funktionalität.</description>
+ <description xml:lang='es'>Funcionalidad básica.</description>
+ <description xml:lang='fr'>Fonctionnalité de base.</description>
+ <description xml:lang='gu'>મૂળભૂત વિધેય.</description>
+ <description xml:lang='hi'>मौलिक प्रकार्यात्मकता.</description>
+ <description xml:lang='it'>Funzione di base.</description>
+ <description xml:lang='ja'>基本的な機能です。</description>
+ <description xml:lang='kn'>ಮೂಲಭೂತ ಕ್ರಿಯಾಶೀಲತೆ.</description>
+ <description xml:lang='ko'>기본적인 기능입니다.</description>
+ <description xml:lang='ml'>അടിസ്ഥാന പ്രവൃത്തിവിശേഷണം.</description>
+ <description xml:lang='mr'>मूळ कार्यक्षमता.</description>
+ <description xml:lang='or'>ସାଧାରଣ କାର୍ଯ୍ୟକାରିତା।</description>
+ <description xml:lang='pa'>ਮੁੱਢਲੀ ਕਾਰਜਸ਼ੀਲਤਾ।</description>
+ <description xml:lang='pl'>Podstawowa funkcjonalność.</description>
+ <description xml:lang='pt_BR'>Função básica</description>
+ <description xml:lang='ru'>Базовая функциональность.</description>
+ <description xml:lang='ta'>அடிப்படை செயலம்சம்.</description>
+ <description xml:lang='te'>ప్రాథమిక ఫంక్షనాలిటి.</description>
+ <description xml:lang='uk'>Основні можливості.</description>
+ <description xml:lang='zh_CN'>基本功能。</description>
+ <description xml:lang='zh_TW'>基本功能。</description>
+ <display_order>5</display_order>
+ <grouplist>
+ <groupid>core</groupid>
+ </grouplist>
+ <optionlist>
+
+ </optionlist>
+ </environment>
+ <langpacks>
+ <match install="autocorr-%s" name="autocorr-en"/>
+ <match install="firefox-langpack-%s" name="firefox"/>
+ <match install="gimp-help-%s" name="gimp-help"/>
+ <match install="gnome-getting-started-docs-%s" name="gnome-getting-started-docs"/>
+ <match install="hunspell-%s" name="hunspell"/>
+ <match install="hyphen-%s" name="hyphen"/>
+ <match install="kde-l10n-%s" name="kdelibs"/>
+ <match install="libreoffice-langpack-%s" name="libreoffice-core"/>
+ <match install="man-pages-%s" name="man-pages"/>
+ <match install="mythes-%s" name="mythes"/>
+ </langpacks>
+
+</comps>
diff --git a/foreman/build/cache.mk b/foreman/build/cache.mk
new file mode 100644
index 0000000..9ae3a7c
--- /dev/null
+++ b/foreman/build/cache.mk
@@ -0,0 +1,78 @@
+##############################################################################
+# 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
+##############################################################################
+
+SHELL = /bin/bash
+CACHEVALIDATE := $(addsuffix .validate,$(SUBDIRS))
+CACHECLEAN := $(addsuffix .clean,$(CACHEFILES) $(CACHEDIRS))
+
+############################################################################
+# BEGIN of variables to customize
+#
+CACHEFILES += .versions
+CACHEFILES += $(shell basename $(ISOSRC))
+#
+# END of variables to customize
+############################################################################
+
+.PHONY: prepare-cache
+prepare-cache: make-cache-dir $(CACHEDIRS) $(CACHEFILES)
+
+.PHONY: make-cache-dir
+make-cache-dir:
+ @rm -rf ${CACHE_DIR}
+ @mkdir ${CACHE_DIR}
+
+.PHONY: clean-cache
+clean-cache: $(CACHECLEAN)
+ @rm -rf ${CACHE_DIR}
+
+.PHONY: $(CACHEDIRS)
+$(CACHEDIRS):
+ @mkdir -p $(dir $(CACHE_DIR)/$@)
+ @if [ ! -d $(BUILD_BASE)/$@ ]; then\
+ mkdir -p $(BUILD_BASE)/$@;\
+ fi
+ @ln -s $(BUILD_BASE)/$@ $(CACHE_DIR)/$@
+
+.PHONY: $(CACHEFILES)
+$(CACHEFILES):
+ @mkdir -p $(dir $(CACHE_DIR)/$@)
+ @if [ ! -d $(dir $(BUILD_BASE)/$@) ]; then\
+ mkdir -p $(dir $(BUILD_BASE)/$@);\
+ fi
+
+ @if [ ! -f $(BUILD_BASE)/$@ ]; then\
+ echo " " > $(BUILD_BASE)/$@;\
+ ln -s $(BUILD_BASE)/$@ $(CACHE_DIR)/$@;\
+ rm -f $(BUILD_BASE)/$@;\
+ else\
+ ln -s $(BUILD_BASE)/$@ $(CACHE_DIR)/$@;\
+ fi
+
+.PHONY: validate-cache
+validate-cache: prepare $(CACHEVALIDATE)
+ @if [[ $(shell md5sum $(BUILD_BASE)/config.mk | cut -f1 -d " ") != $(shell cat $(VERSION_FILE) | grep config.mk | awk '{print $$NF}') ]]; then\
+ echo "Cache does not match current config.mk definition, cache must be rebuilt";\
+ exit 1;\
+ fi;
+
+ @if [[ $(shell md5sum $(BUILD_BASE)/cache.mk | cut -f1 -d " ") != $(shell cat $(VERSION_FILE) | grep cache.mk | awk '{print $$NF}') ]]; then\
+ echo "Cache does not match current cache.mk definition, cache must be rebuilt";\
+ exit 1;\
+ fi;
+
+.PHONY: $(CACHEVALIDATE)
+$(CACHEVALIDATE): %.validate:
+ @echo VALIDATE $(CACHEVALIDATE)
+ $(MAKE) -C $* -f Makefile validate-cache
+
+.PHONY: $(CACHECLEAN)
+$(CACHECLEAN): %.clean:
+ rm -rf ${CACHE_DIR}/$*
diff --git a/foreman/build/config.mk b/foreman/build/config.mk
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/foreman/build/config.mk
diff --git a/foreman/build/isolinux.cfg b/foreman/build/isolinux.cfg
new file mode 100644
index 0000000..12848de
--- /dev/null
+++ b/foreman/build/isolinux.cfg
@@ -0,0 +1,120 @@
+default vesamenu.c32
+timeout 600
+
+display boot.msg
+
+# Clear the screen when exiting the menu, instead of leaving the menu displayed.
+# For vesamenu, this means the graphical background is still displayed without
+# the menu itself for as long as the screen remains in graphics mode.
+menu clear
+menu background splash.png
+menu title CentOS 7
+menu vshift 8
+menu rows 18
+menu margin 8
+#menu hidden
+menu helpmsgrow 15
+menu tabmsgrow 13
+
+# Border Area
+menu color border * #00000000 #00000000 none
+
+# Selected item
+menu color sel 0 #ffffffff #00000000 none
+
+# Title bar
+menu color title 0 #ff7ba3d0 #00000000 none
+
+# Press [Tab] message
+menu color tabmsg 0 #ff3a6496 #00000000 none
+
+# Unselected menu item
+menu color unsel 0 #84b8ffff #00000000 none
+
+# Selected hotkey
+menu color hotsel 0 #84b8ffff #00000000 none
+
+# Unselected hotkey
+menu color hotkey 0 #ffffffff #00000000 none
+
+# Help text
+menu color help 0 #ffffffff #00000000 none
+
+# A scrollbar of some type? Not sure.
+menu color scrollbar 0 #ffffffff #ff355594 none
+
+# Timeout msg
+menu color timeout 0 #ffffffff #00000000 none
+menu color timeout_msg 0 #ffffffff #00000000 none
+
+# Command prompt text
+menu color cmdmark 0 #84b8ffff #00000000 none
+menu color cmdline 0 #ffffffff #00000000 none
+
+# Do not display the actual menu unless the user presses a key. All that is displayed is a timeout message.
+
+menu tabmsg Press Tab for full configuration options on menu items.
+
+menu separator # insert an empty line
+menu separator # insert an empty line
+
+label linux
+ menu label ^Install OPNFV CentOS 7
+ menu default
+ kernel vmlinuz
+ append initrd=initrd.img inst.stage2=hd:LABEL=OPNFV\x20CentOS\x207\x20x86_64
+
+#label check
+# menu label Test this ^media & install CentOS 7
+# kernel vmlinuz
+# append initrd=initrd.img inst.stage2=hd:LABEL=CentOS\x207\x20x86_64 rd.live.check quiet
+
+menu separator # insert an empty line
+
+# utilities submenu
+menu begin ^Troubleshooting
+ menu title Troubleshooting
+
+label vesa
+ menu indent count 5
+ menu label Install CentOS 7 in ^basic graphics mode
+ text help
+ Try this option out if you're having trouble installing
+ CentOS 7.
+ endtext
+ kernel vmlinuz
+ append initrd=initrd.img inst.stage2=hd:LABEL=OPNFV\x20CentOS\x207\x20x86_64 xdriver=vesa nomodeset quiet
+
+label rescue
+ menu indent count 5
+ menu label ^Rescue a CentOS system
+ text help
+ If the system will not boot, this lets you access files
+ and edit config files to try to get it booting again.
+ endtext
+ kernel vmlinuz
+ append initrd=initrd.img inst.stage2=hd:LABEL=CentOS\x207\x20x86_64 rescue quiet
+
+label memtest
+ menu label Run a ^memory test
+ text help
+ If your system is having issues, a problem with your
+ system's memory may be the cause. Use this utility to
+ see if the memory is working correctly.
+ endtext
+ kernel memtest
+
+menu separator # insert an empty line
+
+label local
+ menu label Boot from ^local drive
+ localboot 0xffff
+
+menu separator # insert an empty line
+menu separator # insert an empty line
+
+label returntomain
+ menu label Return to ^main menu
+ menu exit
+
+menu end
diff --git a/foreman/ci/build.sh b/foreman/ci/build.sh
index e69de29..f3d5cf0 100644..100755
--- a/foreman/ci/build.sh
+++ b/foreman/ci/build.sh
@@ -0,0 +1,398 @@
+#!/bin/bash
+set -e
+##############################################################################
+# Copyright (c) 2015 Ericsson AB and others.
+# stefan.k.berg@ericsson.com
+# jonas.bjurel@ericsson.com
+# dradez@redhat.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
+##############################################################################
+
+trap 'echo "Exiting ..."; \
+if [ -f ${LOCK_FILE} ]; then \
+ if [ $(cat ${LOCK_FILE}) -eq $$ ]; then \
+ rm -f ${LOCK_FILE}; \
+ fi; \
+fi;' EXIT
+
+############################################################################
+# BEGIN of usage description
+#
+usage ()
+{
+cat << EOF
+$0 Builds the Foreman OPNFV Deployment ISO
+
+usage: $0 [-s spec-file] [-c cache-URI] [-l log-file] [-f Flags] build-directory
+
+OPTIONS:
+ -s spec-file ($BUILD_SPEC), define the build-spec file, default ../build/config.mk
+ -c cache base URI ($BUILD_CACHE_URI), specifies the base URI to a build cache to be used/updated - the name is automatically generated from the md5sum of the spec-file, http://, ftp://, file://[absolute path] suported.
+
+ -l log-file ($BUILD_LOG), specifies the output log-file (stdout and stderr), if not specified logs are output to console as normal
+ -v version tag to be applied to the build result
+ -r alternative remote access method script/program. curl is default.
+ -t run small build-script unit test.
+ -T run large build-script unit test.
+ -f build flags ($BUILD_FLAGS):
+ o s: Do nothing, succeed
+ o f: Do nothing, fail
+ o t: run build unit tests
+ o i: run interactive (-t flag to docker run)
+ o P: Populate a new local cache and push it to the (-c cache-URI) cache artifactory if -c option is present, currently file://, http:// and ftp:// are supported
+ o d: Detatch - NOT YET SUPPORTED
+
+ build-directory ($BUILD_DIR), specifies the directory for the output artifacts (.iso file).
+
+ -h help, prints this help text
+
+Description:
+build.sh builds opnfv .iso artifact.
+To reduce build time it uses build cache on a local or remote location. The cache is rebuilt and uploaded if either of the below conditions are met:
+1) The P(opulate) flag is set and the -c cache-base-URI is provided, if -c is not provided the cache will stay local.
+2) If the cache is invalidated by one of the following conditions:
+ - The config spec md5sum does not compare to the md5sum for the spec which the cache was built.
+ - The git Commit-Id on the remote repos/HEAD defined in the spec file does not correspont with the Commit-Id for what the cache was built with.
+3) A valid cache does not exist on the specified -c cache-base-URI.
+
+The cache URI object name is foreman_cache-"md5sum(spec file)"
+
+Logging by default to console, but can be directed elsewhere with the -l option in which case both stdout and stderr is redirected to that destination.
+
+Built in unit testing of components is enabled by adding the t(est) flag.
+
+Return codes:
+ - 0 Success!
+ - 1-99 Unspecified build error
+ - 100-199 Build system internal error (not build it self)
+ o 101 Build system instance busy
+ - 200 Build failure
+
+Examples:
+build -c http://opnfv.org/artifactory/foreman/cache -d ~/jenkins/genesis/foreman/ci/output -f ti
+NOTE: At current the build scope is set to the git root of the repository, -d destination locations outside that scope will not work
+EOF
+}
+#
+# END of usage description
+############################################################################
+
+############################################################################
+# BEGIN of variables to customize
+#
+BUILD_BASE=$(readlink -e ../build/)
+RESULT_DIR="${BUILD_BASE}/release"
+BUILD_SPEC="${BUILD_BASE}/config.mk"
+CACHE_DIR="cache"
+LOCAL_CACHE_ARCH_NAME="foreman-cache"
+REMOTE_CACHE_ARCH_NAME="foreman_cache-$(md5sum ${BUILD_SPEC}| cut -f1 -d " ")"
+REMOTE_ACCESS_METHD=curl
+INCLUDE_DIR=../include
+#
+# END of variables to customize
+############################################################################
+
+############################################################################
+# BEGIN of script assigned variables
+#
+SCRIPT_DIR=$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )
+LOCK_FILE="${SCRIPT_DIR}/.build.lck"
+TEST_SUCCEED=0
+TEST_FAIL=0
+UNIT_TEST=0
+UPDATE_CACHE=0
+POPULATE_CACHE=0
+RECURSIV=0
+DETACH=0
+DEBUG=0
+INTEGRATION_TEST=0
+FULL_INTEGRATION_TEST=0
+INTERACTIVE=0
+BUILD_CACHE_URI=
+BUILD_SPEC=
+BUILD_DIR=
+BUILD_LOG=
+BUILD_VERSION=
+MAKE_ARGS=
+#
+# END of script assigned variables
+############################################################################
+
+############################################################################
+# BEGIN of include pragmas
+#
+source ${INCLUDE_DIR}/build.sh.debug
+#
+# END of include
+############################################################################
+
+############################################################################
+# BEGIN of main
+#
+while getopts "s:c:d:v:f:l:r:RtTh" OPTION
+do
+ case $OPTION in
+ h)
+ usage
+ rc=0
+ exit $rc
+ ;;
+
+ s)
+ BUILD_SPEC=${OPTARG}
+ ;;
+
+ c)
+ BUILD_CACHE_URI=${OPTARG}
+ ;;
+
+ d)
+ BUILD_DIR=${OPTARG}
+ ;;
+
+ l)
+ BUILD_LOG=${OPTARG}
+ ;;
+
+ v)
+ BUILD_VERSION=${OPTARG}
+ ;;
+
+ f)
+ BUILD_FLAGS=${OPTARG}
+ ;;
+
+ r) REMOTE_ACCESS_METHD=${OPTARG}
+ ;;
+
+ R)
+ RECURSIVE=1
+ ;;
+
+ t)
+ INTEGRATION_TEST=1
+ ;;
+
+ T)
+ INTEGRATION_TEST=1
+ FULL_INTEGRATION_TEST=1
+ ;;
+
+ *)
+ echo "${OPTION} is not a valid argument"
+ rc=100
+ exit $rc
+ ;;
+ esac
+done
+
+if [ -z $BUILD_DIR ]; then
+ BUILD_DIR=$(echo $@ | cut -d ' ' -f ${OPTIND})
+fi
+
+for ((i=0; i<${#BUILD_FLAGS};i++)); do
+ case ${BUILD_FLAGS:$i:1} in
+ s)
+ rc=0
+ exit $rc
+ ;;
+
+ f)
+ rc=1
+ exit $rc
+ ;;
+
+ t)
+ UNIT_TEST=1
+ ;;
+
+ i)
+ INTERACTIVE=1
+ ;;
+
+ P)
+ POPULATE_CACHE=1
+ ;;
+
+ d)
+ DETACH=1
+ echo "Detach is not yet supported - exiting ...."
+ rc=100
+ exit $rc
+ ;;
+
+ D)
+ DEBUG=1
+ ;;
+
+ *)
+ echo "${BUILD_FLAGS:$i:1} is not a valid build flag - exiting ...."
+ rc=100
+ exit $rc
+ ;;
+ esac
+done
+
+shift $((OPTIND-1))
+
+if [ ${INTEGRATION_TEST} -eq 1 ]; then
+ integration-test
+ rc=0
+ exit $rc
+fi
+
+if [ ! -f ${BUILD_SPEC} ]; then
+ echo "spec file does not exist: $BUILD_SPEC - exiting ...."
+ rc=100
+ exit $rc
+fi
+
+if [ -z ${BUILD_DIR} ]; then
+ echo "Missing build directory - exiting ...."
+ rc=100
+ exit $rc
+fi
+
+if [ ! -z ${BUILD_LOG} ]; then
+ if [[ ${RECURSIVE} -ne 1 ]]; then
+ set +e
+ eval $0 -R $@ > ${BUILD_LOG} 2>&1
+ rc=$?
+ set -e
+ if [ $rc -ne 0]; then
+ exit $rc
+ fi
+ fi
+fi
+
+if [ ${TEST_SUCCEED} -eq 1 ]; then
+ sleep 1
+ rc=0
+ exit $rc
+fi
+
+if [ ${TEST_FAIL} -eq 1 ]; then
+ sleep 1
+ rc=1
+ exit $rc
+fi
+
+if [ -e ${LOCK_FILE} ]; then
+ echo "A build job is already running, exiting....."
+ rc=101
+ exit $rc
+fi
+
+echo $$ > ${LOCK_FILE}
+
+if [ ! -z ${BUILD_CACHE_URI} ]; then
+ if [ ${POPULATE_CACHE} -ne 1 ]; then
+ rm -rf /tmp/cache
+ mkdir /tmp/cache
+ echo "Downloading cach file ${BUILD_CACHE_URI}/${REMOTE_CACHE_ARCH_NAME} ..."
+ set +e
+ ${REMOTE_ACCESS_METHD} -o /tmp/cache/${LOCAL_CACHE_ARCH_NAME}.tgz ${BUILD_CACHE_URI}/${REMOTE_CACHE_ARCH_NAME}.tgz
+ tar -tzf ${BUILD_CACHE_URI}/${REMOTE_CACHE_ARCH_NAME}.tgz >/dev/null
+ rc=$?
+ set -e
+ if [ $rc -ne 0 ]; then
+ echo "Remote cache does not exist, or is not accessible - a new cache will be built ..."
+ POPULATE_CACHE=1
+ else
+ echo "Unpacking cache file ..."
+ tar -C /tmp/cache -xvf /tmp/cache/${LOCAL_CACHE_ARCH_NAME}.tgz
+ cp /tmp/cache/cache/.versions ${BUILD_BASE}/.
+ set +e
+ make -C ${BUILD_BASE} validate-cache;
+ rc=$?
+ set -e
+
+ if [ $rc -ne 0 ]; then
+ echo "Cache invalid - a new cache will be built "
+ POPULATE_CACHE=1
+ else
+ cp -rf /tmp/cache/cache/. ${BUILD_BASE}
+ fi
+ rm -rf /tmp/cache
+ fi
+ fi
+fi
+
+if [ ${POPULATE_CACHE} -eq 1 ]; then
+ if [ ${DEBUG} -eq 0 ]; then
+ set +e
+ cd ${BUILD_BASE} && make clean
+ rc=$?
+ set -e
+ if [ $rc -ne 0 ]; then
+ echo "Build - make clean failed, exiting ..."
+ rc=100
+ exit $rc
+ fi
+ fi
+fi
+
+if [ ! -z ${BUILD_VERSION} ]; then
+ MAKE_ARGS+="REVSTATE=${BUILD_VERSION} "
+fi
+
+if [ ${UNIT_TEST} -eq 1 ]; then
+ MAKE_ARGS+="UNIT_TEST=TRUE "
+else
+ MAKE_ARGS+="UNIT_TEST=FALSE "
+fi
+
+if [ ${INTERACTIVE} -eq 1 ]; then
+ MAKE_ARGS+="INTERACTIVE=TRUE "
+else
+ MAKE_ARGS+="INTERACTIVE=FALSE "
+fi
+
+MAKE_ARGS+=all
+
+if [ ${DEBUG} -eq 0 ]; then
+ set +e
+ cd ${BUILD_BASE} && make ${MAKE_ARGS}
+ rc=$?
+ set -e
+ if [ $rc -gt 0 ]; then
+ echo "Build: make all failed, exiting ..."
+ rc=200
+ exit $rc
+ fi
+else
+debug_make
+fi
+set +e
+make -C ${BUILD_BASE} prepare-cache
+rc=$?
+set -e
+
+if [ $rc -gt 0 ]; then
+ echo "Build: make prepare-cache failed - exiting ..."
+ rc=100
+ exit $rc
+fi
+echo "Copying built OPNFV .iso file to target directory ${BUILD_DIR} ..."
+rm -rf ${BUILD_DIR}
+mkdir -p ${BUILD_DIR}
+cp ${BUILD_BASE}/.versions ${BUILD_DIR}
+cp ${RESULT_DIR}/*.iso* ${BUILD_DIR}
+
+if [ $POPULATE_CACHE -eq 1 ]; then
+ if [ ! -z ${BUILD_CACHE_URI} ]; then
+ echo "Building cache ..."
+ tar --dereference -C ${BUILD_BASE} -caf ${BUILD_BASE}/${LOCAL_CACHE_ARCH_NAME}.tgz ${CACHE_DIR}
+ echo "Uploading cache ${BUILD_CACHE_URI}/${REMOTE_CACHE_ARCH_NAME}"
+ ${REMOTE_ACCESS_METHD} -T ${BUILD_BASE}/${LOCAL_CACHE_ARCH_NAME}.tgz ${BUILD_CACHE_URI}/${REMOTE_CACHE_ARCH_NAME}.tgz
+ rm ${BUILD_BASE}/${LOCAL_CACHE_ARCH_NAME}.tgz
+ fi
+fi
+echo "Success!!!"
+exit 0
+#
+# END of main
+############################################################################
diff --git a/foreman/include/build.sh.debug b/foreman/include/build.sh.debug
new file mode 100644
index 0000000..8b13789
--- /dev/null
+++ b/foreman/include/build.sh.debug
@@ -0,0 +1 @@
+
diff --git a/fuel/build/Makefile b/fuel/build/Makefile
index 364fe31..fda212d 100644
--- a/fuel/build/Makefile
+++ b/fuel/build/Makefile
@@ -62,6 +62,7 @@ all:
@echo "Versions of cached build results built by" $(shell hostname) "at" $(shell date -u) > $(VERSION_FILE)
@echo "cache.mk" $(shell md5sum $(BUILD_BASE)/cache.mk | cut -f1 -d " ") >> $(VERSION_FILE)
@echo "config.mk" $(shell md5sum $(BUILD_BASE)/config.mk | cut -f1 -d " ") >> $(VERSION_FILE)
+ $(MAKE) -C f_odl_docker -f Makefile all
@make -C docker
@docker/runcontext $(DOCKERIMG) $(MAKE) $(MAKEFLAGS) iso
diff --git a/fuel/build/f_odl_docker/puppet/modules/opnfv/manifests/odl_docker.pp b/fuel/build/f_odl_docker/puppet/modules/opnfv/manifests/odl_docker.pp
index ae24460..922ab41 100644
--- a/fuel/build/f_odl_docker/puppet/modules/opnfv/manifests/odl_docker.pp
+++ b/fuel/build/f_odl_docker/puppet/modules/opnfv/manifests/odl_docker.pp
@@ -35,6 +35,20 @@ class opnfv::odl_docker
source => "/etc/puppet/modules/opnfv/scripts/start_odl_container.sh",
mode => 750,
}
+
+ # fix failed to find the cgroup root issue
+ # https://github.com/docker/docker/issues/8791
+ if $::operatingsystem == 'Ubuntu' {
+ package {'cgroup-lite':
+ ensure => present,
+ }
+
+ service {'cgroup-lite':
+ ensure => running,
+ enable => true,
+ require => Package['cgroup-lite'],
+ }
+ }
}
}
}
diff --git a/fuel/build/f_odl_docker/puppet/modules/opnfv/scripts/start_odl_container.sh b/fuel/build/f_odl_docker/puppet/modules/opnfv/scripts/start_odl_container.sh
index 0b4fd46..0bddd20 100755
--- a/fuel/build/f_odl_docker/puppet/modules/opnfv/scripts/start_odl_container.sh
+++ b/fuel/build/f_odl_docker/puppet/modules/opnfv/scripts/start_odl_container.sh
@@ -24,7 +24,7 @@ DEV=1
MATCH_PORT=1
-LOCALPATH=/opt/opnfv/odl_docker
+LOCALPATH=/opt/opnfv/odl
DOCKERBINNAME=docker-latest
DOCKERIMAGENAME=odl_docker_image.tar
DNS=8.8.8.8
@@ -54,6 +54,10 @@ else
echo "Starting Docker in Daemon mode"
chmod +x $LOCALPATH/$DOCKERBINNAME
$LOCALPATH/$DOCKERBINNAME -d &
+
+ # wait until docker will be fully initialized
+ # before any further action against just started docker
+ sleep 5
fi
@@ -72,17 +76,18 @@ echo " starting up ODL - DLUX and Mapping Ports"
if [ "$MATCH_PORT" -eq "1" ]
then
echo "Starting up Docker..."
- docker rm odl_docker
+ $LOCALPATH/$DOCKERBINNAME rm odl_docker
+fi
if [ "$ENABLE_SHELL" -eq "1" ];
then
echo "Starting Container in Interactive Mode (/bin/bash will be provided, you will need to run ./start_odl_docker.sh inside the container yourself)"
- docker run --name odl_docker -p 8181:8181 -p 8185:8185 -p 9000:9000 -p 1099:1099 -p 8101:8101 -p 6633:6633 -p 43506:43506 -p 44444:44444 -p 6653:6653 -p 12001:12001 -p 6400:6400 -p 8080:8080 -p 7800:7800 -p 55130:55130 -p 52150:52150 -p 36826:26826 -i -d -t loving_daniel /bin/bash
+ $LOCALPATH/$DOCKERBINNAME run --name odl_docker -p 8181:8181 -p 8185:8185 -p 9000:9000 -p 1099:1099 -p 8101:8101 -p 6633:6633 -p 43506:43506 -p 44444:44444 -p 6653:6653 -p 12001:12001 -p 6400:6400 -p 6640:6640 -p 8080:8080 -p 7800:7800 -p 55130:55130 -p 52150:52150 -p 36826:26826 -i -t loving_daniel /bin/bash
else
echo "Starting Conatiner in Daemon mode - no shell will be provided and docker attach will not provide shell)"
- docker run --name odl_docker -p 8181:8181 -p 8185:8185 -p 9000:9000 -p 1099:1099 -p 8101:8101 -p 6633:6633 -p 43506:43506 -p 44444:44444 -p 6653:6653 -p 12001:12001 -p 6400:6400 -p 8080:8080 -p 7800:7800 -p 55130:55130 -p 52150:52150 -p 36826:26826 -i -d -t loving_daniel
+ $LOCALPATH/$DOCKERBINNAME run --name odl_docker -p 8181:8181 -p 8185:8185 -p 9000:9000 -p 1099:1099 -p 8101:8101 -p 6633:6633 -p 43506:43506 -p 44444:44444 -p 6653:6653 -p 12001:12001 -p 6400:6400 -p 6640:6640 -p 8080:8080 -p 7800:7800 -p 55130:55130 -p 52150:52150 -p 36826:26826 -i -d -t loving_daniel
echo "should see the process listed here in docker ps -a"
- docker ps -a;
+ $LOCALPATH/$DOCKERBINNAME ps -a;
echo "Match Port enabled, you can reach the DLUX login at: "
echo "http://$HOST_IP:8181/dlux.index.html"
fi
diff --git a/fuel/build/f_odl_docker/scripts/start_odl_container.sh b/fuel/build/f_odl_docker/scripts/start_odl_container.sh
deleted file mode 100755
index 0fca48f..0000000
--- a/fuel/build/f_odl_docker/scripts/start_odl_container.sh
+++ /dev/null
@@ -1,88 +0,0 @@
-#!/bin/bash
-# Ericsson Canada Inc.
-# Authoer: Daniel Smith
-#
-# A helper script to install and setup the ODL docker conatiner on the controller
-#
-#
-# Inputs: odl_docker_image.tar
-#
-# Usage: ./start_odl_docker.sh
-
-# ENVS
-source ~/.bashrc
-source ~/openrc
-
-# VARS
-
-# Switch for Dev mode - uses apt-get on control to cheat and get docker installed locally rather than from puppet source
-
-DEV=1
-
-# Switch for 1:1 port mapping of EXPOSED ports in Docker to the host, if set to 0, then random ports will be used - NOTE: this doesnt work for all web services X port on Host --> Y port in Container,
-# especially for SSL/HTTPS cases. Be aware.
-
-MATCH_PORT=1
-
-LOCALPATH=/opt/opnfv/odl_docker
-DOCKERBINNAME=docker-latest
-DOCKERIMAGENAME=odl_docker_image.tar
-DNS=8.8.8.8
-HOST_IP=`ifconfig br-fw-admin | grep -i "inet addr" | awk -F":" '{print $2}' | awk -F" " '{print $1}'`
-
-
-# Set this to "1" if you want to have your docker container startup into a shell
-
-
-ENABLE_SHELL=1
-
-
-echo " Fetching Docker "
-if [ "$DEV" -eq "1" ];
-# If testing Locally (on a control node) you can set DEV=1 to enable apt-get based install on the control node (not desired target, but good for testing).
-then
- echo "Dev Mode - Fetching from Internet";
- echo " this wont work in production builds";
- apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 36A1D7869245C8950F966E92D8576A8BA88D21E9
- mkdir -p $LOCALPATH
- wget https://get.docker.com/builds/Linux/x86_64/docker-latest -O $LOCALPATH/$DOCKERBINNAME
- wget http://ftp.us.debian.org/debian/pool/main/d/docker.io/docker.io_1.3.3~dfsg1-2_amd64.deb
- chmod 777 $LOCALPATH/$DOCKERBINNAME
- echo "done ";
-else
- echo "Using Binaries delivered from Puppet"
- echo "Starting Docker in Daemon mode"
- chmod +x $LOCALPATH/$DOCKERBINNAME
- $LOCALPATH/$DOCKERBINNAME -d &
-fi
-
-
-# We need to perform some cleanup of the Openstack Environment
-echo "TODO -- This should be automated in the Fuel deployment at some point"
-echo "However, the timing should come after basic tests are running, since this "
-echo " part will remove the subnet router association that is deployed automativally"
-echo " via fuel. Refer to the ODL + Openstack Integration Page "
-
-# Import the ODL container into docker
-
-echo "Importing ODL container into docker"
-$LOCALPATH/$DOCKERBINNAME load -i $LOCALPATH/$DOCKERIMAGENAME
-
-echo " starting up ODL - DLUX and Mapping Ports"
-if [ "$MATCH_PORT" -eq "1" ]
-then
- echo "Starting up Docker..."
- docker rm odl_docker
-
-if [ "$ENABLE_SHELL" -eq "1" ];
-then
- echo "Starting Container in Interactive Mode (/bin/bash will be provided, you will need to run ./start_odl_docker.sh inside the container yourself)"
- docker run --name odl_docker -p 8181:8181 -p 8185:8185 -p 9000:9000 -p 1099:1099 -p 8101:8101 -p 6633:6633 -p 43506:43506 -p 44444:44444 -p 6653:6653 -p 12001:12001 -p 6400:6400 -p 6640:6640 -p 8080:8080 -p 7800:7800 -p 55130:55130 -p 52150:52150 -p 36826:26826 -i -d -t loving_daniel /bin/bash
-else
- echo "Starting Conatiner in Daemon mode - no shell will be provided and docker attach will not provide shell)"
- docker run --name odl_docker -p 8181:8181 -p 8185:8185 -p 9000:9000 -p 1099:1099 -p 8101:8101 -p 6633:6633 -p 43506:43506 -p 44444:44444 -p 6653:6653 -p 12001:12001 -p 6400:6400 -p 6640:6640 -p 8080:8080 -p 7800:7800 -p 55130:55130 -p 52150:52150 -p 36826:26826 -i -d -t loving_daniel
- echo "should see the process listed here in docker ps -a"
- docker ps -a;
- echo "Match Port enabled, you can reach the DLUX login at: "
- echo "http://$HOST_IP:8181/dlux.index.html"
-fi