public Optional<Lifecycle> lifecycle() {
        return Optional.ofNullable(this.lifecycle);
    }
@return Lifecycle is not allowed for ephemeral containers.
sdk/java/src/main/java/com/pulumi/kubernetes/core/v1/outputs/EphemeralContainer.java