Fix broken links and enable Github action link checker (#344)

Resolves https://github.com/crossplane/docs/issues/333
Resolves https://github.com/crossplane/docs/issues/340
This commit is contained in:
Pete Lumbis 2023-02-10 15:11:29 -05:00 committed by GitHub
parent b8a54f32a2
commit 5fc58271c1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
26 changed files with 94 additions and 62 deletions

32
.github/workflows/link-checker.yml vendored Normal file
View File

@ -0,0 +1,32 @@
name: Run htmltest and validate links
on:
pull_request:
paths:
- 'content/**'
- 'themes/**'
# Allows manual workflow run (must in default branch to work)
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout the docs repo
uses: actions/checkout@v3
- name: Setup Hugo
uses: peaceiris/actions-hugo@v2
with:
hugo-version: '0.109.0'
extended: true
- name: Build
# Set to env=dev so SCSS isn't required.
run: hugo --environment development
- name: Run htmltest
uses: wjdp/htmltest-action@master
with:
config: ./utils/htmltest/.htmltest.yml

View File

@ -31,7 +31,7 @@ the Crossplane docs CSS.
Extract and run Hugo with `hugo server`.
Hugo builds the website and launch a local web server on
[http://localhost:1313](http://localhost:1313).
<a href="http://localhost:1313" data-proofer-ignore>http://localhost:1313</a>.
Any changes made are instantly reflected on the local web server. You
don't need to restart Hugo.

View File

@ -28,9 +28,9 @@ Commonmark and `GFM` are extensions to the
The docs support standard Markdown for images, links and tables, Crossplane
recommend using the custom shortcodes to provide a better experience for readers.
* [Images]({{< ref "#Images">}})
* [Links]({{< ref "#Links">}})
* [Tables]({{< ref "#Tables" >}})
* [Images]({{< ref "#images">}})
* [Links]({{< ref "#links">}})
* [Tables]({{< ref "#tables" >}})
## Hide long outputs
Some outputs may be verbose or only relevant for

View File

@ -331,7 +331,7 @@ This way even a tight integration of Crossplane in to [Cloudfoundry] is possible
[OCI images]: https://github.com/opencontainers/image-spec
[EKS Cluster]: https://marketplace.upbound.io/providers/crossplane-contrib/provider-aws/latest/resources/eks.aws.crossplane.io/Cluster/v1beta1
[provider-aws]: https://marketplace.upbound.io/providers/crossplane-contrib/provider-aws
[provider-helm]: https://marketplace.upbound.io/providerscrossplane-contrib/provider-helm
[provider-helm]: https://marketplace.upbound.io/providers/crossplane-contrib/provider-helm/
[Open Service Broker API]: https://github.com/openservicebrokerapi/servicebroker
[Crossplane Service Broker]: https://github.com/vshn/crossplane-service-broker
[Cloudfoundry]: https://www.cloudfoundry.org/

View File

@ -5,20 +5,19 @@ weight: 102
A Managed Resource (MR) is Crossplane's representation of a resource in an
external system - most commonly a cloud provider. Managed Resources are
opinionated, Crossplane Resource Model ([XRM][term-xrm]) compliant Kubernetes
Custom Resources that are installed by a Crossplane [provider].
opinionated, Crossplane Resource Model ([XRM]({{<ref "../concepts/terminology">}})) compliant Kubernetes
Custom Resources that are installed by a Crossplane [provider]({{<ref "providers" >}}).
For example, `RDSInstance` in the AWS Provider corresponds to an actual RDS
Instance in AWS. There is a one-to-one relationship and the changes on managed
resources are reflected directly on the corresponding resource in the provider.
Similarly, the `Database` types in the SQL provider represent a PostgreSQL or
MySQL database. You can browse [API Reference][api-reference] to discover all
available managed resources.
MySQL database.
Managed Resources are the building blocks of Crossplane. They're designed to be
_composed_ into higher level, opinionated Custom Resources that Crossplane calls
Composite Resources or XRs - not used directly. See the
[Composition][composition] documentation for more information.
[Composition]({{<ref "composition" >}}) documentation for more information.
## Syntax
@ -448,8 +447,7 @@ the values that are fetched from the provider.
Note that if a resource has required fields, you must fill those fields or the
creation of the managed resource will be rejected. So, in those cases, you will
need to enter the name of the resource as well as the required fields as
indicated in the [API Reference][api-reference] documentation.
need to enter the name of the resource as well as the required fields.
## Backup and Restore
@ -464,14 +462,10 @@ fields are there and those are enough to import a resource. The tool you're
using needs to store `annotations` and `spec` fields, which most tools do
including Velero.
[term-xrm]: "terminology"
[rds]: https://aws.amazon.com/rds/
[cloudsql]: https://cloud.google.com/sql
[composition]: "composition"
[api-versioning]: https://kubernetes.io/docs/reference/using-api/#api-versioning#api-versioning
[velero]: https://velero.io/
[api-reference]: "../api-docs"
[provider]: "providers"
[issue-727]: https://github.com/crossplane/crossplane/issues/727
[issue-1143]: https://github.com/crossplane/crossplane/issues/1143
[managed-api-patterns]: https://github.com/crossplane/crossplane/blob/release-1.10/design/one-pager-managed-resource-api-design.md

View File

@ -177,7 +177,7 @@ provided constraints.
> Dependency resolution is a `beta` feature and depends on the `v1beta1`
> [`Lock` API][lock-api].
For an example Configuration package, see [getting-started-with-gcp].
For an example Configuration package, see [getting-started-with-gcp](https://github.com/crossplane/docs/tree/master/content/v1.10/snippets/package/gcp).
To build a Configuration package, navigate to the package root directory and
execute the following command:
@ -493,7 +493,6 @@ by [pre-pulling images] onto nodes in the cluster.
[provider-docs]: https://doc.crds.dev/github.com/crossplane/crossplane/meta.pkg.crossplane.io/Provider/v1
[configuration-docs]: https://doc.crds.dev/github.com/crossplane/crossplane/meta.pkg.crossplane.io/Configuration/v1
[lock-api]: https://doc.crds.dev/github.com/crossplane/crossplane/pkg.crossplane.io/Lock/v1beta1
[getting-started-with-gcp]: https://github.com/crossplane/crossplane/tree/master/docs/snippets/package/gcp
[specification]: https://github.com/Masterminds/semver#basic-comparisons
[composition]: {{<ref "composition" >}}
[IAM Roles for Service Accounts]: https://docs.aws.amazon.com/eks/latest/userguide/iam-roles-for-service-accounts.html

View File

@ -65,8 +65,7 @@ spec:
You can see that there is a reference to a key in a specific `Secret`. The value
of that key should contain the credentials that the controller will use. The
documentation of each provider should give you an idea of how that credentials
blob should look like. See [Getting Started][getting-started] guide for more
details.
blob should look like.
The following is an example usage of AWS `ProviderConfig`, referenced by a
`RDSInstance`:
@ -90,7 +89,7 @@ will attempt to use a `ProviderConfig` named `default`.
<!-- Named Links -->
[getting-started]: "../getting-started/install-configure"
[Google Cloud Platform (GCP) Service Account]: "../cloud-providers/gcp/gcp-provider"
[Microsoft Azure Service Principal]: "../cloud-providers/azure/azure-provider"
[Amazon Web Services (AWS) IAM User]: "../cloud-providers/aws/aws-provider"

View File

@ -37,10 +37,10 @@ This table provides a summary of Crossplane components and their roles.
{{< table "table table-hover table-sm">}}
| Component | Abbreviation | Scope | Summary |
| --- | --- | --- | ---- |
| [Provider]({{<ref "#Provider">}}) | | cluster | Creates new Kubernetes Custom Resource Definitions for an external service. |
| [ProviderConfig]({{<ref "#ProviderConfig">}}) | `PC` | cluster | Applies settings for a _Provider_. |
| [Managed Resource]({{<ref "#managed-resource">}}) | `MR` | cluster | A provider resource created and managed by Crossplane inside the Kubernetes cluster. |
| [Composition]({{<ref "#composition">}}) | | cluster | A template for creating multiple _managed resources_ at once. |
| [Provider]({{<ref "#providers">}}) | | cluster | Creates new Kubernetes Custom Resource Definitions for an external service. |
| [ProviderConfig]({{<ref "#provider-configurations">}}) | `PC` | cluster | Applies settings for a _Provider_. |
| [Managed Resource]({{<ref "#managed-resources">}}) | `MR` | cluster | A provider resource created and managed by Crossplane inside the Kubernetes cluster. |
| [Composition]({{<ref "#compositions">}}) | | cluster | A template for creating multiple _managed resources_ at once. |
| [Composite Resources]({{<ref "#composite-resources" >}}) | `XR` | cluster | Uses a _Composition_ template to create multiple _managed resources_ as a single Kubernetes object. |
| [Composite Resource Definitions]({{<ref "#composite-resource-definitions" >}}) | `XRD` | cluster | Defines the API schema for _Composite Resources_ and _Claims_ |
| [Claims]({{<ref "#claims" >}}) | `XC` | namespace | Like a _Composite Resource_, but namespace scoped. |

View File

@ -177,7 +177,7 @@ provided constraints.
> Dependency resolution is a `beta` feature and depends on the `v1beta1`
> [`Lock` API][lock-api].
For an example Configuration package, see [getting-started-with-gcp].
For an example Configuration package, see [getting-started-with-gcp](https://github.com/crossplane/docs/tree/master/content/v1.10/snippets/package/gcp).
To build a Configuration package, navigate to the package root directory and
execute the following command:
@ -491,7 +491,6 @@ by [pre-pulling images] onto nodes in the cluster.
[provider-docs]: https://doc.crds.dev/github.com/crossplane/crossplane/meta.pkg.crossplane.io/Provider/v1
[configuration-docs]: https://doc.crds.dev/github.com/crossplane/crossplane/meta.pkg.crossplane.io/Configuration/v1
[lock-api]: https://doc.crds.dev/github.com/crossplane/crossplane/pkg.crossplane.io/Lock/v1beta1
[getting-started-with-gcp]: https://github.com/crossplane/crossplane/tree/master/docs/snippets/package/gcp
[specification]: https://github.com/Masterminds/semver#basic-comparisons
[composition]: {{<ref "composition" >}}
[IAM Roles for Service Accounts]: https://docs.aws.amazon.com/eks/latest/userguide/iam-roles-for-service-accounts.html

View File

@ -87,7 +87,7 @@ hugo server
```
Hugo builds the website and launch a local web server on
[http://localhost:1313](http://localhost:1313).
<a href="http://localhost:1313" data-proofer-ignore>http://localhost:1313</a>.
Any changes made are instantly reflected on the local web server. You
don't need to restart Hugo.

View File

@ -71,8 +71,13 @@ the convention of `release-[minor-semver]`.
If this is the first ever release branch being created in a repo (uncommon), you
should also set up branch protection rules for the `release-*` pattern. You can
find existing examples in the [Crossplane repo
settings](https://github.com/crossplane/crossplane/settings/branches).
find existing examples in the
<a href="https://github.com/crossplane/crossplane/settings/branches" data-proofer-ignore>Crossplane repo
settings</a>.
{{<hint "important">}}
Only maintainers can view the repo settings.
{{< /hint >}}
At this point, the `HEAD` commit in the release branch will be our release
candidate. The build pipeline will automatically be started due to the create

View File

@ -388,7 +388,7 @@ spec:
```
```console
curl -OL https://raw.githubusercontent.com/crossplane/crossplane/release-1.10/docs/snippets/package/gcp/composition.yaml
curl -OL https://raw.githubusercontent.com/crossplane/docs/master/content/v1.10/snippets/package/gcp/composition.yaml
```
{{< /tab >}}
@ -589,7 +589,7 @@ spec:
```
```console
curl -OL https://raw.githubusercontent.com/crossplane/crossplane/release-1.10/docs/snippets/package/gcp/crossplane.yaml
curl -OL https://raw.githubusercontent.com/crossplane/docs/master/content/v1.10/snippets/package/gcp/crossplane.yaml
kubectl crossplane build configuration
```

View File

@ -331,7 +331,7 @@ This way even a tight integration of Crossplane in to [Cloudfoundry] is possible
[OCI images]: https://github.com/opencontainers/image-spec
[EKS Cluster]: https://marketplace.upbound.io/providers/crossplane-contrib/provider-aws/latest/resources/eks.aws.crossplane.io/Cluster/v1beta1
[provider-aws]: https://marketplace.upbound.io/providers/crossplane-contrib/provider-aws
[provider-helm]: https://marketplace.upbound.io/providerscrossplane-contrib/provider-helm
[provider-helm]: https://marketplace.upbound.io/providers/crossplane-contrib/provider-helm/
[Open Service Broker API]: https://github.com/openservicebrokerapi/servicebroker
[Crossplane Service Broker]: https://github.com/vshn/crossplane-service-broker
[Cloudfoundry]: https://www.cloudfoundry.org/

View File

@ -5,20 +5,19 @@ weight: 102
A Managed Resource (MR) is Crossplane's representation of a resource in an
external system - most commonly a cloud provider. Managed Resources are
opinionated, Crossplane Resource Model ([XRM][term-xrm]) compliant Kubernetes
Custom Resources that are installed by a Crossplane [provider].
opinionated, Crossplane Resource Model ([XRM]({{<ref "../concepts/terminology">}})) compliant Kubernetes
Custom Resources that are installed by a Crossplane [provider]({{<ref "providers" >}}).
For example, `RDSInstance` in the AWS Provider corresponds to an actual RDS
Instance in AWS. There is a one-to-one relationship and the changes on managed
resources are reflected directly on the corresponding resource in the provider.
Similarly, the `Database` types in the SQL provider represent a PostgreSQL or
MySQL database. You can browse [API Reference][api-reference] to discover all
available managed resources.
MySQL database.
Managed Resources are the building blocks of Crossplane. They're designed to be
_composed_ into higher level, opinionated Custom Resources that Crossplane calls
Composite Resources or XRs - not used directly. See the
[Composition][composition] documentation for more information.
[Composition]({{<ref "composition" >}}) documentation for more information.
## Syntax
@ -448,8 +447,7 @@ the values that are fetched from the provider.
Note that if a resource has required fields, you must fill those fields or the
creation of the managed resource will be rejected. So, in those cases, you will
need to enter the name of the resource as well as the required fields as
indicated in the [API Reference][api-reference] documentation.
need to enter the name of the resource as well as the required fields.
## Backup and Restore
@ -464,14 +462,10 @@ fields are there and those are enough to import a resource. The tool you're
using needs to store `annotations` and `spec` fields, which most tools do
including Velero.
[term-xrm]: {{<ref "terminology" >}}
[rds]: https://aws.amazon.com/rds/
[cloudsql]: https://cloud.google.com/sql
[composition]: {{<ref "composition" >}}
[api-versioning]: https://kubernetes.io/docs/reference/using-api/#api-versioning#api-versioning
[velero]: https://velero.io/
[api-reference]: https://doc.crds.dev/github.com/crossplane/crossplane
[provider]: {{<ref "providers" >}}
[issue-727]: https://github.com/crossplane/crossplane/issues/727
[issue-1143]: https://github.com/crossplane/crossplane/issues/1143
[managed-api-patterns]: https://github.com/crossplane/crossplane/blob/release-1.10/design/one-pager-managed-resource-api-design.md

View File

@ -177,7 +177,7 @@ provided constraints.
> Dependency resolution is a `beta` feature and depends on the `v1beta1`
> [`Lock` API][lock-api].
For an example Configuration package, see [getting-started-with-gcp].
For an example Configuration package, see [getting-started-with-gcp](https://github.com/crossplane/docs/tree/master/content/v1.10/snippets/package/gcp).
To build a Configuration package, navigate to the package root directory and
execute the following command:
@ -493,7 +493,6 @@ by [pre-pulling images] onto nodes in the cluster.
[provider-docs]: https://doc.crds.dev/github.com/crossplane/crossplane/meta.pkg.crossplane.io/Provider/v1
[configuration-docs]: https://doc.crds.dev/github.com/crossplane/crossplane/meta.pkg.crossplane.io/Configuration/v1
[lock-api]: https://doc.crds.dev/github.com/crossplane/crossplane/pkg.crossplane.io/Lock/v1beta1
[getting-started-with-gcp]: https://github.com/crossplane/crossplane/tree/master/docs/snippets/package/gcp
[specification]: https://github.com/Masterminds/semver#basic-comparisons
[composition]: {{<ref "composition" >}}
[IAM Roles for Service Accounts]: https://docs.aws.amazon.com/eks/latest/userguide/iam-roles-for-service-accounts.html

View File

@ -65,8 +65,7 @@ spec:
You can see that there is a reference to a key in a specific `Secret`. The value
of that key should contain the credentials that the controller will use. The
documentation of each provider should give you an idea of how that credentials
blob should look like. See [Getting Started][getting-started] guide for more
details.
blob should look like.
The following is an example usage of AWS `ProviderConfig`, referenced by a
`RDSInstance`:

View File

@ -37,10 +37,10 @@ This table provides a summary of Crossplane components and their roles.
{{< table "table table-hover table-sm">}}
| Component | Abbreviation | Scope | Summary |
| --- | --- | --- | ---- |
| [Provider]({{<ref "#Provider">}}) | | cluster | Creates new Kubernetes Custom Resource Definitions for an external service. |
| [ProviderConfig]({{<ref "#ProviderConfig">}}) | `PC` | cluster | Applies settings for a _Provider_. |
| [Managed Resource]({{<ref "#managed-resource">}}) | `MR` | cluster | A provider resource created and managed by Crossplane inside the Kubernetes cluster. |
| [Composition]({{<ref "#composition">}}) | | cluster | A template for creating multiple _managed resources_ at once. |
| [Provider]({{<ref "#providers">}}) | | cluster | Creates new Kubernetes Custom Resource Definitions for an external service. |
| [ProviderConfig]({{<ref "#provider-configurations">}}) | `PC` | cluster | Applies settings for a _Provider_. |
| [Managed Resource]({{<ref "#managed-resources">}}) | `MR` | cluster | A provider resource created and managed by Crossplane inside the Kubernetes cluster. |
| [Composition]({{<ref "#compositions">}}) | | cluster | A template for creating multiple _managed resources_ at once. |
| [Composite Resources]({{<ref "#composite-resources" >}}) | `XR` | cluster | Uses a _Composition_ template to create multiple _managed resources_ as a single Kubernetes object. |
| [Composite Resource Definitions]({{<ref "#composite-resource-definitions" >}}) | `XRD` | cluster | Defines the API schema for _Composite Resources_ and _Claims_ |
| [Claims]({{<ref "#claims" >}}) | `XRC` | namespace | Like a _Composite Resource_, but namespace scoped. |

View File

@ -72,8 +72,13 @@ the convention of `release-[minor-semver]`.
If this is the first ever release branch being created in a repo (uncommon), you
should also set up branch protection rules for the `release-*` pattern. You can
find existing examples in the [Crossplane repo
settings](https://github.com/crossplane/crossplane/settings/branches).
find existing examples in the
<a href="https://github.com/crossplane/crossplane/settings/branches" data-proofer-ignore>Crossplane repo
settings</a>.
{{<hint "important">}}
Only maintainers can view the repo settings.
{{< /hint >}}
At this point, the `HEAD` commit in the release branch will be our release
candidate. The build pipeline will automatically be started due to the create

View File

@ -388,7 +388,7 @@ spec:
```
```console
curl -OL https://raw.githubusercontent.com/crossplane/crossplane/release-1.9/docs/snippets/package/gcp/composition.yaml
curl -OL https://raw.githubusercontent.com/crossplane/docs/master/content/v1.9/snippets/package/gcp/composition.yaml
```
{{< /tab >}}
@ -589,7 +589,7 @@ spec:
```
```console
curl -OL https://raw.githubusercontent.com/crossplane/crossplane/release-1.9/docs/snippets/package/gcp/crossplane.yaml
curl -OL https://raw.githubusercontent.com/crossplane/docs/master/content/v1.9/snippets/package/gcp/crossplane.yaml
kubectl crossplane build configuration
```

View File

@ -332,7 +332,7 @@ This way even a tight integration of Crossplane in to [Cloudfoundry] is possible
[OCI images]: https://github.com/opencontainers/image-spec
[EKS Cluster]: https://marketplace.upbound.io/providers/crossplane-contrib/provider-aws/latest/resources/eks.aws.crossplane.io/Cluster/v1beta1
[provider-aws]: https://marketplace.upbound.io/providers/crossplane-contrib/provider-aws
[provider-helm]: https://marketplace.upbound.io/providerscrossplane-contrib/provider-helm
[provider-helm]: https://marketplace.upbound.io/providers/crossplane-contrib/provider-helm/
[Open Service Broker API]: https://github.com/openservicebrokerapi/servicebroker
[Crossplane Service Broker]: https://github.com/vshn/crossplane-service-broker
[Cloudfoundry]: https://www.cloudfoundry.org/

View File

@ -15,7 +15,7 @@
<div class="bd-content mt-3">
<p>
Crossplane may change or drop this feature at any time. <br />
For more information read the <a href="https://docs.crossplane.io/latest/reference/feature-lifecycle/">Crossplane feature lifecycle</a>.
For more information read the <a href="{{.Site.BaseURL}}knowledge-base/guides/feature-lifecycle/" >}}'>Crossplane feature lifecycle</a>.
</p>
</div>
</div>

View File

@ -1,6 +1,6 @@
<div class="section-container container pe-0 pt-1">
<div class="nav-container">
<a href="{{.Site.BaseURL}}contribute" class="d-inline-flex align-items-center">
<a href="{{.Site.BaseURL}}contribute/" class="d-inline-flex align-items-center">
Contributing Guide
</a>
</div>

View File

@ -1,6 +1,6 @@
<div class="section-container container pe-0 pt-1">
<div class="nav-container">
<a href="{{.Site.BaseURL}}knowledge-base" class="d-inline-flex align-items-center">
<a href="{{.Site.BaseURL}}knowledge-base/" class="d-inline-flex align-items-center">
Knowledge Base
</a>
</div>

View File

@ -1,6 +1,6 @@
<div class="section-container container pe-0 pt-1">
<div class="nav-container">
<a href="{{.Site.BaseURL}}v{{.Site.Params.latest}}" class="d-inline-flex align-items-center">
<a href="{{.Site.BaseURL}}v{{.Site.Params.latest}}/" class="d-inline-flex align-items-center">
User Documentation
</a>
</div>

View File

@ -11,5 +11,5 @@
</script>
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@docsearch/css@3" media="print" onload="this.media='all'"/>
<link rel="preconnect" href="https://9UXKYX61NK-dsn.algolia.net" crossorigin />
<link rel="preconnect" href="https://9UXKYX61NK-dsn.algolia.net" crossorigin data-proofer-ignore/>

View File

@ -0,0 +1,7 @@
DirectoryPath: "public"
# The version drop down has an empty hash.
# This doesn't cause errors
IgnoreInternalEmptyHash: true
CheckExternal: false
IgnoreURLs:
- "github.com/crossplane/docs/tree/master/content/(.*).md" # Ignore the links to "view this source"