Only re-run 'mkvirtualenv' for backup app, if it doesn't exist
This commit is contained in:
		
							parent
							
								
									775b0eed29
								
							
						
					
					
						commit
						a1af0b131e
					
				
					 1 changed files with 2 additions and 2 deletions
				
			
		|  | @ -78,10 +78,10 @@ def deploy_backup_app(deploy, envname, mkvirtualenv=True, user='rattail', | |||
|         runat = datetime.time(0) # defaults to midnight | ||||
| 
 | ||||
|     # virtualenv | ||||
|     if mkvirtualenv: | ||||
|     envpath = '/srv/envs/{}'.format(envname) | ||||
|     if mkvirtualenv and not exists(envpath): | ||||
|         python.mkvirtualenv(envname, python=python_exe, upgrade_setuptools=False, | ||||
|                             runas_user=user) | ||||
|     envpath = '/srv/envs/{}'.format(envname) | ||||
|     sudo('chown -R {}: {}'.format(user, envpath)) | ||||
|     with cd(envpath): | ||||
|         mkdir('src', owner=user) | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Lance Edgar
						Lance Edgar