diff --git a/CHANGELOG.md b/CHANGELOG.md index 241d150..afeb363 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -30,6 +30,10 @@ Dropping a requirement of a major version of a dependency is a new contract. - Add `SudoSshUbuntuImage`. Resolve [JPERF-445]. - Add `AutoCloseable` wrappers for some `docker-java` resources. +### Fixed +- Avoid degradation-prone central Ubuntu servers. Fix [JPERF-444]. + +[JPERF-444]: https://ecosystem.atlassian.net/browse/JPERF-444 [JPERF-445]: https://ecosystem.atlassian.net/browse/JPERF-445 ## [0.1.0] - 2019-02-15 diff --git a/src/main/kotlin/com/atlassian/performance/tools/sshubuntu/api/SudoSshUbuntuImage.kt b/src/main/kotlin/com/atlassian/performance/tools/sshubuntu/api/SudoSshUbuntuImage.kt index 50cb42c..cd8ace7 100644 --- a/src/main/kotlin/com/atlassian/performance/tools/sshubuntu/api/SudoSshUbuntuImage.kt +++ b/src/main/kotlin/com/atlassian/performance/tools/sshubuntu/api/SudoSshUbuntuImage.kt @@ -85,8 +85,10 @@ class SudoSshUbuntuImage( authentication = PasswordAuthentication("root"), port = sshPort ) + val debianMirror = "deb mirror://mirrors.ubuntu.com/mirrors.txt xenial main restricted universe multiverse" val ssh = Ssh(sshHost) ssh.newConnection().use { + it.execute("echo \"$debianMirror\\n\" > /etc/apt/sources.list") it.execute("apt-get update", Duration.ofSeconds(50)) it.execute("apt-get install sudo") }