Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(pv): iSCSI Persistent Volume and possibility to bind PVs to PVCs in any namespace #3285

Closed

Conversation

St0rmingBr4in
Copy link

This adds the IscsiPersistentVolume class to be able to generate iSCSI backed persistent volumes.

This also adds the ability to bind a PV to a PVC in another namespace than the default one.

Signed-off-by: Julien DOCHE <julien.doche@datadoghq.com>
Signed-off-by: Julien DOCHE <julien.doche@datadoghq.com>
Signed-off-by: Julien DOCHE <julien.doche@datadoghq.com>
Signed-off-by: Julien DOCHE <julien.doche@datadoghq.com>
Signed-off-by: Julien DOCHE <julien.doche@datadoghq.com>
Signed-off-by: Julien DOCHE <julien.doche@datadoghq.com>
@St0rmingBr4in St0rmingBr4in changed the title Add iSCSI persistentvolume and possibility to bind PVs to PVCs in any namespace feat(PersistentVolume): Add iSCSI Persistent Volume and possibility to bind PVs to PVCs in any namespace Nov 12, 2023
@St0rmingBr4in
Copy link
Author

@iliapolo Could you take a look please ?

@sumupitchayan sumupitchayan changed the base branch from k8s-27/main to k8s-28/main February 23, 2024 15:26
@iliapolo iliapolo changed the title feat(PersistentVolume): Add iSCSI Persistent Volume and possibility to bind PVs to PVCs in any namespace feat(pv): iSCSI Persistent Volume and possibility to bind PVs to PVCs in any namespace Apr 7, 2024
@@ -208,10 +209,10 @@ export class PersistentVolume extends base.Resource implements IPersistentVolume
*
* @see https://kubernetes.io/docs/concepts/storage/persistent-volumes/#reserving-a-persistentvolume
*/
public reserve(): pvc.PersistentVolumeClaim {
public reserve(namespace?: string): pvc.PersistentVolumeClaim {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We don't normally use optional positional arguments. Instead, create a PersistentVolumeReserveOptions interface.

Also this requires a test.

metadata: { name: `pvc-${this.name}`, namespace: this.metadata.namespace },

metadata: { name: `pvc-${this.name}` },
namespace: namespace ? namespace : this.metadata.namespace,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
namespace: namespace ? namespace : this.metadata.namespace,
namespace: namespace ?? this.metadata.namespace,

@iliapolo
Copy link
Member

iliapolo commented Apr 7, 2024

Awesome, thanks for this!

@iliapolo iliapolo changed the base branch from k8s-28/main to k8s-29/main April 15, 2024 06:11
@iliapolo iliapolo changed the base branch from k8s-29/main to k8s-30/main June 4, 2024 15:26
@iliapolo iliapolo added backport-to-k8s-29/main Backport a PR to the k8s-30 branch and removed backport-to-k8s-27/main labels Jun 4, 2024
@iliapolo iliapolo added the response-requested Awaiting response from author label Sep 10, 2024
Copy link

This PR has not received a response in a while and will be closed soon. If you want to keep it open, please leave a comment below @mentioning a maintainer.

@github-actions github-actions bot added the closing-soon Issue/PR will be closing soon if no response is provided label Sep 10, 2024
@iliapolo iliapolo changed the base branch from k8s-30/main to k8s-31/main September 11, 2024 11:54
@iliapolo iliapolo added backport-to-k8s-30/main Backport a PR to the k8s-30 branch and removed backport-to-k8s-28/main labels Sep 11, 2024
@github-actions github-actions bot added closed-for-staleness Issue/PR was closed due to staleness and removed closing-soon Issue/PR will be closing soon if no response is provided labels Sep 17, 2024
@github-actions github-actions bot closed this Sep 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport-to-k8s-29/main Backport a PR to the k8s-30 branch backport-to-k8s-30/main Backport a PR to the k8s-30 branch closed-for-staleness Issue/PR was closed due to staleness response-requested Awaiting response from author
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants