Skip to content
This repository has been archived by the owner on Jan 12, 2024. It is now read-only.

Commit

Permalink
Make generate Vault config command re-runnable, so that it can replac…
Browse files Browse the repository at this point in the history
…e current config
  • Loading branch information
fieldju committed Dec 12, 2016
1 parent e5cd7c3 commit ef8cfff
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 7 deletions.
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -16,4 +16,4 @@

group=com.nike
artifactId=cerberus-lifecycle-cli
version=0.10.0
version=0.11.0
Original file line number Diff line number Diff line change
Expand Up @@ -65,18 +65,12 @@ public void run(final CreateVaultConfigCommand command) {
public boolean isRunnable(final CreateVaultConfigCommand command) {
boolean isRunnable = true;
final String vaultAclToken = configStore.getVaultAclToken();
final boolean hasVaultConfig = configStore.hasVaultConfig();

if (StringUtils.isBlank(vaultAclToken)) {
logger.error("No Vault ACL token present for Consul, please generate that first.");
isRunnable = false;
}

if (hasVaultConfig) {
logger.error("Vault configuration present for specified environment, use the update command.");
isRunnable = false;
}

return isRunnable;
}
}

0 comments on commit ef8cfff

Please sign in to comment.