0

  • I am attempting to install SBT using the following instructions (from http://www.scala-sbt.org/0.13/docs/Installing-sbt-on-Linux.html)
    echo "deb https://dl.bintray.com/sbt/debian /" | sudo tee -a /etc/apt/sources.list.d/sbt.list
    sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv 2EE0EA64E40A89B84B2DF73499E82A75642AC823
    sudo apt-get update
    sudo apt-get install sbt
    

  • While executing apt-get update, a 403 is received:
    # sudo apt-get update
    ...
    Ign https://dl.bintray.com  InRelease
    Ign https://dl.bintray.com  Release.gpg
    Ign https://dl.bintray.com  Release
    Err https://dl.bintray.com  Packages
    Received HTTP code 403 from proxy after CONNECT
    ...
    W: Failed to fetch https://dl.bintray.com/sbt/debian/Packages  Received HTTP code 403 from proxy after CONNECT
    
    E: Some index files failed to download. They have been ignored, or old ones used instead.
    

  • Checking the keyserver (https://keyserver.ubuntu.com , search for 'sbt build tool') does not show expiration date for certificate:
    pub  4096R/642AC823 2015-05-29            
         Fingerprint=2EE0 EA64 E40A 89B8 4B2D  F734 99E8 2A75 642A C823 
    
    uid sbt build tool <scalasbt@gmail.com>
    sig  sig3  642AC823 2015-05-29 __________ __________ [selfsig]
    
    sub  4096R/06F9BF46 2015-05-29            
    sig sbind  642AC823 2015-05-29 __________ __________ []
    
    https://keyserver.ubuntu.com/pks/lookup?op=vindex&search=sbt+build&fingerprint=on
    

  • My OS info:
    # uname -a
    Linux xxxxxxxx 3.13.0-107-generic #154-Ubuntu SMP Tue Dec 20 09:57:27 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux
    
    # lsb_release -a
    No LSB modules are available.
    Distributor ID: Ubuntu
    Description:    Ubuntu 14.04.5 LTS
    Release:        14.04
    Codename:       trusty
    

  • I have recently used the same instructions on different host, but same OS, with success (mid to late January 2017?).

  • WORKAROUND: If https is changed to http in /etc/apt/sources.list.d/sbt.list, the apt-update works fine (no longer matches installation instructions, and bypasses the security of using https).
  • mb-texas
    • 385
    • 5
    • 10

    2 Answers2

    2
    • I learned that all puppetized hosts within a zone were recently configured for an http apt cache proxy. Once the apt cache proxy was removed from the host and the install began to work properly.
    • The sbt.list was restored to use the https prefix.
    mb-texas
    • 385
    • 5
    • 10
    1

    Anyone landing here with the 403 occurring 2021 should be aware that bintray has been removed by JFrog the original suppliers of it. This affects sbt which has been until recently distributed through bintray.

    Confirm by

    cd /etc/apt/sources.list.d
    

    then

    > grep bintray *
    sbt.list:deb https://dl.bintray.com/sbt/debian /
    sbt.list.save:deb https://dl.bintray.com/sbt/debian /
    

    if you see bintray in the sbt.list files,do

    rm sbt.list*
    

    and sudo apt update should no longer show 403

    It may be an idea to refresh the sbt source at this point, see here.

    Mazerunner72
    • 613
    • 2
    • 6
    • 16