Skip to content

Commit

Permalink
feat(ui): Sign-post IDE set-up. Closes argoproj#3720 (argoproj#3723)
Browse files Browse the repository at this point in the history
  • Loading branch information
alexec committed Aug 14, 2020
1 parent 21dc23d commit a38101f
Show file tree
Hide file tree
Showing 18 changed files with 46 additions and 16 deletions.
4 changes: 2 additions & 2 deletions cmd/argo/commands/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ See %s`, help.ArgoSever),
// InsecureSkipVerify will not impact the TLS listener. It is needed for the server to speak to itself for GRPC.
tlsConfig = &tls.Config{Certificates: []tls.Certificate{cer}, InsecureSkipVerify: true}
} else {
log.Warn("You are running in insecure mode. Learn how to enable transport layer security: https://github.com/argoproj/argo/blob/master/docs/tls.md")
log.Warn("You are running in insecure mode. Learn how to enable transport layer security: https://argoproj.github.io/argo/tls/")
}

modes := auth.Modes{}
Expand All @@ -92,7 +92,7 @@ See %s`, help.ArgoSever),
errors.CheckError(err)
}
if reflect.DeepEqual(modes, auth.Modes{auth.Server: true}) {
log.Warn("You are running without client authentication. Learn how to enable client authentication: https://github.com/argoproj/argo/blob/master/docs/argo-server-auth-mode.md")
log.Warn("You are running without client authentication. Learn how to enable client authentication: https://argoproj.github.io/argo/argo-server-auth-mode/")
}

