aboutsummaryrefslogtreecommitdiffstats
path: root/environments/network-environment.yaml
AgeCommit message (Expand)AuthorFilesLines
2017-04-12Replace references to the 192.0.2 networkGiulio Fidente1-2/+2
2017-02-23neutron: don't set external_network_bridge option by defaultIhar Hrachyshka1-2/+0
2017-01-09Correct typo in ManagementAllocationPools in network-environment.yamlKevin Jones1-1/+1
2016-11-01Add Neutron network type and VLAN ranges to network-environment.yamlDan Sneddon1-0/+5
2016-08-25Merge "Updates and fixes to NIC config template routes"Jenkins1-12/+16
2016-08-12Remove NeutronEnableTunnelling from templatesBob Fournier1-0/+2
2016-08-08Updates and fixes to NIC config template routesDan Sneddon1-12/+16
2016-05-06Merge "Fixes ovs bonding option"Jenkins1-1/+1
2016-04-28Fixes ovs bonding optionRamon Acedo1-1/+1
2016-03-31Updates ControlPlaneSubnetCidr to be a stringRhys Oxenham1-1/+1
2016-02-24Add a sample network-environment.yaml file to environmentsDan Sneddon1-0/+50
{ color: #f8f8f2 } /* Name.Variable.Magic */ .highlight .il { color: #ae81ff } /* Literal.Number.Integer.Long */ } @media (prefers-color-scheme: light) { .highlight .hll { background-color: #ffffcc } .highlight .c { color: #888888 } /* Comment */ .highlight .err { color: #a61717; background-color: #e3d2d2 } /* Error */ .highlight .k { color: #008800; font-weight: bold } /* Keyword */ .highlight .ch { color: #888888 } /* Comment.Hashbang */ .highlight .cm { color: #888888 } /* Comment.Multiline */ .highlight .cp { color: #cc0000; font-weight: bold } /* Comment.Preproc */ .highlight .cpf { color: #888888 } /* Comment.PreprocFile */ .highlight .c1 { color: #888888 } /* Comment.Single */ .highlight .cs { color: #cc0000; font-weight: bold; background-color: #fff0f0 } /* Comment.Special */ .highlight .gd { color: #000000; background-color: #ffdddd } /* Generic.Deleted */ .highlight .ge { font-style: italic } /* Generic.Emph */ .highlight .gr { color: #aa0000 } /* Generic.Error */ .highlight .gh { color: #333333 } /* Generic.Heading */ .highlight .gi { color: #000000; background-color: #ddffdd } /* Generic.Inserted */ .highlight .go { color: #888888 } /* Generic.Output */ .highlight .gp { color: #555555 } /* Generic.Prompt */ .highlight .gs { font-weight: bold } /* Generic.Strong */ .highlight .gu { color: #666666 } /* Generic.Subheading */ .highlight .gt { color: #aa0000 } /* Generic.Traceback */ .highlight .kc { color: #008800; font-weight: bold } /* Keyword.Constant */ .highlight .kd { color: #008800; font-weight: bold } /* Keyword.Declaration */ .highlight .kn { color: #008800; font-weight: bold } /* Keyword.Namespace */ .highlight .kp { color: #008800 } /* Keyword.Pseudo */ .highlight .kr { color: #008800; font-weight: bold } /* Keyword.Reserved */ .highlight .kt { color: #888888; font-weight: bold } /* Keyword.Type */ .highlight .m { color: #0000DD; font-weight: bold } /* Literal.Number */ .highlight .s { color: #dd2200; background-color: #fff0f0 } /* Literal.String */ .highlight .na { color: #336699 } /* Name.Attribute */ .highlight .nb { color: #003388 } /* Name.Builtin */ .highlight .nc { color: #bb0066; font-weight: bold } /* Name.Class */ .highlight .no { color: #003366; font-weight: bold } /* Name.Constant */ .highlight .nd { color: #555555 } /* Name.Decorator */ .highlight .ne { color: #bb0066; font-weight: bold } /* Name.Exception */ .highlight .nf { color: #0066bb; font-weight: bold } /* Name.Function */ .highlight .nl { color: #336699; font-style: italic } /* Name.Label */ .highlight .nn { color: #bb0066; font-weight: bold } /* Name.Namespace */ .highlight .py { color: #336699; font-weight: bold } /* Name.Property */ .highlight .nt { color: #bb0066; font-weight: bold } /* Name.Tag */ .highlight .nv { color: #336699 } /* Name.Variable */ .highlight .ow { color: #008800 } /* Operator.Word */ .highlight .w { color: #bbbbbb } /* Text.Whitespace */ .highlight .mb { color: #0000DD; font-weight: bold } /* Literal.Number.Bin */ .highlight .mf { color: #0000DD; font-weight: bold } /* Literal.Number.Float */ .highlight .mh { color: #0000DD; font-weight: bold } /* Literal.Number.Hex */ .highlight .mi { color: #0000DD; font-weight: bold } /* Literal.Number.Integer */ .highlight .mo { color: #0000DD; font-weight: bold } /* Literal.Number.Oct */ .highlight .sa { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Affix */ .highlight .sb { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Backtick */ .highlight .sc { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Char */ .highlight .dl { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Delimiter */ .highlight .sd { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Doc */ .highlight .s2 { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Double */ .highlight .se { color: #0044dd; background-color: #fff0f0 } /* Literal.String.Escape */ .highlight .sh { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Heredoc */ .highlight .si { color: #3333bb; background-color: #fff0f0 } /* Literal.String.Interpol */ .highlight .sx { color: #22bb22; background-color: #f0fff0 } /* Literal.String.Other */ .highlight .sr { color: #008800; background-color: #fff0ff } /* Literal.String.Regex */ .highlight .s1 { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Single */ .highlight .ss { color: #aa6600; background-color: #fff0f0 } /* Literal.String.Symbol */ .highlight .bp { color: #003388 } /* Name.Builtin.Pseudo */ .highlight .fm { color: #0066bb; font-weight: bold } /* Name.Function.Magic */ .highlight .vc { color: #336699 } /* Name.Variable.Class */ .highlight .vg { color: #dd7700 } /* Name.Variable.Global */ .highlight .vi { color: #3333bb } /* Name.Variable.Instance */ .highlight .vm { color: #336699 } /* Name.Variable.Magic */ .highlight .il { color: #0000DD; font-weight: bold } /* Literal.Number.Integer.Long */ }
##############################################################################
# Copyright (c) 2016 Cavium
# Copyright (c) 2016 Enea AB and others.
# 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
##############################################################################

# NOTE: Armband patching consists of:
# - clone upstream repositories to git submodules, tracking remotes;
# - tag each submodule (before patching) with "${A_OPNFV_TAG}-root";
# - apply Armband patches for each submodule;
# - tag each submodule (after patching) with "${OPNFV_TAG}";
# - stage Fuel submodule patches by copying them to Fuel f_repos/patch dir;
# - pass updated repository info to Fuel@OPNFV build system
#   (e.g. FUEL_PLUGIN_ODL_CHANGE="${OPNFV_TAG}") via armband-fuel-config.mk;

# NOTE: Long-term goals (Armband repo should merge with Fuel@OPNFV):
# - all build related changes should affect Fuel@OPNFV, NOT Armband;
# - Armband make/build system should only handle patching non-Fuel submodules,
#   and then invoke Fuel@OPNFV's patch & build system;
# - Fuel@OPNFV is made aware of an Armband type build by passing
#   the "ARMBAND_BASE" env var;

SHELL = /bin/sh

export ARMBAND_BASE  := $(shell pwd)
export OPNFV_GIT_SHA := $(shell git rev-parse HEAD)
export REVSTATE

include armband-fuel-config.mk

all: release

# Fetch & update git submodules, checkout remote HEAD
.PHONY: submodules-init
submodules-init: .submodules-init

.submodules-init:
	@if [ -n "${ARMBAND_TRACK_REMOTES}" ]; then \
		git submodule update --init --remote 2>/dev/null; \
	else \
		git submodule update --init 2>/dev/null; \
	fi
	@ln -sf ${A_FUEL_BASE}/ci/clean_cache.sh ${ARMBAND_BASE}/ci/clean_cache.sh
	@touch $@

# Clean any changes made to submodules, checkout Armband root commit
.PHONY: submodules-clean
submodules-clean: .submodules-init
	@test ! -d ${F_REPOS_DIR} || $(MAKE) fuel-patches-clean
	@git submodule -q foreach ' \
		git am -q --abort 2>/dev/null; \
		git checkout -q -f ${A_OPNFV_TAG}-root 2>/dev/null; \
		git branch -q -D opnfv-armband 2>/dev/null; \
		git tag | grep ${A_OPNFV_TAG} | xargs git tag -d > /dev/null 2>&1; \
		git reset -q --hard HEAD; \
		git clean -xdff'
	@rm -f .submodules-patched

# Generate patches from submodules
.PHONY: patches-export
patches-export: .submodules-init
	@git submodule -q foreach ' \
		SUB_DIR=${A_PATCH_DIR}/$$name; \
		git tag | awk "!/root/ && /${A_OPNFV_TAG}-fuel/" | while read A_TAG; do \
			SUB_FEATURE=`dirname $${A_TAG#${A_OPNFV_TAG}-fuel/}`; \
			echo "`tput setaf 2`== exporting $$name ($$A_TAG)`tput sgr0`"; \
			mkdir -p $$SUB_DIR/$${SUB_FEATURE} && \
			git format-patch --no-signature --ignore-space-at-eol \
				-o $$SUB_DIR/$$SUB_FEATURE -N $$A_TAG-root..$$A_TAG; \
			sed -i -e "1{/From: /!d}" -e "s/[[:space:]]*$$//" \
				$$SUB_DIR/$$SUB_FEATURE/*.patch; \
		done'

# Apply patches from patches/* to respective submodules
.PHONY: patches-import
patches-import: .submodules-init .submodules-patched

.submodules-patched: ${A_PATCHES}
	@$(MAKE) submodules-clean
	@git submodule -q foreach ' \
		SUB_DIR=${A_PATCH_DIR}/$$name; mkdir -p $$SUB_DIR && \
		git tag ${A_OPNFV_TAG}-root && \
		git checkout -q -b opnfv-armband && \
		find $$SUB_DIR -type d | sort | while read p_dir; do \
			SUB_PATCHES=$$(ls $$p_dir/*.patch 2>/dev/null); \
			if [ -n "$$SUB_PATCHES" ]; then \
				SUB_FEATURE=$${p_dir#$$SUB_DIR} \
				SUB_TAG=${A_OPNFV_TAG}-fuel$$SUB_FEATURE/patch; \
				echo "`tput setaf 2`== patching $$name ($$SUB_TAG)`tput sgr0`";\
				git tag $$SUB_TAG-root && git am -3 --whitespace=nowarn \
					--committer-date-is-author-date $$SUB_PATCHES && \
				git tag $$SUB_TAG || exit 1; \
			fi \
		done && \
		git tag ${A_OPNFV_TAG}'
	# Staging Fuel@OPNFV patches
	@ls -d ${F_SUB_DIR}/* 2>/dev/null | while read p_sub_path; do \
		SUB_NAME=`basename $$p_sub_path`; \
		find ${A_PATCH_DIR}/$$SUB_NAME -name '*.patch' 2>/dev/null -exec sh -c '\
			A_PATCH={}; R_PATCH=$${A_PATCH#${A_PATCH_DIR}/}; \
			F_PATCH=${F_PATCH_DIR}/$${0}/armband/$${R_PATCH#$${0}/}; \
			if [ -f $$F_PATCH ]; then \
				echo "`tput setaf 3`* WARN: $$R_PATCH upstream.`tput sgr0`"; \
			else \
				if [ -h $$A_PATCH ]; then \
					echo "`tput setaf 3`* PHONY: $$R_PATCH`tput sgr0`"; \
				else \
					echo "`tput setaf 6`* Staging $$R_PATCH`tput sgr0`"; \
					mkdir -p `dirname $$F_PATCH` && cp $$A_PATCH $$F_PATCH; \
				fi; \
			fi' "$$SUB_NAME" \; || true ; \
	done
	@touch $@

# Pass down debug/clean/deepclean/build to Fuel@OPNFV
.PHONY: clean debug
clean: .submodules-init
debug: fuel-patches-import
clean debug:
	$(MAKE) -e --no-print-directory -C ${F_BUILD_DIR} $@

.PHONY: deepclean
deepclean: clean
	$(MAKE) -e --no-print-directory -C ${F_BUILD_DIR} deepclean
	@git submodule deinit -f .
	@rm -f .submodules*

.PHONY: build
build: patches-import
	$(MAKE) -e --no-print-directory -C ${F_BUILD_DIR} all

.PHONY: release
release: export LC_ALL=en_US.UTF-8
release: build

##############################################################################
# Fuel@OPNFV patch operations - to be used only during development
##############################################################################

# Apply all Fuel@OPNFV patches, including Armband patches
.PHONY: fuel-patches-import
fuel-patches-import: .submodules-patched fuel-patches-clean
	$(MAKE) -e -C ${F_REPOS_DIR} patches-import

# Export Fuel@OPNFV patches, including Armband patches
.PHONY: fuel-patches-export
fuel-patches-export: .submodules-patched
	$(MAKE) -e -C ${F_REPOS_DIR} patches-export
	@ls -d ${F_PATCH_DIR}/* 2>/dev/null | while read p_sub_path; do \
		SUB_NAME=`basename $$p_sub_path`; \
		if [ -d $$p_sub_path/armband ]; then \
			echo "`tput setaf 6`* Pulling $$SUB_NAME patches.`tput sgr0`"; \
			cp -R $$p_sub_path/armband/* ${A_PATCH_DIR}/$$SUB_NAME && \
				rm -rf $$p_sub_path/armband; \
		fi \
	done

.PHONY: fuel-patches-clean
fuel-patches-clean:
	$(MAKE) -e -C ${F_REPOS_DIR} clean