Skip to content

Commit

Permalink
feat(cf): Add artifacts for user-defined services (#6468)
Browse files Browse the repository at this point in the history
Co-Authored-By: Jason Chu <jchu@pivotal.io>
  • Loading branch information
2 people authored and jkschneider committed Feb 6, 2019
1 parent 7848f7a commit 5f81f40
Showing 1 changed file with 22 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,17 @@ export class CloudfoundryDeployServiceStageConfig extends React.Component<
};
this.setState({ type: 'userProvided' });
break;
case 'userProvidedArtifact':
this.props.stage.manifest = {
service: '',
syslogDrainUrl: '',
routeServiceUrl: '',
tags: [],
credentialsMap: {},
type: 'userProvidedArtifact',
};
this.setState({ type: 'userProvidedArtifact' });
break;
}
};

Expand Down Expand Up @@ -185,6 +196,7 @@ export class CloudfoundryDeployServiceStageConfig extends React.Component<
/>
);
break;
case 'userProvidedArtifact':
case 'artifact':
const artifact = manifest as { type: string } & ICloudfoundryServiceManifestArtifactSource;
manifestInput = (
Expand Down Expand Up @@ -246,6 +258,16 @@ export class CloudfoundryDeployServiceStageConfig extends React.Component<
User-Provided
</label>
</div>
<div className="radio radio-inline">
<label>
<input
type="radio"
checked={manifest.type === 'userProvidedArtifact'}
onChange={() => this.manifestTypeUpdated('userProvidedArtifact')}
/>{' '}
User-Provided-Artifact
</label>
</div>
</StageConfigField>
{manifestInput}
{manifest.type !== 'userProvided' && (
Expand Down

0 comments on commit 5f81f40

Please sign in to comment.