aboutsummaryrefslogtreecommitdiffstats
path: root/mcp/scripts/globals.sh
AgeCommit message (Collapse)AuthorFilesLines
2018-09-20[infra] Bind mas01 mcpcontrol DHCP to MAAS_IPAlexandru Avadanii1-0/+1
Bring back MAAS_IP global env var and use it for mas01 VM IP addr in mcpcontrol network to prevent salt minion signature change. Partially-reverts: b666bc50 Change-Id: I5c7668393fe66287bd3ecdc75dd3195d5a89a8f3 Signed-off-by: Alexandru Avadanii <Alexandru.Avadanii@enea.com>
2018-09-11[cleanup] FN VMs: Fold user-data templatesAlexandru Avadanii1-2/+1
While at it, retire obsolete MAAS_IP global variable and let mas01 VM get a DHCP address from virsh-managed mcpcontrol network. Change-Id: Ifd85dbcab10894a5d0d675d37f0c35f09776d9b4 Signed-off-by: Alexandru Avadanii <Alexandru.Avadanii@enea.com>
2018-02-06[virtual] Add missing ODL dhcp_intAlexandru Avadanii1-0/+5
- add missing network definitions for ODL node's 1st interface; - add missing comments for `notify` global functions; - fix or silence shellcheck issues; JIRA: FUEL-322 Change-Id: Ie3341d29ab12ddf432db603ad865259afb54714e Signed-off-by: Alexandru Avadanii <Alexandru.Avadanii@enea.com>
2018-02-05[PDF] Switch to generate_config, unify templatesAlexandru Avadanii1-1/+5
- move bash template handling (previously expanded via `envsubst`) to lib.sh; - move j2 template handling to lib.sh; - move virsh network templates to 'mcp/scripts/virsh_net' subdir; - switch virsh network templates from `envsubst` expansion to j2 and leverage generate_config.py, similar to PDF Fuel installer adapter; - add relevant runtime env vars (e.g. SALT_MASTER, MAAS_IP) on the fly to PDF, to consume them in templates like params coming from PDF; - parameterize virsh network definitions based on PDF (mgmt, public); JIRA: FUEL-322 Change-Id: Ib94e78fc4f25797b9354a0552e884104da5d0003 Signed-off-by: Alexandru Avadanii <Alexandru.Avadanii@enea.com>
2018-02-05deploy.sh: Move notify() to globals.shAlexandru Avadanii1-0/+28
Extend `notify` to 4 variants: - notify_i = inline (no newline) colored output; - notify = `notify_i` + trailing '\n'; - notify_n = `notify` + extra '\n' before and after; - notify_e = `notify` + stderr output + exit; This allows us to remove '\n' and cleanup the code a bit. While at it, fix some 'NOTE' messages going to stderr instead of stdout. Change-Id: I682e3344ae9e307c4a68ab31c7766bc91b12ee58 Signed-off-by: Alexandru Avadanii <Alexandru.Avadanii@enea.com>
2017-12-11[baremetal] Move all MaaS PXE net config to PDFAlexandru Avadanii1-3/+0
- s/opnfv_maas_pxe_/opnfv_infra_maas_pxe_/g to align with other vars; - patches: pharos: Add MaaS PXE network to installer adapter; - runtime.yml{,.template}: move to installer adapter, update pod_config.yml example; - drop MAAS_PXE_NETWORK global env var, now read strictly from PDF; JIRA: FUEL-313 Change-Id: I46d7510bd53fba7890c411d36bc28fd6ff6f3648 Signed-off-by: Alexandru Avadanii <Alexandru.Avadanii@enea.com>
2017-12-08[baremetal] PDF: Use net_admin for MaaS PXE netAlexandru Avadanii1-1/+1
While at it, fix another small issue where a variable (parameters__param_opnfv_maas_pxe_address) was used without being populated (defined in 'runtime.yml', which is not read using `parse_yaml`, like the scenario yml or the PDF expanded class, pod_config.yml). JIRA: FUEL-313 Change-Id: Iee88601d5420f55572bf90c8cf330afbedfb2e21 Signed-off-by: Alexandru Avadanii <Alexandru.Avadanii@enea.com>
2017-10-15states: Break on error, retry states up to 5 timesAlexandru Avadanii1-1/+2
While applying scenario states, break on error, and retry failed state up to 5 times. Apply the same behavior for `salt.sh`. Add new deploy parameter, '-D', backed up by 'CI_DEBUG' env var, which gates deploy sh scripts logging (set -x). Also extend '-f' deploy parameter, allowing it to be specified more than once; the first occurence will skip infra VM creation, but still sync reclass & other config from local repo, while a second occurence will also disable config sync. To prevent glusterfs client state from failing due to non-existent nova user/group, move it after nova:compute's nova state is applied. Change-Id: I234e126e16be0e133d878957bd88fed946955de8 Signed-off-by: Alexandru Avadanii <Alexandru.Avadanii@enea.com>
2017-10-03ci/deploy.sh: Move global vars to separate fileAlexandru Avadanii1-0/+21
log.sh should also work as standalone script, so factor out global variables from <ci/deploy.sh> into <mcp/scripts/globals.sh>, which should be sourced by log.sh when required variables are not set. Change-Id: I5a5bb85ee5835f567d6910b11c137d95e2147714 Signed-off-by: Alexandru Avadanii <Alexandru.Avadanii@enea.com>