Skip to content

Commit 465e0b8

Browse files
committed
refactor(localtunnel): attach RequirePreview attribute to localtunnel
This closes #684. There should be documentation on how to use webhooks until a stable solution for local urls is found
1 parent 8c1848f commit 465e0b8

File tree

3 files changed

+6
-0
lines changed

3 files changed

+6
-0
lines changed

examples/WebhookOperator/WebhookOperator.csproj

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
<Nullable>enable</Nullable>
66
<ImplicitUsings>enable</ImplicitUsings>
77
<IsPackable>false</IsPackable>
8+
<EnablePreviewFeatures>true</EnablePreviewFeatures>
89
</PropertyGroup>
910

1011
<ItemGroup>

src/KubeOps.Operator.Web/Builder/OperatorBuilderExtensions.cs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
using System.Reflection;
2+
using System.Runtime.Versioning;
23

34
using KubeOps.Abstractions.Builder;
45
using KubeOps.Operator.Web.LocalTunnel;
@@ -37,6 +38,9 @@ public static class OperatorBuilderExtensions
3738
/// ;
3839
/// </code>
3940
/// </example>
41+
[RequiresPreviewFeatures(
42+
"Localtunnel is sometimes unstable, use with caution. " +
43+
"This API is in preview and may be removed in future versions if no stable alternative is found.")]
4044
public static IOperatorBuilder AddDevelopmentTunnel(
4145
this IOperatorBuilder builder,
4246
ushort port,

test/Directory.Build.props

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
<Nullable>enable</Nullable>
66
<IsPackable>false</IsPackable>
77
<IsTestProject>true</IsTestProject>
8+
<EnablePreviewFeatures>true</EnablePreviewFeatures>
89
</PropertyGroup>
910

1011
<ItemGroup>

0 commit comments

Comments
 (0)