opts := apiserver.ArgoServerOpts{
Expand Down
Binary file added docs/assets/ide-step-1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/assets/ide-step-2.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/assets/ide-step-3.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
27 changes: 27 additions & 0 deletions docs/ide-setup.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
# IDE Set-Up

## How To Use CRD Validation With Your Editor

Use either VS Code or Kubernetes and load the full Custom Resource Definitions (CRDs) into an IDE that support CRD validation (e.g IntelliJ, VS Code).

CRD URLs:

* [ClusterWorkflowTemplate](https://raw.githubusercontent.com/argoproj/argo/master/manifests/base/crds/full/argoproj.io_clusterworkflowtemplates.yaml)
* [WorkflowTemplate](https://raw.githubusercontent.com/argoproj/argo/master/manifests/base/crds/full/argoproj.io_workflowtemplates.yaml)
* [CronWorkflow](https://raw.githubusercontent.com/argoproj/argo/master/manifests/base/crds/full/argoproj.io_cronworkflows.yaml)
* [Workflow](https://raw.githubusercontent.com/argoproj/argo/master/manifests/base/crds/full/argoproj.io_clusterworkflowtemplates.yaml)

### IntelliJ

Install the Kubernetes plugin:

![Step 1](assets/ide-step-1.png)

Add the CRD URLs to the Kubernetes configuration panel (choose “IDE” for the scope):

![Step 2](assets/ide-step-2.png)

Finally, open your CRDs and verify no errors appear, example:

![Step 3](assets/ide-step-3.png)

2 changes: 1 addition & 1 deletion docs/workflow-controller-configmap.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -214,7 +214,7 @@ data:
# SSO Configuration for the Argo server.
# You must also start argo server with `--auth-mode sso`.
# https://github.com/argoproj/argo/blob/master/docs/argo-server-auth-mode.md
# https://argoproj.github.io/argo/argo-server-auth-mode/
sso:
# This is the root URL of the OIDC provider (required).
issuer: https://issuer.root.url/
Expand Down
2 changes: 1 addition & 1 deletion examples/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -317,7 +317,7 @@ The [FailFast](./dag-disable-failFast.yaml) flag default is `true`, if set to `

**Note:**
You will need to configure an artifact repository to run this example.
[Configuring an artifact repository here](https://github.com/argoproj/argo/blob/master/docs/configure-artifact-repository.md).
[Configuring an artifact repository here](https://argoproj.github.io/argo/configure-artifact-repository/).

When running workflows, it is very common to have steps that generate or consume artifacts. Often, the output artifacts of one step may be used as input artifacts to a subsequent step.

Expand Down
2 changes: 1 addition & 1 deletion manifests/quick-start/base/workflow-role.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# https://github.com/argoproj/argo/blob/master/docs/workflow-rbac.md
# https://argoproj.github.io/argo/workflow-rbac/
apiVersion: rbac.authorization.k8s.io/v1
kind: Role
metadata:
Expand Down
3 changes: 3 additions & 0 deletions mkdocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ nav:
- workflow-creator.md
- synchronization.md
- workflow-of-workflows.md
- memoization.md
# all other topics, including API access
- Advanced:
- workflow-requirements.md
Expand All @@ -58,6 +59,7 @@ nav:
- resuming-workflow-via-automation.md
- async-pattern.md
- security.md
- ide-setup.md
- Examples: examples/README.md
- Field Reference: fields.md
- CLI Reference:
Expand Down Expand Up @@ -88,6 +90,7 @@ nav:
- argo lint: cli/argo_lint.md
- argo list: cli/argo_list.md
- argo logs: cli/argo_logs.md
- argo node: cli/argo_node.md
- argo resubmit: cli/argo_resubmit.md
- argo resume: cli/argo_resume.md
- argo retry: cli/argo_retry.md
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ export class ArchivedWorkflowList extends BasePage<RouteComponentProps<any>, Sta
if (!this.state.workflows) {
return <Loading />;
}
const learnMore = <a href='https://github.com/argoproj/argo/blob/master/docs/workflow-archive.md'>Learn more</a>;
const learnMore = <a href='https://argoproj.github.io/argo/workflow-archive/'>Learn more</a>;
if (this.state.workflows.length === 0) {
return (
<ZeroState title='No archived workflows'>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ export class ClusterWorkflowTemplateList extends BasePage<RouteComponentProps<an
if (!this.state.templates) {
return <Loading />;
}
const learnMore = <a href='https://github.com/argoproj/argo/blob/master/docs/cluster-workflow-templates.md'>Learn more</a>;
const learnMore = <a href='https://argoproj.github.io/argo/cluster-workflow-templates/'>Learn more</a>;
if (this.state.templates.length === 0) {
return (
<ZeroState title='No cluster workflow templates'>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ export class CronWorkflowList extends BasePage<RouteComponentProps<any>, State>
if (!this.state.cronWorkflows) {
return <Loading />;
}
const learnMore = <a href='https://github.com/argoproj/argo/blob/master/docs/cron-workflows.md'>Learn more</a>;
const learnMore = <a href='https://argoproj.github.io/argo/cron-workflows/'>Learn more</a>;
if (this.state.cronWorkflows.length === 0) {
return (
<ZeroState title='No cron workflows'>
Expand Down
2 changes: 1 addition & 1 deletion ui/src/app/login/components/login.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ export const Login = () => (
</h3>
<p>It may not be necessary to be logged in to use Argo Workflows, it depends on how it is configured.</p>
<p>
<a href='https://github.com/argoproj/argo/blob/master/docs/argo-server-auth-mode.md'>Learn more</a>.
<a href='https://argoproj.github.io/argo/argo-server-auth-mode/'>Learn more</a>.
</p>
</div>

Expand Down
3 changes: 1 addition & 2 deletions ui/src/app/shared/components/cost-optimisation-nudge.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,7 @@ export class CostOptimisationNudge extends React.Component<Props, State> {
return (
!this.state.closed && (
<Notice>
<i className='fa fa-money-bill-alt status-icon--pending' /> {this.props.children}{' '}
<a href='https://github.com/argoproj/argo/blob/master/docs/cost-optimisation.md'>Learn more</a>
<i className='fa fa-money-bill-alt status-icon--pending' /> {this.props.children} <a href='https://argoproj.github.io/argo/cost-optimisation/'>Learn more</a>
<span className='fa-pull-right'>
<a onClick={() => this.close()}>
<i className='fa fa-times' />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -165,8 +165,9 @@ export class ResourceEditor<T> extends React.Component<Props<T>, State> {
private renderWarning() {
return (
<div style={{marginTop: '1em'}}>
<i className='fa fa-info-circle' /> Note:{' '}
{this.state.lang === 'json' ? <>Full auto-completion enabled</> : <>Basic completion for YAML. Switch to JSON for full auto-completion.</>}
<i className='fa fa-info-circle' />{' '}
{this.state.lang === 'json' ? <>Full auto-completion enabled.</> : <>Basic completion for YAML. Switch to JSON for full auto-completion.</>}{' '}
<a href='https://argoproj.github.io/argo/ide-setup/'>Learn how to get auto-completion in your IDE.</a>
</div>
);
}
Expand Down
2 changes: 1 addition & 1 deletion ui/src/app/shared/resources-duration.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ export class ResourcesDuration extends React.Component<Props> {
Object.entries(this.props.resourcesDuration)
.map(([resource, duration]) => formatDuration(duration, 1) + '*(' + denominator(resource) + ' ' + resource + ')')
.join(',')}{' '}
<a href='https://github.com/argoproj/argo/blob/master/docs/resource-duration.md'>
<a href='https://argoproj.github.io/argo/resource-duration/'>
<i className='fa fa-info-circle' />
</a>
</>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ export class WorkflowTemplateList extends BasePage<RouteComponentProps<any>, Sta
if (!this.state.templates) {
return <Loading />;
}
const learnMore = <a href='https://github.com/argoproj/argo/blob/master/docs/workflow-templates.md'>Learn more</a>;
const learnMore = <a href='https://argoproj.github.io/argo/workflow-templates/'>Learn more</a>;
if (this.state.templates.length === 0) {
return (
<ZeroState title='No workflow templates'>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ export class WorkflowDrawer extends React.Component<WorkflowDrawerProps, Workflo
<div className='workflow-drawer__resourcesDuration'>
<div className='workflow-drawer__title'>
RESOURCES DURATION&nbsp;
<a href='https://github.com/argoproj/argo/blob/master/docs/resource-duration.md' target='_blank'>
<a href='https://argoproj.github.io/argo/resource-duration/' target='_blank'>
<i className='fas fa-info-circle' />
</a>
</div>
Expand Down

0 comments on commit a38101f

Please sign in to comment.