-
Notifications
You must be signed in to change notification settings - Fork 55
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
removed unnecessaries properties for docker containers
- Loading branch information
1 parent
59c64bc
commit a8843db
Showing
1 changed file
with
3 additions
and
37 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,19 +1,14 @@ | ||
using System; | ||
using System.ComponentModel; | ||
using System.IO; | ||
using System.Net; | ||
using System.Threading; | ||
using System.Threading.Tasks; | ||
using DotNet.Testcontainers.Builders; | ||
using DotNet.Testcontainers.Configurations; | ||
using DotNet.Testcontainers.Images; | ||
using DotNet.Testcontainers.Networks; | ||
using Grpc.Core; | ||
using Microsoft.Extensions.Logging; | ||
using NLog.Extensions.Logging; | ||
using NUnit.Framework.Constraints; | ||
using Zeebe.Client; | ||
using Zeebe.Client.Api.Builder; | ||
using Zeebe.Client.Impl.Builder; | ||
using IContainer = DotNet.Testcontainers.Containers.IContainer; | ||
|
||
|
@@ -179,25 +174,7 @@ private IContainer CreateIdentityContainer(INetwork network) | |
.WithEnvironment("IDENTITY_DATABASE_NAME", "bitnami_keycloak") | ||
.WithEnvironment("IDENTITY_DATABASE_USERNAME", "bn_keycloak") | ||
.WithEnvironment("IDENTITY_DATABASE_PASSWORD", "#3]O?4RGj)DE7Z!9SA5") | ||
.WithEnvironment("KEYCLOAK_INIT_OPERATE_SECRET", "XALaRPl5qwTEItdwCMiPS62nVpKs7dL7") | ||
.WithEnvironment("KEYCLOAK_INIT_OPERATE_ROOT_URL", "http://localhost:1234/test") | ||
.WithEnvironment("KEYCLOAK_INIT_TASKLIST_SECRET", "XALaRPl5qwTEItdwCMiPS62nVpKs7dL7") | ||
.WithEnvironment("KEYCLOAK_INIT_TASKLIST_ROOT_URL", "http://localhost:1234/test") | ||
.WithEnvironment("KEYCLOAK_INIT_OPTIMIZE_SECRET", "XALaRPl5qwTEItdwCMiPS62nVpKs7dL7") | ||
.WithEnvironment("KEYCLOAK_INIT_OPTIMIZE_ROOT_URL", "http://localhost:1234/test") | ||
.WithEnvironment("KEYCLOAK_INIT_WEBMODELER_ROOT_URL", "http://localhost:1234/test") | ||
.WithEnvironment("KEYCLOAK_INIT_CONNECTORS_SECRET", "XALaRPl5qwTEItdwCMiPS62nVpKs7dL7") | ||
.WithEnvironment("KEYCLOAK_INIT_CONNECTORS_ROOT_URL", "http://localhost:1234/test") | ||
.WithEnvironment("KEYCLOAK_INIT_ZEEBE_NAME", "zeebe") | ||
.WithEnvironment("KEYCLOAK_USERS_0_USERNAME", "demo") | ||
.WithEnvironment("KEYCLOAK_USERS_0_PASSWORD", "demo") | ||
.WithEnvironment("KEYCLOAK_USERS_0_FIRST_NAME", "demo") | ||
.WithEnvironment("KEYCLOAK_USERS_0_EMAIL", "[email protected]") | ||
.WithEnvironment("KEYCLOAK_USERS_0_ROLES_0", "Identity") | ||
.WithEnvironment("KEYCLOAK_USERS_0_ROLES_1", "Optimize") | ||
.WithEnvironment("KEYCLOAK_USERS_0_ROLES_2", "Operate") | ||
.WithEnvironment("KEYCLOAK_USERS_0_ROLES_3", "Tasklist") | ||
.WithEnvironment("KEYCLOAK_USERS_0_ROLES_4", "Web Modeler") | ||
.WithEnvironment("KEYCLOAK_CLIENTS_0_NAME", "zeebe") | ||
.WithEnvironment("KEYCLOAK_CLIENTS_0_ID", "zeebe") | ||
.WithEnvironment("KEYCLOAK_CLIENTS_0_SECRET", "sddh123865WUS)(1%!") | ||
|
@@ -244,10 +221,6 @@ public IZeebeClient CreateZeebeClient() | |
.Build(); | ||
} | ||
|
||
private static readonly string ServerCertPath = | ||
Path.Combine(AppDomain.CurrentDomain.BaseDirectory, "Resources", "server.crt"); | ||
|
||
|
||
public IZeebeClient CreateAuthenticatedZeebeClient() | ||
{ | ||
var loggerFactory = LoggerFactory; | ||
|
@@ -265,7 +238,7 @@ public IZeebeClient CreateAuthenticatedZeebeClient() | |
|
||
private async Task AwaitBrokerReadiness() | ||
{ | ||
var zeebeClient = (ZeebeClient)client; | ||
var zeebeClient = withIdentity ? (ZeebeClient)CreateAuthenticatedZeebeClient() : (ZeebeClient)client; | ||
await zeebeClient.Connect(); | ||
var topologyErrorLogger = LoggerFactory.CreateLogger<ZeebeIntegrationTestHelper>(); | ||
var ready = false; | ||
|
@@ -283,15 +256,8 @@ private async Task AwaitBrokerReadiness() | |
} | ||
catch (Exception e) | ||
{ | ||
if (e is RpcException rpcException && rpcException.StatusCode == StatusCode.Unauthenticated) | ||
{ | ||
ready = true; | ||
} | ||
else | ||
{ | ||
// retry | ||
topologyErrorLogger.LogError(e, "Exception in sending topology"); | ||
} | ||
topologyErrorLogger.LogError(e, "Exception in sending topology"); | ||
// retry | ||
} | ||
|
||
continueLoop = !ready && maxCount > retries++; | ||
|