Skip to content

Commit

Permalink
feat(cf): Add artifacts for user-defined services
Browse files Browse the repository at this point in the history
Co-Authored-By: Jason Chu <jchu@pivotal.io>
  • Loading branch information
Jammy Louie and jasonjchu committed Feb 1, 2019
1 parent 1f97215 commit 064e5b3
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 064e5b3

Please sign in to comment.