57 lines
3.0 KiB
Groovy
57 lines
3.0 KiB
Groovy
plugins {
|
|
id "com.android.application"
|
|
}
|
|
|
|
android {
|
|
namespace "su.cin.rapvpn"
|
|
compileSdk 35
|
|
|
|
signingConfigs {
|
|
release {
|
|
// Для тестовой среды используем debug-сертификат как fallback, чтобы APK всегда можно было установить.
|
|
// Когда будет отдельный keystore для prod/release — заменим на него в этом блоке.
|
|
initWith signingConfigs.debug
|
|
}
|
|
}
|
|
|
|
buildFeatures {
|
|
buildConfig true
|
|
}
|
|
|
|
def normalizeGradleString = { value ->
|
|
return (value == null ? "" : value.toString()).replace("\\", "\\\\").replace("\"", "\\\"")
|
|
}
|
|
|
|
def defaultBackendUrl = project.findProperty("RAP_ANDROID_DEFAULT_BACKEND_URL") ?: ""
|
|
// This is a node bootstrap seed set, not an API/backend selector. The
|
|
// Android app installs as a fabric node and tries every QUIC endpoint that
|
|
// may be reachable from its current network: public nodes, LAN nodes, or a
|
|
// closed-site neighbor that can route onward through the fabric.
|
|
def defaultFabricBootstrapPeers = project.findProperty("RAP_ANDROID_FABRIC_BOOTSTRAP_PEERS") ?: "quic://94.141.118.222:19199#sha256=49892029a27db9c394a41bc4cb917d9cceb1f86219417c351764d2ed9d6bc683,quic://94.141.118.222:19191#sha256=72e51f1631b32c3a7d1e8732fe3325e0395a897a5aa31db645888c142e4ae401,quic://192.168.200.61:19134#sha256=72e51f1631b32c3a7d1e8732fe3325e0395a897a5aa31db645888c142e4ae401,quic://192.168.200.61:19132#sha256=8d28b75144d25d29e3b8f8022b6165258ce3cb0e227a2d9d97996839abb89c2a,quic://192.168.200.61:19133#sha256=a71b07e55b810f57b01696c485b765b336983e963238163085824bf04022ecaa,quic://192.168.200.85:18080#sha256=49892029a27db9c394a41bc4cb917d9cceb1f86219417c351764d2ed9d6bc683,quic://192.168.200.85:18081#sha256=2a3be67e6345943a36cfa1197a5879c2b112c81adc019fd1ee9d7dffbf188b57,quic://192.168.200.85:18082#sha256=a318c1a756ff43595635961768dfd1677afa7e2cbf945d724c107ff82426378a"
|
|
def defaultClusterId = project.findProperty("RAP_ANDROID_DEFAULT_CLUSTER_ID") ?: "cfc0743d-d960-49fb-9de8-96e063d5e4aa"
|
|
def defaultOrganizationId = project.findProperty("RAP_ANDROID_DEFAULT_ORGANIZATION_ID") ?: "125ff8b2-5ac1-4406-9bbb-ebbe18f7c7ed"
|
|
|
|
defaultConfig {
|
|
applicationId "su.cin.rapvpn"
|
|
minSdk 26
|
|
targetSdk 35
|
|
versionCode 239
|
|
versionName "0.2.239"
|
|
buildConfigField "String", "DEFAULT_BACKEND_URL", "\"${normalizeGradleString(defaultBackendUrl)}\""
|
|
buildConfigField "String", "FABRIC_BOOTSTRAP_PEERS", "\"${normalizeGradleString(defaultFabricBootstrapPeers)}\""
|
|
buildConfigField "String", "DEFAULT_CLUSTER_ID", "\"${normalizeGradleString(defaultClusterId)}\""
|
|
buildConfigField "String", "DEFAULT_ORGANIZATION_ID", "\"${normalizeGradleString(defaultOrganizationId)}\""
|
|
}
|
|
|
|
buildTypes {
|
|
release {
|
|
signingConfig signingConfigs.release
|
|
}
|
|
}
|
|
}
|
|
|
|
dependencies {
|
|
implementation files("libs/rap-fabricvpn.aar")
|
|
implementation "com.squareup.okhttp3:okhttp:5.3.2"
|
|
}
|