Error: Unknown host 'jcenter.bintray.com'

I get an error: Unknown host 'jcenter.bintray.com' Error: Unknown host 'jcenter.bintray.com'. You may need to configure proxy settings in Gradle. Enable Gradle "Offline" and the synchronization project.
Learn more about configuring HTTP proxies in Gradle.

in Android Studio 2.2.1. Can you help me please?

Here is my code

build.gradle

    apply plugin: 'com.android.application'
android {
compileSdkVersion 24
buildToolsVersion "24.0.2"
defaultConfig {
    applicationId "com.dev.alemappdev.testclevertap"
    minSdkVersion 16
    targetSdkVersion 24
    versionCode 1
    versionName "1.0"
    testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
}
buildTypes {
    release {
        minifyEnabled false
        proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
    }
}
}
dependencies {
compile fileTree(include: ['*.jar'], dir: 'libs')
compile 'com.android.support:appcompat-v7:24.2.1'
compile 'com.google.android.gms:play-services-gcm:9.6.1'
compile 'com.clevertap.android:clevertap-android-sdk:3.0.0'
compile 'com.google.firebase:firebase-messaging:9.0.2' // uncomment if using FCM
compile 'com.android.support:support-v4:23.4.0'
}
apply plugin: 'com.google.gms.google-services'

build.gradle

buildscript {
repositories {
    jcenter()
    mavenCentral()
}
dependencies {
    classpath 'com.android.tools.build:gradle:2.2.1'
    classpath 'com.google.gms:google-services:3.0.0'

    // NOTE: Do not place your application dependencies here; they belong
    // in the individual module build.gradle files

}
}

allprojects {
repositories {
    jcenter()
    mavenCentral()
}
}

task clean(type: Delete) {
    delete rootProject.buildDir
}
+4
source share

Source: https://habr.com/ru/post/1657696/


All Articles