File tree 1 file changed +9
-0
lines changed
src/main/java/com/dajudge/kindcontainer
1 file changed +9
-0
lines changed Original file line number Diff line number Diff line change 6
6
import com .github .dockerjava .api .model .Bind ;
7
7
import com .github .dockerjava .api .model .ContainerNetwork ;
8
8
import com .github .dockerjava .api .model .Volume ;
9
+ import org .jetbrains .annotations .NotNull ;
9
10
import org .slf4j .Logger ;
10
11
import org .slf4j .LoggerFactory ;
11
12
import org .testcontainers .DockerClientFactory ;
@@ -88,6 +89,7 @@ public KindContainer(final KubernetesImageSpec<KindContainerVersion> imageSpec)
88
89
super (imageSpec .getImage ());
89
90
this .version = imageSpec .getVersion ();
90
91
final StringBuffer log = new StringBuffer ();
92
+ final String startupMessage = getStartupMessage ();
91
93
this .withStartupTimeout (ofSeconds (300 ))
92
94
.withLogConsumer (outputFrame -> {
93
95
if (provisioningLatch .getCount () != 0 ) {
@@ -121,6 +123,13 @@ public KindContainer(final KubernetesImageSpec<KindContainerVersion> imageSpec)
121
123
.withTmpFs (TMP_FILESYSTEMS );
122
124
}
123
125
126
+ @ NotNull
127
+ private String getStartupMessage () {
128
+ return version .descriptor ().getMajor () >= 1 && version .descriptor ().getMajor () >= 29
129
+ ? "Reached target multi-user.target"
130
+ : "Reached target Multi-User System." ;
131
+ }
132
+
124
133
@ Override
125
134
public T withReuse (final boolean reuse ) {
126
135
if (reuse ) {
You can’t perform that action at this time.
0 commit comments