summaryrefslogtreecommitdiffstats
path: root/patches/opnfv-fuel/0005-deploy.py-add-a-time-stamp-to-the-new-ISO-image.patch
blob: d87171562a2346f7ed28a923dd9004dce619d45b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
: Copyright (c) 2017 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
::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
From: Josep Puigdemont <josep.puigdemont@enea.com>
Date: Tue, 17 May 2016 14:40:48 +0200
Subject: [PATCH] deploy.py: add a time stamp to the new ISO image

Add a time stamp to the newly create ISO image. This is to prevent name
collisions with other ISO images from earlier deploy jobs.

Ideally this will only be a temporary need, and releng will provide with
unique IDs for each job that we can use to this effect.

Signed-off-by: Josep Puigdemont <josep.puigdemont@enea.com>
---
 deploy/deploy.py | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/deploy/deploy.py b/deploy/deploy.py
index 041ba2f..cebef97 100755
--- a/deploy/deploy.py
+++ b/deploy/deploy.py
@@ -13,6 +13,7 @@ import os
 import io
 import re
 import sys
+import time
 import yaml
 import signal
 import netaddr
@@ -100,8 +101,9 @@ class AutoDeploy(object):

     def install_fuel_master(self):
         log('Install Fuel Master')
-        new_iso = ('%s/deploy-%s'
-                   % (self.tmp_dir, os.path.basename(self.iso_file)))
+        stamp = time.strftime("%Y%m%d%H%M%S")
+        new_iso = ('%s/deploy-%s-%s'
+                   % (self.tmp_dir, stamp, os.path.basename(self.iso_file)))
         self.patch_iso(new_iso)
         self.iso_file = new_iso
         self.install_iso()
ar l-Scalar-Plain">string default: 'regionOne' description: Keystone region for endpoint outputs: role_data: description: Role data for the Panko role. value: service_name: panko_base config_settings: panko::db::database_connection: list_join: - '' - - {get_param: [EndpointMap, MysqlInternal, protocol]} - '://panko:' - {get_param: PankoPassword} - '@' - {get_param: [EndpointMap, MysqlInternal, host]} - '/panko' - '?bind_address=' - "%{hiera('tripleo::profile::base::database::mysql::client_bind_address')}" panko::debug: {get_param: Debug} panko::auth::auth_url: {get_param: [EndpointMap, KeystoneInternal, uri_no_suffix] } panko::keystone::authtoken::project_name: 'service' panko::keystone::authtoken::password: {get_param: PankoPassword} panko::keystone::authtoken::auth_uri: {get_param: [EndpointMap, KeystoneInternal, uri] } panko::keystone::authtoken::auth_url: { get_param: [EndpointMap, KeystoneAdmin, uri_no_suffix] } panko::auth::auth_password: {get_param: PankoPassword} panko::auth::auth_region: 'regionOne' panko::auth::auth_tenant_name: 'service' service_config_settings: keystone: panko::keystone::auth::public_url: {get_param: [EndpointMap, PankoPublic, uri]} panko::keystone::auth::internal_url: {get_param: [EndpointMap, PankoInternal, uri]} panko::keystone::auth::admin_url: {get_param: [EndpointMap, PankoAdmin, uri]} panko::keystone::auth::password: {get_param: PankoPassword} panko::keystone::auth::region: {get_param: KeystoneRegion} panko::keystone::auth::tenant: 'service' mysql: panko::db::mysql::user: panko panko::db::mysql::password: {get_param: PankoPassword} panko::db::mysql::host: {get_param: [EndpointMap, MysqlInternal, host_nobrackets]} panko::db::mysql::dbname: panko panko::db::mysql::allowed_hosts: - '%' - "%{hiera('mysql_bind_host')}"