@backstage/plugin-kubernetes-cluster 0.0.28-next.1 → 0.0.28
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +9 -0
- package/dist/Router.esm.js.map +1 -1
- package/dist/components/ApiResources/ApiResources.esm.js.map +1 -1
- package/dist/components/ApiResources/useApiResources.esm.js.map +1 -1
- package/dist/components/ClusterOverview/ClusterOverview.esm.js.map +1 -1
- package/dist/components/ClusterOverview/useCluster.esm.js.map +1 -1
- package/dist/components/KubernetesClusterContent/KubernetesClusterContent.esm.js.map +1 -1
- package/dist/components/KubernetesClusterErrorContext/KubernetesClusterErrorContext.esm.js +1 -1
- package/dist/components/KubernetesClusterErrorContext/KubernetesClusterErrorContext.esm.js.map +1 -1
- package/dist/components/Nodes/Nodes.esm.js.map +1 -1
- package/dist/components/Nodes/useNodes.esm.js.map +1 -1
- package/dist/plugin.esm.js.map +1 -1
- package/dist/translation.esm.js.map +1 -1
- package/package.json +10 -10
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,14 @@
|
|
|
1
1
|
# @backstage/plugin-kubernetes-cluster
|
|
2
2
|
|
|
3
|
+
## 0.0.28
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Updated dependencies
|
|
8
|
+
- @backstage/core-components@0.17.5
|
|
9
|
+
- @backstage/plugin-catalog-react@1.20.0
|
|
10
|
+
- @backstage/plugin-kubernetes-react@0.5.10
|
|
11
|
+
|
|
3
12
|
## 0.0.28-next.1
|
|
4
13
|
|
|
5
14
|
### Patch Changes
|
package/dist/Router.esm.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Router.esm.js","sources":["../src/Router.tsx"],"sourcesContent":["/*\n * Copyright 2020 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { Entity } from '@backstage/catalog-model';\nimport {\n useEntity,\n MissingAnnotationEmptyState,\n} from '@backstage/plugin-catalog-react';\nimport { Route, Routes } from 'react-router-dom';\nimport { ANNOTATION_KUBERNETES_API_SERVER } from '@backstage/plugin-kubernetes-common';\nimport { KubernetesClusterContent } from './components/KubernetesClusterContent';\n\n/**\n *\n *\n * @public\n */\nexport const isKubernetesClusterAvailable = (entity: Entity) =>\n Boolean(entity.metadata.annotations?.[ANNOTATION_KUBERNETES_API_SERVER]);\n\n/**\n *\n *\n * @public\n */\nexport const Router = () => {\n const { entity } = useEntity();\n\n if (isKubernetesClusterAvailable(entity)) {\n return (\n <Routes>\n <Route path=\"/\" element={<KubernetesClusterContent />} />\n </Routes>\n );\n }\n\n return (\n <>\n <MissingAnnotationEmptyState\n annotation={ANNOTATION_KUBERNETES_API_SERVER}\n />\n </>\n );\n};\n"],"names":[],"mappings":";;;;;;
|
|
1
|
+
{"version":3,"file":"Router.esm.js","sources":["../src/Router.tsx"],"sourcesContent":["/*\n * Copyright 2020 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { Entity } from '@backstage/catalog-model';\nimport {\n useEntity,\n MissingAnnotationEmptyState,\n} from '@backstage/plugin-catalog-react';\nimport { Route, Routes } from 'react-router-dom';\nimport { ANNOTATION_KUBERNETES_API_SERVER } from '@backstage/plugin-kubernetes-common';\nimport { KubernetesClusterContent } from './components/KubernetesClusterContent';\n\n/**\n *\n *\n * @public\n */\nexport const isKubernetesClusterAvailable = (entity: Entity) =>\n Boolean(entity.metadata.annotations?.[ANNOTATION_KUBERNETES_API_SERVER]);\n\n/**\n *\n *\n * @public\n */\nexport const Router = () => {\n const { entity } = useEntity();\n\n if (isKubernetesClusterAvailable(entity)) {\n return (\n <Routes>\n <Route path=\"/\" element={<KubernetesClusterContent />} />\n </Routes>\n );\n }\n\n return (\n <>\n <MissingAnnotationEmptyState\n annotation={ANNOTATION_KUBERNETES_API_SERVER}\n />\n </>\n );\n};\n"],"names":[],"mappings":";;;;;;AA8BO,MAAM,4BAAA,GAA+B,CAAC,MAAA,KAC3C,OAAA,CAAQ,OAAO,QAAA,CAAS,WAAA,GAAc,gCAAgC,CAAC;AAOlE,MAAM,SAAS,MAAM;AAC1B,EAAA,MAAM,EAAE,MAAA,EAAO,GAAI,SAAA,EAAU;AAE7B,EAAA,IAAI,4BAAA,CAA6B,MAAM,CAAA,EAAG;AACxC,IAAA,uBACE,GAAA,CAAC,MAAA,EAAA,EACC,QAAA,kBAAA,GAAA,CAAC,KAAA,EAAA,EAAM,IAAA,EAAK,KAAI,OAAA,kBAAS,GAAA,CAAC,wBAAA,EAAA,EAAyB,CAAA,EAAI,CAAA,EACzD,CAAA;AAAA,EAEJ;AAEA,EAAA,uBACE,GAAA,CAAA,QAAA,EAAA,EACE,QAAA,kBAAA,GAAA;AAAA,IAAC,2BAAA;AAAA,IAAA;AAAA,MACC,UAAA,EAAY;AAAA;AAAA,GACd,EACF,CAAA;AAEJ;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ApiResources.esm.js","sources":["../../../src/components/ApiResources/ApiResources.tsx"],"sourcesContent":["/*\n * Copyright 2023 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport { useApiResources } from './useApiResources';\nimport { useCallback, useEffect } from 'react';\nimport { useEntity } from '@backstage/plugin-catalog-react';\nimport { Table, TableColumn } from '@backstage/core-components';\nimport type { IAPIGroup } from '@kubernetes-models/apimachinery/apis/meta/v1';\nimport { useKubernetesClusterError } from '../KubernetesClusterErrorContext/KubernetesClusterErrorContext';\nimport { makeStyles } from '@material-ui/core/styles';\n\nconst useStyles = makeStyles(theme => ({\n empty: {\n padding: theme.spacing(2),\n display: 'flex',\n justifyContent: 'center',\n },\n}));\n\nconst defaultColumns: TableColumn<IAPIGroup>[] = [\n {\n title: 'Name',\n highlight: true,\n render: (apiGroup: IAPIGroup) => {\n return apiGroup.name;\n },\n },\n {\n title: 'Preferred Version',\n highlight: true,\n render: (apiGroup: IAPIGroup) => {\n return apiGroup.preferredVersion?.groupVersion;\n },\n },\n];\n\nexport const ApiResources = () => {\n const classes = useStyles();\n const { entity } = useEntity();\n const { setError } = useKubernetesClusterError();\n const setErrorCallback = useCallback(setError, [setError]);\n const { value, error, loading } = useApiResources({\n clusterName: entity.metadata.name,\n });\n\n useEffect(() => {\n if (error) {\n setErrorCallback(error.message);\n }\n }, [error, setErrorCallback]);\n\n return (\n <Table\n title=\"API Resources\"\n options={{ paging: true, search: false, emptyRowsWhenPaging: false }}\n isLoading={!value && loading}\n data={value?.groups ?? []}\n emptyContent={\n <div className={classes.empty}>\n {error !== undefined\n ? 'Error loading API Resources'\n : 'No API Resources found'}\n </div>\n }\n columns={defaultColumns}\n />\n );\n};\n"],"names":[],"mappings":";;;;;;;;AAuBA,MAAM,SAAA,GAAY,WAAW,
|
|
1
|
+
{"version":3,"file":"ApiResources.esm.js","sources":["../../../src/components/ApiResources/ApiResources.tsx"],"sourcesContent":["/*\n * Copyright 2023 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport { useApiResources } from './useApiResources';\nimport { useCallback, useEffect } from 'react';\nimport { useEntity } from '@backstage/plugin-catalog-react';\nimport { Table, TableColumn } from '@backstage/core-components';\nimport type { IAPIGroup } from '@kubernetes-models/apimachinery/apis/meta/v1';\nimport { useKubernetesClusterError } from '../KubernetesClusterErrorContext/KubernetesClusterErrorContext';\nimport { makeStyles } from '@material-ui/core/styles';\n\nconst useStyles = makeStyles(theme => ({\n empty: {\n padding: theme.spacing(2),\n display: 'flex',\n justifyContent: 'center',\n },\n}));\n\nconst defaultColumns: TableColumn<IAPIGroup>[] = [\n {\n title: 'Name',\n highlight: true,\n render: (apiGroup: IAPIGroup) => {\n return apiGroup.name;\n },\n },\n {\n title: 'Preferred Version',\n highlight: true,\n render: (apiGroup: IAPIGroup) => {\n return apiGroup.preferredVersion?.groupVersion;\n },\n },\n];\n\nexport const ApiResources = () => {\n const classes = useStyles();\n const { entity } = useEntity();\n const { setError } = useKubernetesClusterError();\n const setErrorCallback = useCallback(setError, [setError]);\n const { value, error, loading } = useApiResources({\n clusterName: entity.metadata.name,\n });\n\n useEffect(() => {\n if (error) {\n setErrorCallback(error.message);\n }\n }, [error, setErrorCallback]);\n\n return (\n <Table\n title=\"API Resources\"\n options={{ paging: true, search: false, emptyRowsWhenPaging: false }}\n isLoading={!value && loading}\n data={value?.groups ?? []}\n emptyContent={\n <div className={classes.empty}>\n {error !== undefined\n ? 'Error loading API Resources'\n : 'No API Resources found'}\n </div>\n }\n columns={defaultColumns}\n />\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AAAA,IAAC,KAAA;AAAA,IAAA;AAAA,MACC,KAAA,EAAM,eAAA;AAAA,MACN,SAAS,EAAE,MAAA,EAAQ,MAAM,MAAA,EAAQ,KAAA,EAAO,qBAAqB,KAAA,EAAM;AAAA,MACnE,SAAA,EAAW,CAAC,KAAA,IAAS,OAAA;AAAA,MACrB,IAAA,EAAM,KAAA,EAAO,MAAA,IAAU,EAAC;AAAA,MACxB,YAAA,sBACG,KAAA,EAAA,EAAI,SAAA,EAAW,QAAQ,KAAA,EACrB,QAAA,EAAA,KAAA,KAAU,MAAA,GACP,6BAAA,GACA,wBAAA,EACN,CAAA;AAAA,MAEF,OAAA,EAAS;AAAA;AAAA,GACX;AAEJ;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useApiResources.esm.js","sources":["../../../src/components/ApiResources/useApiResources.ts"],"sourcesContent":["/*\n * Copyright 2023 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport useAsync from 'react-use/esm/useAsync';\n\nimport { useApi } from '@backstage/core-plugin-api';\nimport { kubernetesApiRef } from '@backstage/plugin-kubernetes-react';\nimport type { IAPIGroupList } from '@kubernetes-models/apimachinery/apis/meta/v1';\n\n/**\n * Arguments for useApiResources\n *\n * @public\n */\nexport interface ApiResourcesOptions {\n clusterName: string;\n}\n\n/**\n * Retrieves the logs for the given pod\n *\n * @public\n */\nexport const useApiResources = ({ clusterName }: ApiResourcesOptions) => {\n const kubernetesApi = useApi(kubernetesApiRef);\n return useAsync(async () => {\n return await kubernetesApi\n .proxy({\n clusterName,\n path: '/apis',\n })\n .then(r => {\n return r.json() as Promise<IAPIGroupList>;\n });\n }, [clusterName]);\n};\n"],"names":[],"mappings":";;;;AAmCO,MAAM,
|
|
1
|
+
{"version":3,"file":"useApiResources.esm.js","sources":["../../../src/components/ApiResources/useApiResources.ts"],"sourcesContent":["/*\n * Copyright 2023 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport useAsync from 'react-use/esm/useAsync';\n\nimport { useApi } from '@backstage/core-plugin-api';\nimport { kubernetesApiRef } from '@backstage/plugin-kubernetes-react';\nimport type { IAPIGroupList } from '@kubernetes-models/apimachinery/apis/meta/v1';\n\n/**\n * Arguments for useApiResources\n *\n * @public\n */\nexport interface ApiResourcesOptions {\n clusterName: string;\n}\n\n/**\n * Retrieves the logs for the given pod\n *\n * @public\n */\nexport const useApiResources = ({ clusterName }: ApiResourcesOptions) => {\n const kubernetesApi = useApi(kubernetesApiRef);\n return useAsync(async () => {\n return await kubernetesApi\n .proxy({\n clusterName,\n path: '/apis',\n })\n .then(r => {\n return r.json() as Promise<IAPIGroupList>;\n });\n }, [clusterName]);\n};\n"],"names":[],"mappings":";;;;AAmCO,MAAM,eAAA,GAAkB,CAAC,EAAE,WAAA,EAAY,KAA2B;AACvE,EAAA,MAAM,aAAA,GAAgB,OAAO,gBAAgB,CAAA;AAC7C,EAAA,OAAO,SAAS,YAAY;AAC1B,IAAA,OAAO,MAAM,cACV,KAAA,CAAM;AAAA,MACL,WAAA;AAAA,MACA,IAAA,EAAM;AAAA,KACP,CAAA,CACA,IAAA,CAAK,CAAA,CAAA,KAAK;AACT,MAAA,OAAO,EAAE,IAAA,EAAK;AAAA,IAChB,CAAC,CAAA;AAAA,EACL,CAAA,EAAG,CAAC,WAAW,CAAC,CAAA;AAClB;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ClusterOverview.esm.js","sources":["../../../src/components/ClusterOverview/ClusterOverview.tsx"],"sourcesContent":["/*\n * Copyright 2023 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport { useCallback, useEffect } from 'react';\nimport { InfoCard, StructuredMetadataTable } from '@backstage/core-components';\nimport { useEntity } from '@backstage/plugin-catalog-react';\nimport { useCluster } from './useCluster';\nimport Skeleton from '@material-ui/lab/Skeleton';\nimport { Theme, createStyles, makeStyles } from '@material-ui/core/styles';\nimport { useKubernetesClusterError } from '../KubernetesClusterErrorContext/KubernetesClusterErrorContext';\n\nconst useStyles = makeStyles((_theme: Theme) =>\n createStyles({\n root: {\n height: '100%',\n },\n }),\n);\n\nexport const ClusterOverview = () => {\n const classes = useStyles();\n const { entity } = useEntity();\n const { value, loading, error } = useCluster({\n clusterName: entity.metadata.name,\n });\n const { setError } = useKubernetesClusterError();\n const setErrorCallback = useCallback(setError, [setError]);\n useEffect(() => {\n if (error) {\n setErrorCallback(error.message);\n }\n }, [error, setErrorCallback]);\n\n return (\n <InfoCard title=\"Cluster Overview\" className={classes.root}>\n {!value && loading && (\n <>\n <Skeleton height=\"35rem\" />\n </>\n )}\n {value && (\n <StructuredMetadataTable\n metadata={{\n name: value.name,\n 'Backstage auth provider': value.authProvider,\n 'OIDC Token Provider': value.oidcTokenProvider ?? 'N/A',\n 'Dashboard Link': value.dashboardUrl ?? 'N/A',\n }}\n options={{ nestedValuesAsYaml: true }}\n />\n )}\n </InfoCard>\n );\n};\n"],"names":[],"mappings":";;;;;;;;;AAuBA,MAAM,
|
|
1
|
+
{"version":3,"file":"ClusterOverview.esm.js","sources":["../../../src/components/ClusterOverview/ClusterOverview.tsx"],"sourcesContent":["/*\n * Copyright 2023 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport { useCallback, useEffect } from 'react';\nimport { InfoCard, StructuredMetadataTable } from '@backstage/core-components';\nimport { useEntity } from '@backstage/plugin-catalog-react';\nimport { useCluster } from './useCluster';\nimport Skeleton from '@material-ui/lab/Skeleton';\nimport { Theme, createStyles, makeStyles } from '@material-ui/core/styles';\nimport { useKubernetesClusterError } from '../KubernetesClusterErrorContext/KubernetesClusterErrorContext';\n\nconst useStyles = makeStyles((_theme: Theme) =>\n createStyles({\n root: {\n height: '100%',\n },\n }),\n);\n\nexport const ClusterOverview = () => {\n const classes = useStyles();\n const { entity } = useEntity();\n const { value, loading, error } = useCluster({\n clusterName: entity.metadata.name,\n });\n const { setError } = useKubernetesClusterError();\n const setErrorCallback = useCallback(setError, [setError]);\n useEffect(() => {\n if (error) {\n setErrorCallback(error.message);\n }\n }, [error, setErrorCallback]);\n\n return (\n <InfoCard title=\"Cluster Overview\" className={classes.root}>\n {!value && loading && (\n <>\n <Skeleton height=\"35rem\" />\n </>\n )}\n {value && (\n <StructuredMetadataTable\n metadata={{\n name: value.name,\n 'Backstage auth provider': value.authProvider,\n 'OIDC Token Provider': value.oidcTokenProvider ?? 'N/A',\n 'Dashboard Link': value.dashboardUrl ?? 'N/A',\n }}\n options={{ nestedValuesAsYaml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A,EAAkB,MAAM,YAAA,IAAgB;AAAA,SAC1C;AAAA,QACA,OAAA,EAAS,EAAE,kBAAA,EAAoB,IAAA;AAAK;AAAA;AACtC,GAAA,EAEJ,CAAA;AAEJ;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useCluster.esm.js","sources":["../../../src/components/ClusterOverview/useCluster.ts"],"sourcesContent":["/*\n * Copyright 2023 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport useAsync from 'react-use/esm/useAsync';\n\nimport { useApi } from '@backstage/core-plugin-api';\nimport { kubernetesApiRef } from '@backstage/plugin-kubernetes-react';\n\n/**\n * Arguments for useApiResources\n *\n * @public\n */\nexport interface UseClusterOptions {\n clusterName: string;\n}\n\n/**\n * Retrieves the logs for the given pod\n *\n * @public\n */\nexport const useCluster = ({ clusterName }: UseClusterOptions) => {\n const kubernetesApi = useApi(kubernetesApiRef);\n return useAsync(async () => {\n return await kubernetesApi.getCluster(clusterName);\n }, [clusterName]);\n};\n"],"names":[],"mappings":";;;;AAkCO,MAAM,
|
|
1
|
+
{"version":3,"file":"useCluster.esm.js","sources":["../../../src/components/ClusterOverview/useCluster.ts"],"sourcesContent":["/*\n * Copyright 2023 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport useAsync from 'react-use/esm/useAsync';\n\nimport { useApi } from '@backstage/core-plugin-api';\nimport { kubernetesApiRef } from '@backstage/plugin-kubernetes-react';\n\n/**\n * Arguments for useApiResources\n *\n * @public\n */\nexport interface UseClusterOptions {\n clusterName: string;\n}\n\n/**\n * Retrieves the logs for the given pod\n *\n * @public\n */\nexport const useCluster = ({ clusterName }: UseClusterOptions) => {\n const kubernetesApi = useApi(kubernetesApiRef);\n return useAsync(async () => {\n return await kubernetesApi.getCluster(clusterName);\n }, [clusterName]);\n};\n"],"names":[],"mappings":";;;;AAkCO,MAAM,UAAA,GAAa,CAAC,EAAE,WAAA,EAAY,KAAyB;AAChE,EAAA,MAAM,aAAA,GAAgB,OAAO,gBAAgB,CAAA;AAC7C,EAAA,OAAO,SAAS,YAAY;AAC1B,IAAA,OAAO,MAAM,aAAA,CAAc,UAAA,CAAW,WAAW,CAAA;AAAA,EACnD,CAAA,EAAG,CAAC,WAAW,CAAC,CAAA;AAClB;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"KubernetesClusterContent.esm.js","sources":["../../../src/components/KubernetesClusterContent/KubernetesClusterContent.tsx"],"sourcesContent":["/*\n * Copyright 2023 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport { ApiResources } from '../ApiResources/ApiResources';\nimport Grid from '@material-ui/core/Grid';\nimport Typography from '@material-ui/core/Typography';\nimport { Nodes } from '../Nodes/Nodes';\nimport { ClusterOverview } from '../ClusterOverview';\nimport {\n KubernetesClusterErrorProvider,\n useKubernetesClusterError,\n} from '../KubernetesClusterErrorContext/KubernetesClusterErrorContext';\nimport { WarningPanel } from '@backstage/core-components';\nimport { kubernetesClustersReadPermission } from '@backstage/plugin-kubernetes-common';\nimport { RequirePermission } from '@backstage/plugin-permission-react';\nimport { useTranslationRef } from '@backstage/core-plugin-api/alpha';\nimport { kubernetesClusterTranslationRef } from '../../translation';\n\nconst ContentGrid = () => {\n const { error } = useKubernetesClusterError();\n return (\n <>\n <Grid container>\n {error && (\n <Grid item xs={12}>\n <WarningPanel title=\"Error loading Kubernetes Cluster Plugin\">\n <Typography>{error}</Typography>\n </WarningPanel>\n </Grid>\n )}\n <Grid item xs={6}>\n <ClusterOverview />\n </Grid>\n <Grid item xs={6}>\n <ApiResources />\n </Grid>\n <Grid item xs={12}>\n <Nodes />\n </Grid>\n </Grid>\n </>\n );\n};\n\n/**\n *\n *\n * @public\n */\nexport const KubernetesClusterContent = () => {\n const { t } = useTranslationRef(kubernetesClusterTranslationRef);\n\n return (\n <RequirePermission\n permission={kubernetesClustersReadPermission}\n errorPage={\n <WarningPanel\n title={t('kubernetesClusterContentPage.permissionAlert.title')}\n message={t('kubernetesClusterContentPage.permissionAlert.message')}\n />\n }\n >\n <KubernetesClusterErrorProvider>\n <ContentGrid />\n </KubernetesClusterErrorProvider>\n </RequirePermission>\n );\n};\n"],"names":[],"mappings":";;;;;;;;;;;;;AA8BA,MAAM,cAAc,MAAM;AACxB,
|
|
1
|
+
{"version":3,"file":"KubernetesClusterContent.esm.js","sources":["../../../src/components/KubernetesClusterContent/KubernetesClusterContent.tsx"],"sourcesContent":["/*\n * Copyright 2023 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport { ApiResources } from '../ApiResources/ApiResources';\nimport Grid from '@material-ui/core/Grid';\nimport Typography from '@material-ui/core/Typography';\nimport { Nodes } from '../Nodes/Nodes';\nimport { ClusterOverview } from '../ClusterOverview';\nimport {\n KubernetesClusterErrorProvider,\n useKubernetesClusterError,\n} from '../KubernetesClusterErrorContext/KubernetesClusterErrorContext';\nimport { WarningPanel } from '@backstage/core-components';\nimport { kubernetesClustersReadPermission } from '@backstage/plugin-kubernetes-common';\nimport { RequirePermission } from '@backstage/plugin-permission-react';\nimport { useTranslationRef } from '@backstage/core-plugin-api/alpha';\nimport { kubernetesClusterTranslationRef } from '../../translation';\n\nconst ContentGrid = () => {\n const { error } = useKubernetesClusterError();\n return (\n <>\n <Grid container>\n {error && (\n <Grid item xs={12}>\n <WarningPanel title=\"Error loading Kubernetes Cluster Plugin\">\n <Typography>{error}</Typography>\n </WarningPanel>\n </Grid>\n )}\n <Grid item xs={6}>\n <ClusterOverview />\n </Grid>\n <Grid item xs={6}>\n <ApiResources />\n </Grid>\n <Grid item xs={12}>\n <Nodes />\n </Grid>\n </Grid>\n </>\n );\n};\n\n/**\n *\n *\n * @public\n */\nexport const KubernetesClusterContent = () => {\n const { t } = useTranslationRef(kubernetesClusterTranslationRef);\n\n return (\n <RequirePermission\n permission={kubernetesClustersReadPermission}\n errorPage={\n <WarningPanel\n title={t('kubernetesClusterContentPage.permissionAlert.title')}\n message={t('kubernetesClusterContentPage.permissionAlert.message')}\n />\n }\n >\n <KubernetesClusterErrorProvider>\n <ContentGrid />\n </KubernetesClusterErrorProvider>\n </RequirePermission>\n );\n};\n"],"names":[],"mappings":";;;;;;;;;;;;;AA8BA,MAAM,cAAc,MAAM;AACxB,EAAA,MAAM,EAAE,KAAA,EAAM,GAAI,yBAAA,EAA0B;AAC5C,EAAA,uBACE,GAAA,CAAA,QAAA,EAAA,EACE,QAAA,kBAAA,IAAA,CAAC,IAAA,EAAA,EAAK,SAAA,EAA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ime';
|
|
2
|
-
import {
|
|
2
|
+
import { useState, useCallback, createContext, useContext } from 'react';
|
|
3
3
|
|
|
4
4
|
const KubernetesClusterErrorContext = createContext({
|
|
5
5
|
setError: (_) => {
|
package/dist/components/KubernetesClusterErrorContext/KubernetesClusterErrorContext.esm.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"KubernetesClusterErrorContext.esm.js","sources":["../../../src/components/KubernetesClusterErrorContext/KubernetesClusterErrorContext.tsx"],"sourcesContent":["/*\n * Copyright 2023 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n ReactNode,\n createContext,\n useCallback,\n useContext,\n useState,\n} from 'react';\n\nexport interface ErrorContext {\n error?: string;\n setError: (message: string) => void;\n}\n\nexport const KubernetesClusterErrorContext = createContext<ErrorContext>({\n setError: (_: string) => {},\n});\n\nexport interface KubernetesClusterErrorProviderProps {\n children: ReactNode;\n}\n\nexport const KubernetesClusterErrorProvider = ({\n children,\n}: KubernetesClusterErrorProviderProps) => {\n const [error, setError] = useState<string | undefined>(undefined);\n\n const contextValue: ErrorContext = {\n error,\n setError: useCallback((message: string) => setError(message), []),\n };\n\n return (\n <KubernetesClusterErrorContext.Provider value={contextValue}>\n {children}\n </KubernetesClusterErrorContext.Provider>\n );\n};\n\nexport const useKubernetesClusterError = () => {\n return useContext(KubernetesClusterErrorContext);\n};\n"],"names":[],"mappings":";;;AA4BO,MAAM,gCAAgC,
|
|
1
|
+
{"version":3,"file":"KubernetesClusterErrorContext.esm.js","sources":["../../../src/components/KubernetesClusterErrorContext/KubernetesClusterErrorContext.tsx"],"sourcesContent":["/*\n * Copyright 2023 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n ReactNode,\n createContext,\n useCallback,\n useContext,\n useState,\n} from 'react';\n\nexport interface ErrorContext {\n error?: string;\n setError: (message: string) => void;\n}\n\nexport const KubernetesClusterErrorContext = createContext<ErrorContext>({\n setError: (_: string) => {},\n});\n\nexport interface KubernetesClusterErrorProviderProps {\n children: ReactNode;\n}\n\nexport const KubernetesClusterErrorProvider = ({\n children,\n}: KubernetesClusterErrorProviderProps) => {\n const [error, setError] = useState<string | undefined>(undefined);\n\n const contextValue: ErrorContext = {\n error,\n setError: useCallback((message: string) => setError(message), []),\n };\n\n return (\n <KubernetesClusterErrorContext.Provider value={contextValue}>\n {children}\n </KubernetesClusterErrorContext.Provider>\n );\n};\n\nexport const useKubernetesClusterError = () => {\n return useContext(KubernetesClusterErrorContext);\n};\n"],"names":[],"mappings":";;;AA4BO,MAAM,gCAAgC,aAAA,CAA4B;AAAA,EACvE,QAAA,EAAU,CAAC,CAAA,KAAc;AAAA,EAAC;AAC5B,CAAC;AAMM,MAAM,iCAAiC,CAAC;AAAA,EAC7C;AACF,CAAA,KAA2C;AACzC,EAAA,MAAM,CAAC,KAAA,EAAO,QAAQ,CAAA,GAAI,SAA6B,MAAS,CAAA;AAEhE,EAAA,MAAM,YAAA,GAA6B;AAAA,IACjC,KAAA;AAAA,IACA,QAAA,EAAU,YAAY,CAAC,OAAA,KAAoB,SAAS,OAAO,CAAA,EAAG,EAAE;AAAA,GAClE;AAEA,EAAA,2BACG,6BAAA,CAA8B,QAAA,EAA9B,EAAuC,KAAA,EAAO,cAC5C,QAAA,EACH,CAAA;AAEJ;AAEO,MAAM,4BAA4B,MAAM;AAC7C,EAAA,OAAO,WAAW,6BAA6B,CAAA;AACjD;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Nodes.esm.js","sources":["../../../src/components/Nodes/Nodes.tsx"],"sourcesContent":["/*\n * Copyright 2023 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport { useNodes } from './useNodes';\nimport { useCallback, useEffect } from 'react';\nimport { useEntity } from '@backstage/plugin-catalog-react';\nimport {\n StructuredMetadataTable,\n Table,\n TableColumn,\n} from '@backstage/core-components';\nimport { INode } from 'kubernetes-models/v1';\nimport Grid from '@material-ui/core/Grid';\nimport Typography from '@material-ui/core/Typography';\nimport { makeStyles } from '@material-ui/core/styles';\nimport { useKubernetesClusterError } from '../KubernetesClusterErrorContext/KubernetesClusterErrorContext';\nimport { KubernetesDrawer } from '@backstage/plugin-kubernetes-react';\n\nconst useStyles = makeStyles(theme => ({\n empty: {\n padding: theme.spacing(2),\n display: 'flex',\n justifyContent: 'center',\n },\n}));\n\nconst defaultColumns: TableColumn<INode>[] = [\n {\n title: 'Name',\n highlight: true,\n width: 'auto',\n render: (node: INode) => {\n return (\n <KubernetesDrawer\n kubernetesObject={node}\n label={node.metadata?.name ?? 'unknown-node'}\n >\n <Grid container>\n <Grid item xs={12}>\n <Typography variant=\"h5\">Node Info</Typography>\n <StructuredMetadataTable\n metadata={node.status?.nodeInfo ?? {}}\n options={{ nestedValuesAsYaml: true }}\n />\n </Grid>\n <Grid item xs={12}>\n <Typography variant=\"h5\">Addresses</Typography>\n <StructuredMetadataTable\n metadata={\n node.status?.addresses?.reduce((accum, next) => {\n accum[next.type] = next.address;\n return accum;\n }, {} as any) ?? {}\n }\n options={{ nestedValuesAsYaml: true }}\n />\n </Grid>\n <Grid item xs={12}>\n <Typography variant=\"h5\">Taints</Typography>\n <StructuredMetadataTable\n metadata={\n node.spec?.taints?.reduce((accum, next) => {\n accum[`${next.effect}`] = `${next.key} (${next.value})`;\n return accum;\n }, {} as any) ?? {}\n }\n options={{ nestedValuesAsYaml: true }}\n />\n </Grid>\n </Grid>\n </KubernetesDrawer>\n );\n },\n },\n {\n title: 'Schedulable',\n align: 'center',\n width: 'auto',\n render: (node: INode) => {\n if (node.spec?.unschedulable) {\n return '❌';\n }\n return '✅';\n },\n },\n {\n title: 'Status',\n width: 'auto',\n render: (node: INode) => {\n // TODO add an icon\n const readyCondition = node.status?.conditions?.find(c => {\n return c.type === 'Ready';\n });\n if (!readyCondition) {\n return 'Unknown';\n }\n return readyCondition.status === 'True' ? 'Ready' : 'Not Ready';\n },\n },\n {\n title: 'OS',\n width: 'auto',\n render: (node: INode) => {\n return `${node.status?.nodeInfo?.operatingSystem ?? 'unknown'} (${\n node.status?.nodeInfo?.architecture ?? '?'\n })`;\n },\n },\n];\n\nexport const Nodes = () => {\n const classes = useStyles();\n const { entity } = useEntity();\n const { value, error, loading } = useNodes({\n clusterName: entity.metadata.name,\n });\n const { setError } = useKubernetesClusterError();\n const setErrorCallback = useCallback(setError, [setError]);\n useEffect(() => {\n if (error) {\n setErrorCallback(error.message);\n }\n }, [error, setErrorCallback]);\n\n return (\n <Table\n title=\"Nodes\"\n options={{ paging: true, search: false, emptyRowsWhenPaging: false }}\n isLoading={!value && loading}\n data={value?.items ?? []}\n emptyContent={\n <div className={classes.empty}>\n {error !== undefined ? 'Error loading nodes' : 'No nodes found'}\n </div>\n }\n columns={defaultColumns}\n />\n );\n};\n"],"names":[],"mappings":";;;;;;;;;;;AA8BA,MAAM,SAAA,GAAY,WAAW,
|
|
1
|
+
{"version":3,"file":"Nodes.esm.js","sources":["../../../src/components/Nodes/Nodes.tsx"],"sourcesContent":["/*\n * Copyright 2023 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport { useNodes } from './useNodes';\nimport { useCallback, useEffect } from 'react';\nimport { useEntity } from '@backstage/plugin-catalog-react';\nimport {\n StructuredMetadataTable,\n Table,\n TableColumn,\n} from '@backstage/core-components';\nimport { INode } from 'kubernetes-models/v1';\nimport Grid from '@material-ui/core/Grid';\nimport Typography from '@material-ui/core/Typography';\nimport { makeStyles } from '@material-ui/core/styles';\nimport { useKubernetesClusterError } from '../KubernetesClusterErrorContext/KubernetesClusterErrorContext';\nimport { KubernetesDrawer } from '@backstage/plugin-kubernetes-react';\n\nconst useStyles = makeStyles(theme => ({\n empty: {\n padding: theme.spacing(2),\n display: 'flex',\n justifyContent: 'center',\n },\n}));\n\nconst defaultColumns: TableColumn<INode>[] = [\n {\n title: 'Name',\n highlight: true,\n width: 'auto',\n render: (node: INode) => {\n return (\n <KubernetesDrawer\n kubernetesObject={node}\n label={node.metadata?.name ?? 'unknown-node'}\n >\n <Grid container>\n <Grid item xs={12}>\n <Typography variant=\"h5\">Node Info</Typography>\n <StructuredMetadataTable\n metadata={node.status?.nodeInfo ?? {}}\n options={{ nestedValuesAsYaml: true }}\n />\n </Grid>\n <Grid item xs={12}>\n <Typography variant=\"h5\">Addresses</Typography>\n <StructuredMetadataTable\n metadata={\n node.status?.addresses?.reduce((accum, next) => {\n accum[next.type] = next.address;\n return accum;\n }, {} as any) ?? {}\n }\n options={{ nestedValuesAsYaml: true }}\n />\n </Grid>\n <Grid item xs={12}>\n <Typography variant=\"h5\">Taints</Typography>\n <StructuredMetadataTable\n metadata={\n node.spec?.taints?.reduce((accum, next) => {\n accum[`${next.effect}`] = `${next.key} (${next.value})`;\n return accum;\n }, {} as any) ?? {}\n }\n options={{ nestedValuesAsYaml: true }}\n />\n </Grid>\n </Grid>\n </KubernetesDrawer>\n );\n },\n },\n {\n title: 'Schedulable',\n align: 'center',\n width: 'auto',\n render: (node: INode) => {\n if (node.spec?.unschedulable) {\n return '❌';\n }\n return '✅';\n },\n },\n {\n title: 'Status',\n width: 'auto',\n render: (node: INode) => {\n // TODO add an icon\n const readyCondition = node.status?.conditions?.find(c => {\n return c.type === 'Ready';\n });\n if (!readyCondition) {\n return 'Unknown';\n }\n return readyCondition.status === 'True' ? 'Ready' : 'Not Ready';\n },\n },\n {\n title: 'OS',\n width: 'auto',\n render: (node: INode) => {\n return `${node.status?.nodeInfo?.operatingSystem ?? 'unknown'} (${\n node.status?.nodeInfo?.architecture ?? '?'\n })`;\n },\n },\n];\n\nexport const Nodes = () => {\n const classes = useStyles();\n const { entity } = useEntity();\n const { value, error, loading } = useNodes({\n clusterName: entity.metadata.name,\n });\n const { setError } = useKubernetesClusterError();\n const setErrorCallback = useCallback(setError, [setError]);\n useEffect(() => {\n if (error) {\n setErrorCallback(error.message);\n }\n }, [error, setErrorCallback]);\n\n return (\n <Table\n title=\"Nodes\"\n options={{ paging: true, search: false, emptyRowsWhenPaging: false }}\n isLoading={!value && loading}\n data={value?.items ?? []}\n emptyContent={\n <div className={classes.empty}>\n {error !== undefined ? 'Error loading nodes' : 'No nodes found'}\n </div>\n }\n columns={defaultColumns}\n />\n );\n};\n"],"names":[],"mappings":";;;;;;;;;;;AA8BA,MAAM,SAAA,GAAY,WAAW,CAAA,KAAA,MAAU;AAAA,EACrC,KAAA,EAAO;AAAA,IACL,OAAA,EAAS,KAAA,CAAM,OAAA,CAAQ,CAAC,CAAA;AAAA,IACxB,OAAA,EAA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F,CAAA,EAAG,CAAC,KAAA,EAAO,gBAAgB,CAAC,CAAA;AAE5B,EAAA,uBACE,GAAA;AAAA,IAAC,KAAA;AAAA,IAAA;AAAA,MACC,KAAA,EAAM,OAAA;AAAA,MACN,SAAS,EAAE,MAAA,EAAQ,MAAM,MAAA,EAAQ,KAAA,EAAO,qBAAqB,KAAA,EAAM;AAAA,MACnE,SAAA,EAAW,CAAC,KAAA,IAAS,OAAA;AAAA,MACrB,IAAA,EAAM,KAAA,EAAO,KAAA,IAAS,EAAC;AAAA,MACvB,YAAA,sBACG,KAAA,EAAA,EAAI,SAAA,EAAW,QAAQ,KAAA,EACrB,QAAA,EAAA,KAAA,KAAU,MAAA,GAAY,qBAAA,GAAwB,gBAAA,EACjD,CAAA;AAAA,MAEF,OAAA,EAAS;AAAA;AAAA,GACX;AAEJ;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useNodes.esm.js","sources":["../../../src/components/Nodes/useNodes.ts"],"sourcesContent":["/*\n * Copyright 2023 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport useAsync from 'react-use/esm/useAsync';\n\nimport { useApi } from '@backstage/core-plugin-api';\nimport { kubernetesApiRef } from '@backstage/plugin-kubernetes-react';\nimport { NodeList } from 'kubernetes-models/v1';\n\n/**\n * Arguments for useApiResources\n *\n * @public\n */\nexport interface useNodesOptions {\n clusterName: string;\n}\n\n/**\n * Retrieves nodes for a cluster\n *\n * @public\n */\nexport const useNodes = ({ clusterName }: useNodesOptions) => {\n const kubernetesApi = useApi(kubernetesApiRef);\n return useAsync(async () => {\n return await kubernetesApi\n .proxy({\n clusterName,\n path: '/api/v1/nodes?limit=500',\n })\n .then(r => {\n return r.json() as Promise<NodeList>;\n });\n }, [clusterName]);\n};\n"],"names":[],"mappings":";;;;AAmCO,MAAM,
|
|
1
|
+
{"version":3,"file":"useNodes.esm.js","sources":["../../../src/components/Nodes/useNodes.ts"],"sourcesContent":["/*\n * Copyright 2023 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport useAsync from 'react-use/esm/useAsync';\n\nimport { useApi } from '@backstage/core-plugin-api';\nimport { kubernetesApiRef } from '@backstage/plugin-kubernetes-react';\nimport { NodeList } from 'kubernetes-models/v1';\n\n/**\n * Arguments for useApiResources\n *\n * @public\n */\nexport interface useNodesOptions {\n clusterName: string;\n}\n\n/**\n * Retrieves nodes for a cluster\n *\n * @public\n */\nexport const useNodes = ({ clusterName }: useNodesOptions) => {\n const kubernetesApi = useApi(kubernetesApiRef);\n return useAsync(async () => {\n return await kubernetesApi\n .proxy({\n clusterName,\n path: '/api/v1/nodes?limit=500',\n })\n .then(r => {\n return r.json() as Promise<NodeList>;\n });\n }, [clusterName]);\n};\n"],"names":[],"mappings":";;;;AAmCO,MAAM,QAAA,GAAW,CAAC,EAAE,WAAA,EAAY,KAAuB;AAC5D,EAAA,MAAM,aAAA,GAAgB,OAAO,gBAAgB,CAAA;AAC7C,EAAA,OAAO,SAAS,YAAY;AAC1B,IAAA,OAAO,MAAM,cACV,KAAA,CAAM;AAAA,MACL,WAAA;AAAA,MACA,IAAA,EAAM;AAAA,KACP,CAAA,CACA,IAAA,CAAK,CAAA,CAAA,KAAK;AACT,MAAA,OAAO,EAAE,IAAA,EAAK;AAAA,IAChB,CAAC,CAAA;AAAA,EACL,CAAA,EAAG,CAAC,WAAW,CAAC,CAAA;AAClB;;;;"}
|
package/dist/plugin.esm.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"plugin.esm.js","sources":["../src/plugin.ts"],"sourcesContent":["/*\n * Copyright 2020 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n createPlugin,\n createRouteRef,\n createRoutableExtension,\n} from '@backstage/core-plugin-api';\n\nexport const rootCatalogKubernetesClusterRouteRef = createRouteRef({\n id: 'kubernetes-cluster',\n});\n\nexport const kubernetesClusterPlugin = createPlugin({\n id: 'kubernetes-cluster',\n apis: [],\n routes: {\n entityContent: rootCatalogKubernetesClusterRouteRef,\n },\n});\n\n/**\n * Props of EntityKubernetesContent\n *\n * @public\n */\nexport type EntityKubernetesClusterContentProps = {};\n\n/**\n * Props of EntityKubernetesContent\n *\n * @public\n */\nexport const EntityKubernetesClusterContent: (\n props: EntityKubernetesClusterContentProps,\n) => JSX.Element = kubernetesClusterPlugin.provide(\n createRoutableExtension({\n name: 'EntityKubernetesClusterContent',\n component: () => import('./Router').then(m => m.Router),\n mountPoint: rootCatalogKubernetesClusterRouteRef,\n }),\n);\n"],"names":[],"mappings":";;AAqBO,MAAM,uCAAuC,
|
|
1
|
+
{"version":3,"file":"plugin.esm.js","sources":["../src/plugin.ts"],"sourcesContent":["/*\n * Copyright 2020 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport {\n createPlugin,\n createRouteRef,\n createRoutableExtension,\n} from '@backstage/core-plugin-api';\n\nexport const rootCatalogKubernetesClusterRouteRef = createRouteRef({\n id: 'kubernetes-cluster',\n});\n\nexport const kubernetesClusterPlugin = createPlugin({\n id: 'kubernetes-cluster',\n apis: [],\n routes: {\n entityContent: rootCatalogKubernetesClusterRouteRef,\n },\n});\n\n/**\n * Props of EntityKubernetesContent\n *\n * @public\n */\nexport type EntityKubernetesClusterContentProps = {};\n\n/**\n * Props of EntityKubernetesContent\n *\n * @public\n */\nexport const EntityKubernetesClusterContent: (\n props: EntityKubernetesClusterContentProps,\n) => JSX.Element = kubernetesClusterPlugin.provide(\n createRoutableExtension({\n name: 'EntityKubernetesClusterContent',\n component: () => import('./Router').then(m => m.Router),\n mountPoint: rootCatalogKubernetesClusterRouteRef,\n }),\n);\n"],"names":[],"mappings":";;AAqBO,MAAM,uCAAuC,cAAA,CAAe;AAAA,EACjE,EAAA,EAAI;AACN,CAAC;AAEM,MAAM,0BAA0B,YAAA,CAAa;AAAA,EAClD,EAAA,EAAI,oBAAA;AAAA,EACJ,MAAM,EAAC;AAAA,EACP,MAAA,EAAQ;AAAA,IACN,aAAA,EAAe;AAAA;AAEnB,CAAC;AAcM,MAAM,iCAEM,uBAAA,CAAwB,OAAA;AAAA,EACzC,uBAAA,CAAwB;AAAA,IACtB,IAAA,EAAM,gCAAA;AAAA,IACN,SAAA,EAAW,MAAM,OAAO,iBAAU,EAAE,IAAA,CAAK,CAAA,CAAA,KAAK,EAAE,MAAM,CAAA;AAAA,IACtD,UAAA,EAAY;AAAA,GACb;AACH;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"translation.esm.js","sources":["../src/translation.ts"],"sourcesContent":["/*\n * Copyright 2025 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport { createTranslationRef } from '@backstage/core-plugin-api/alpha';\n\n/** @alpha */\nexport const kubernetesClusterTranslationRef = createTranslationRef({\n id: 'kubernetes-cluster',\n messages: {\n kubernetesClusterContentPage: {\n permissionAlert: {\n title: 'Permission required',\n message:\n \"To view Kubernetes objects, contact your portal administrator to give you the 'kubernetes.clusters.read' permission.\",\n },\n },\n },\n});\n"],"names":[],"mappings":";;AAkBO,MAAM,kCAAkC,
|
|
1
|
+
{"version":3,"file":"translation.esm.js","sources":["../src/translation.ts"],"sourcesContent":["/*\n * Copyright 2025 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport { createTranslationRef } from '@backstage/core-plugin-api/alpha';\n\n/** @alpha */\nexport const kubernetesClusterTranslationRef = createTranslationRef({\n id: 'kubernetes-cluster',\n messages: {\n kubernetesClusterContentPage: {\n permissionAlert: {\n title: 'Permission required',\n message:\n \"To view Kubernetes objects, contact your portal administrator to give you the 'kubernetes.clusters.read' permission.\",\n },\n },\n },\n});\n"],"names":[],"mappings":";;AAkBO,MAAM,kCAAkC,oBAAA,CAAqB;AAAA,EAClE,EAAA,EAAI,oBAAA;AAAA,EACJ,QAAA,EAAU;AAAA,IACR,4BAAA,EAA8B;AAAA,MAC5B,eAAA,EAAiB;AAAA,QACf,KAAA,EAAO,qBAAA;AAAA,QACP,OAAA,EACE;AAAA;AACJ;AACF;AAEJ,CAAC;;;;"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@backstage/plugin-kubernetes-cluster",
|
|
3
|
-
"version": "0.0.28
|
|
3
|
+
"version": "0.0.28",
|
|
4
4
|
"description": "A Backstage plugin that shows details of Kubernetes clusters",
|
|
5
5
|
"backstage": {
|
|
6
6
|
"role": "frontend-plugin",
|
|
@@ -62,13 +62,13 @@
|
|
|
62
62
|
"test": "backstage-cli package test"
|
|
63
63
|
},
|
|
64
64
|
"dependencies": {
|
|
65
|
-
"@backstage/catalog-model": "1.7.5",
|
|
66
|
-
"@backstage/core-components": "0.17.5
|
|
67
|
-
"@backstage/core-plugin-api": "1.10.9",
|
|
68
|
-
"@backstage/plugin-catalog-react": "1.20.0
|
|
69
|
-
"@backstage/plugin-kubernetes-common": "0.9.6",
|
|
70
|
-
"@backstage/plugin-kubernetes-react": "0.5.10
|
|
71
|
-
"@backstage/plugin-permission-react": "0.4.36",
|
|
65
|
+
"@backstage/catalog-model": "^1.7.5",
|
|
66
|
+
"@backstage/core-components": "^0.17.5",
|
|
67
|
+
"@backstage/core-plugin-api": "^1.10.9",
|
|
68
|
+
"@backstage/plugin-catalog-react": "^1.20.0",
|
|
69
|
+
"@backstage/plugin-kubernetes-common": "^0.9.6",
|
|
70
|
+
"@backstage/plugin-kubernetes-react": "^0.5.10",
|
|
71
|
+
"@backstage/plugin-permission-react": "^0.4.36",
|
|
72
72
|
"@kubernetes-models/apimachinery": "^2.0.0",
|
|
73
73
|
"@kubernetes-models/base": "^5.0.0",
|
|
74
74
|
"@material-ui/core": "^4.12.2",
|
|
@@ -81,8 +81,8 @@
|
|
|
81
81
|
"react-use": "^17.2.4"
|
|
82
82
|
},
|
|
83
83
|
"devDependencies": {
|
|
84
|
-
"@backstage/cli": "0.
|
|
85
|
-
"@backstage/test-utils": "1.7.11
|
|
84
|
+
"@backstage/cli": "^0.34.0",
|
|
85
|
+
"@backstage/test-utils": "^1.7.11",
|
|
86
86
|
"@testing-library/dom": "^10.0.0",
|
|
87
87
|
"@testing-library/jest-dom": "^6.0.0",
|
|
88
88
|
"@testing-library/react": "^16.0.0",
|