Compare commits
16 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 2f746486db | |||
| 55b10c5ab2 | |||
| a7761e992b | |||
| 679922e711 | |||
| 248ffa4962 | |||
| 0b082984a7 | |||
| 4da3513015 | |||
| 74af59ef50 | |||
| 67287158fd | |||
| dbc1fb199b | |||
| c63afb1461 | |||
| 3429b32625 | |||
| 5cf360b591 | |||
| 889504962d | |||
| 7b51df5ce5 | |||
| a3b860c1f5 |
@@ -24,6 +24,14 @@ jobs:
|
|||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v4
|
||||||
|
|
||||||
|
- name: Get package name
|
||||||
|
id: package_name
|
||||||
|
working-directory: ./headlamp-sealed-secrets
|
||||||
|
run: |
|
||||||
|
PKG_NAME=$(jq -r '.name' package.json)
|
||||||
|
echo "name=${PKG_NAME}" >> $GITHUB_OUTPUT
|
||||||
|
echo "Package name: ${PKG_NAME}"
|
||||||
|
|
||||||
- name: Configure git
|
- name: Configure git
|
||||||
run: |
|
run: |
|
||||||
git config user.name "github-actions[bot]"
|
git config user.name "github-actions[bot]"
|
||||||
@@ -38,7 +46,7 @@ jobs:
|
|||||||
- name: Update artifacthub-pkg.yml version
|
- name: Update artifacthub-pkg.yml version
|
||||||
run: |
|
run: |
|
||||||
VERSION="${{ inputs.version }}"
|
VERSION="${{ inputs.version }}"
|
||||||
RELEASE_URL="https://github.com/${{ github.repository }}/releases/download/v${VERSION}/headlamp-sealed-secrets-${VERSION}.tar.gz"
|
RELEASE_URL="https://github.com/${{ github.repository }}/releases/download/v${VERSION}/${{ steps.package_name.outputs.name }}-${VERSION}.tar.gz"
|
||||||
|
|
||||||
sed -i "s|^version:.*|version: ${VERSION}|" artifacthub-pkg.yml
|
sed -i "s|^version:.*|version: ${VERSION}|" artifacthub-pkg.yml
|
||||||
sed -i "s|^appVersion:.*|appVersion: ${VERSION}|" artifacthub-pkg.yml
|
sed -i "s|^appVersion:.*|appVersion: ${VERSION}|" artifacthub-pkg.yml
|
||||||
@@ -74,7 +82,7 @@ jobs:
|
|||||||
- name: Move tarball to root
|
- name: Move tarball to root
|
||||||
working-directory: ./headlamp-sealed-secrets
|
working-directory: ./headlamp-sealed-secrets
|
||||||
run: |
|
run: |
|
||||||
TARBALL="headlamp-sealed-secrets-${{ inputs.version }}.tar.gz"
|
TARBALL="${{ steps.package_name.outputs.name }}-${{ inputs.version }}.tar.gz"
|
||||||
if [ ! -f "${TARBALL}" ]; then
|
if [ ! -f "${TARBALL}" ]; then
|
||||||
echo "::error::Expected tarball ${TARBALL} not found"
|
echo "::error::Expected tarball ${TARBALL} not found"
|
||||||
ls -la *.tar.gz
|
ls -la *.tar.gz
|
||||||
@@ -85,7 +93,7 @@ jobs:
|
|||||||
|
|
||||||
- name: Validate tarball name
|
- name: Validate tarball name
|
||||||
run: |
|
run: |
|
||||||
EXPECTED="headlamp-sealed-secrets-${{ inputs.version }}.tar.gz"
|
EXPECTED="${{ steps.package_name.outputs.name }}-${{ inputs.version }}.tar.gz"
|
||||||
ACTUAL=$(ls *.tar.gz)
|
ACTUAL=$(ls *.tar.gz)
|
||||||
if [ "$EXPECTED" != "$ACTUAL" ]; then
|
if [ "$EXPECTED" != "$ACTUAL" ]; then
|
||||||
echo "::error::Tarball name mismatch! Expected: $EXPECTED, Got: $ACTUAL"
|
echo "::error::Tarball name mismatch! Expected: $EXPECTED, Got: $ACTUAL"
|
||||||
@@ -96,19 +104,19 @@ jobs:
|
|||||||
- name: Compute checksum
|
- name: Compute checksum
|
||||||
id: compute_checksum
|
id: compute_checksum
|
||||||
run: |
|
run: |
|
||||||
TARBALL="headlamp-sealed-secrets-${{ inputs.version }}.tar.gz"
|
TARBALL="${{ steps.package_name.outputs.name }}-${{ inputs.version }}.tar.gz"
|
||||||
CHECKSUM=$(sha256sum "$TARBALL" | awk '{print $1}')
|
CHECKSUM=$(sha256sum "$TARBALL" | awk '{print $1}')
|
||||||
echo "checksum=${CHECKSUM}" >> $GITHUB_OUTPUT
|
echo "checksum=${CHECKSUM}" >> $GITHUB_OUTPUT
|
||||||
echo "Checksum: sha256:${CHECKSUM}"
|
echo "Checksum: sha256:${CHECKSUM}"
|
||||||
|
|
||||||
- name: Verify tarball contents
|
- name: Verify tarball contents
|
||||||
run: |
|
run: |
|
||||||
TARBALL="headlamp-sealed-secrets-${{ inputs.version }}.tar.gz"
|
TARBALL="${{ steps.package_name.outputs.name }}-${{ inputs.version }}.tar.gz"
|
||||||
echo "Tarball contents:"
|
echo "Tarball contents:"
|
||||||
tar -tzf "${TARBALL}" | head -20
|
tar -tzf "${TARBALL}" | head -20
|
||||||
|
|
||||||
# Verify main.js exists (structure is headlamp-sealed-secrets/main.js)
|
# Verify main.js exists (structure is <package-name>/main.js)
|
||||||
if ! tar -tzf "${TARBALL}" | grep -q "headlamp-sealed-secrets/main.js"; then
|
if ! tar -tzf "${TARBALL}" | grep -q "${{ steps.package_name.outputs.name }}/main.js"; then
|
||||||
echo "::error::main.js not found in tarball"
|
echo "::error::main.js not found in tarball"
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
@@ -134,7 +142,7 @@ jobs:
|
|||||||
uses: softprops/action-gh-release@v2
|
uses: softprops/action-gh-release@v2
|
||||||
with:
|
with:
|
||||||
tag_name: "v${{ inputs.version }}"
|
tag_name: "v${{ inputs.version }}"
|
||||||
files: headlamp-sealed-secrets-${{ inputs.version }}.tar.gz
|
files: ${{ steps.package_name.outputs.name }}-${{ inputs.version }}.tar.gz
|
||||||
fail_on_unmatched_files: true
|
fail_on_unmatched_files: true
|
||||||
draft: false
|
draft: false
|
||||||
prerelease: false
|
prerelease: false
|
||||||
@@ -147,9 +155,9 @@ jobs:
|
|||||||
echo "Release Summary:"
|
echo "Release Summary:"
|
||||||
echo "=================="
|
echo "=================="
|
||||||
echo "Version: v${{ inputs.version }}"
|
echo "Version: v${{ inputs.version }}"
|
||||||
echo "Tarball: headlamp-sealed-secrets-${{ inputs.version }}.tar.gz"
|
echo "Tarball: ${{ steps.package_name.outputs.name }}-${{ inputs.version }}.tar.gz"
|
||||||
echo "Checksum: sha256:${{ steps.compute_checksum.outputs.checksum }}"
|
echo "Checksum: sha256:${{ steps.compute_checksum.outputs.checksum }}"
|
||||||
echo "Archive URL: https://github.com/${{ github.repository }}/releases/download/v${{ inputs.version }}/headlamp-sealed-secrets-${{ inputs.version }}.tar.gz"
|
echo "Archive URL: https://github.com/${{ github.repository }}/releases/download/v${{ inputs.version }}/${{ steps.package_name.outputs.name }}-${{ inputs.version }}.tar.gz"
|
||||||
echo ""
|
echo ""
|
||||||
echo "✓ Version bumped to ${{ inputs.version }}"
|
echo "✓ Version bumped to ${{ inputs.version }}"
|
||||||
echo "✓ Metadata updated with checksum"
|
echo "✓ Metadata updated with checksum"
|
||||||
|
|||||||
+6
-6
@@ -1,13 +1,13 @@
|
|||||||
# Artifact Hub package metadata file
|
# Artifact Hub package metadata file
|
||||||
# https://github.com/artifacthub/hub/blob/master/docs/metadata/artifacthub-pkg.yml
|
# https://github.com/artifacthub/hub/blob/master/docs/metadata/artifacthub-pkg.yml
|
||||||
version: 0.2.12
|
version: 0.2.17
|
||||||
name: headlamp-sealed-secrets
|
name: sealed-secrets
|
||||||
displayName: Sealed Secrets Plugin for Headlamp
|
displayName: Sealed Secrets
|
||||||
createdAt: "2026-02-12T00:00:00Z"
|
createdAt: "2026-02-12T00:00:00Z"
|
||||||
description: A comprehensive Headlamp plugin for managing Bitnami Sealed Secrets with client-side encryption and RBAC-aware UI
|
description: A comprehensive Headlamp plugin for managing Bitnami Sealed Secrets with client-side encryption and RBAC-aware UI
|
||||||
license: Apache-2.0
|
license: Apache-2.0
|
||||||
homeURL: https://github.com/privilegedescalation/headlamp-sealed-secrets-plugin
|
homeURL: https://github.com/privilegedescalation/headlamp-sealed-secrets-plugin
|
||||||
appVersion: 0.2.12
|
appVersion: 0.2.17
|
||||||
containersImages:
|
containersImages:
|
||||||
- name: sealed-secrets-controller
|
- name: sealed-secrets-controller
|
||||||
image: docker.io/bitnami/sealed-secrets-controller:v0.24.0
|
image: docker.io/bitnami/sealed-secrets-controller:v0.24.0
|
||||||
@@ -19,8 +19,8 @@ keywords:
|
|||||||
- encryption
|
- encryption
|
||||||
- security
|
- security
|
||||||
annotations:
|
annotations:
|
||||||
headlamp/plugin/archive-url: "https://github.com/privilegedescalation/headlamp-sealed-secrets-plugin/releases/download/v0.2.12/headlamp-sealed-secrets-0.2.12.tar.gz"
|
headlamp/plugin/archive-url: "https://github.com/privilegedescalation/headlamp-sealed-secrets-plugin/releases/download/v0.2.17/sealed-secrets-0.2.17.tar.gz"
|
||||||
headlamp/plugin/archive-checksum: sha256:a269f578a94131dc85ae50aa7f828f0dfe4f2fcc95638879784e4cdc09c0c076
|
headlamp/plugin/archive-checksum: sha256:2f1f94aa40df7e66e3b3585792fbe8c05c89a1b9705d9a34358ecf40713dd35c
|
||||||
headlamp/plugin/version-compat: ">=0.13.0"
|
headlamp/plugin/version-compat: ">=0.13.0"
|
||||||
headlamp/plugin/distro-compat: "desktop,in-cluster,web,docker-desktop"
|
headlamp/plugin/distro-compat: "desktop,in-cluster,web,docker-desktop"
|
||||||
links:
|
links:
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "headlamp-sealed-secrets",
|
"name": "sealed-secrets",
|
||||||
"version": "0.2.12",
|
"version": "0.2.17",
|
||||||
"description": "Headlamp plugin for Bitnami Sealed Secrets - manage encrypted Kubernetes secrets",
|
"description": "Headlamp plugin for Bitnami Sealed Secrets - manage encrypted Kubernetes secrets",
|
||||||
"files": [
|
"files": [
|
||||||
"dist",
|
"dist",
|
||||||
|
|||||||
@@ -57,15 +57,15 @@ function formatScope(scope: SealedSecretScope): string {
|
|||||||
* SealedSecret detail view component
|
* SealedSecret detail view component
|
||||||
*/
|
*/
|
||||||
export function SealedSecretDetail() {
|
export function SealedSecretDetail() {
|
||||||
const { namespace, name } = useParams<{ namespace: string; name: string }>();
|
const { namespace = '', name = '' } = useParams<{ namespace: string; name: string }>();
|
||||||
const [sealedSecret, error] = SealedSecret.useGet(name, namespace);
|
const [sealedSecret, error] = SealedSecret.useGet(name || undefined, namespace || undefined);
|
||||||
const [secret] = K8s.ResourceClasses.Secret.useGet(name, namespace);
|
const [secret] = K8s.ResourceClasses.Secret.useGet(name || undefined, namespace || undefined);
|
||||||
const [decryptKey, setDecryptKey] = React.useState<string | null>(null);
|
const [decryptKey, setDecryptKey] = React.useState<string | null>(null);
|
||||||
const [deleteDialogOpen, setDeleteDialogOpen] = React.useState(false);
|
const [deleteDialogOpen, setDeleteDialogOpen] = React.useState(false);
|
||||||
const [rotating, setRotating] = React.useState(false);
|
const [rotating, setRotating] = React.useState(false);
|
||||||
const [canDecrypt, setCanDecrypt] = React.useState(false);
|
const [canDecrypt, setCanDecrypt] = React.useState(false);
|
||||||
const { enqueueSnackbar } = useSnackbar();
|
const { enqueueSnackbar } = useSnackbar();
|
||||||
const { permissions } = usePermissions(namespace);
|
const { permissions } = usePermissions(namespace || undefined);
|
||||||
|
|
||||||
// Check if user can decrypt secrets (requires get permission on Secrets)
|
// Check if user can decrypt secrets (requires get permission on Secrets)
|
||||||
React.useEffect(() => {
|
React.useEffect(() => {
|
||||||
@@ -74,6 +74,11 @@ export function SealedSecretDetail() {
|
|||||||
}
|
}
|
||||||
}, [namespace]);
|
}, [namespace]);
|
||||||
|
|
||||||
|
// Wait for required params before rendering
|
||||||
|
if (!namespace || !name) {
|
||||||
|
return <SealedSecretDetailSkeleton />;
|
||||||
|
}
|
||||||
|
|
||||||
// Show error if fetch failed
|
// Show error if fetch failed
|
||||||
if (error) {
|
if (error) {
|
||||||
return (
|
return (
|
||||||
@@ -146,7 +151,7 @@ export function SealedSecretDetail() {
|
|||||||
},
|
},
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
<Box>
|
<Box sx={{ height: '100%', overflow: 'auto' }}>
|
||||||
<SectionBox
|
<SectionBox
|
||||||
title={
|
title={
|
||||||
<Box display="flex" alignItems="center" justifyContent="space-between">
|
<Box display="flex" alignItems="center" justifyContent="space-between">
|
||||||
|
|||||||
@@ -4,7 +4,6 @@
|
|||||||
* Configuration page for the Sealed Secrets plugin
|
* Configuration page for the Sealed Secrets plugin
|
||||||
*/
|
*/
|
||||||
|
|
||||||
import { SectionBox } from '@kinvolk/headlamp-plugin/lib/CommonComponents';
|
|
||||||
import { Box, Button, Divider, TextField, Typography } from '@mui/material';
|
import { Box, Button, Divider, TextField, Typography } from '@mui/material';
|
||||||
import { useSnackbar } from 'notistack';
|
import { useSnackbar } from 'notistack';
|
||||||
import React from 'react';
|
import React from 'react';
|
||||||
@@ -35,10 +34,7 @@ export function SettingsPage() {
|
|||||||
};
|
};
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<SectionBox
|
<Box p={3}>
|
||||||
title="Sealed Secrets Plugin Settings"
|
|
||||||
>
|
|
||||||
<Box p={3}>
|
|
||||||
<Typography variant="body1" paragraph id="settings-description">
|
<Typography variant="body1" paragraph id="settings-description">
|
||||||
Configure the connection to your Sealed Secrets controller. These settings are stored in
|
Configure the connection to your Sealed Secrets controller. These settings are stored in
|
||||||
your browser's local storage.
|
your browser's local storage.
|
||||||
@@ -155,7 +151,6 @@ export function SettingsPage() {
|
|||||||
<dd style={{ display: 'inline', margin: 0 }}>8080</dd>
|
<dd style={{ display: 'inline', margin: 0 }}>8080</dd>
|
||||||
</Typography>
|
</Typography>
|
||||||
</Box>
|
</Box>
|
||||||
</Box>
|
</Box>
|
||||||
</SectionBox>
|
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -107,7 +107,7 @@ registerDetailsViewSection(({ resource }) => {
|
|||||||
* Settings will appear in Settings → Plugins → Sealed Secrets
|
* Settings will appear in Settings → Plugins → Sealed Secrets
|
||||||
*/
|
*/
|
||||||
registerPluginSettings(
|
registerPluginSettings(
|
||||||
'headlamp-sealed-secrets',
|
'Sealed Secrets',
|
||||||
() => (
|
() => (
|
||||||
<GenericErrorBoundary>
|
<GenericErrorBoundary>
|
||||||
<SettingsPage />
|
<SettingsPage />
|
||||||
|
|||||||
Reference in New Issue
Block a user