homebrew-core/Formula/localstack.rb

120 lines
5.3 KiB
Ruby

class Localstack < Formula
include Language::Python::Virtualenv
desc "Fully functional local AWS cloud stack"
homepage "https://github.com/localstack/localstack"
url "https://files.pythonhosted.org/packages/25/b7/01aa3732a152ea3eb2f7e5ba6c500734abf0cdf596699816ef753db8c118/localstack-0.12.1.tar.gz"
sha256 "8d364fcccd25e897c5d42e7fb99b2a0120e511d530e5f8c9872d56e33ca3b72c"
license "Apache-2.0"
bottle do
cellar :any_skip_relocation
sha256 "da98d8375901d274c3f7041c0566b7effd694c3292be35f272c9f4d1806f491a" => :catalina
sha256 "9942cb521c3431894e5dbcd86eaae50867834835b115ac1b901d55d11b92ce8f" => :mojave
sha256 "1fe1e28d2882093a7cc6fa2f701ea3c099943b700a8e7aed507cf8d027dd4ea7" => :high_sierra
end
depends_on "docker" => :test
depends_on "python@3.9"
resource "boto3" do
url "https://files.pythonhosted.org/packages/19/3d/08a8b5f43c9303ffd3282f3659a6f7ed2c81157bdae9d7fccc0b577eea12/boto3-1.16.4.tar.gz"
sha256 "8611d07488bb36b509d9a79a4ab593cf1c96f9c0d177733007568cbfa1079914"
end
resource "botocore" do
url "https://files.pythonhosted.org/packages/1e/4f/24abb8dbfe3d4a4ebfcedf9d966fde75d3e0e3026148e95e4667e2545709/botocore-1.19.4.tar.gz"
sha256 "c78fe2fb4790e9f06dc40a28402893f12088c4aa88b739475827d9674972f1c4"
end
resource "certifi" do
url "https://files.pythonhosted.org/packages/40/a7/ded59fa294b85ca206082306bba75469a38ea1c7d44ea7e1d64f5443d67a/certifi-2020.6.20.tar.gz"
sha256 "5930595817496dd21bb8dc35dad090f1c2cd0adfaf21204bf6732ca5d8ee34d3"
end
resource "chardet" do
url "https://files.pythonhosted.org/packages/fc/bb/a5768c230f9ddb03acc9ef3f0d4a3cf93462473795d18e9535498c8f929d/chardet-3.0.4.tar.gz"
sha256 "84ab92ed1c4d4f16916e05906b6b75a6c0fb5db821cc65e70cbd64a3e2a5eaae"
end
resource "dnslib" do
url "https://files.pythonhosted.org/packages/07/ec/611036f948b362e1155e68521c2e8f589f919b51fa361157e8808faffbe3/dnslib-0.9.14.tar.gz"
sha256 "fbd20a7cd704836923be8e130f0da6c3d840f14ac04590fae420a41d1f1be6fb"
end
resource "dnspython" do
url "https://files.pythonhosted.org/packages/ec/c5/14bcd63cb6d06092a004793399ec395405edf97c2301dfdc146dfbd5beed/dnspython-1.16.0.zip"
sha256 "36c5e8e38d4369a08b6780b7f27d790a292b2b08eea01607865bf0936c558e01"
end
resource "docopt" do
url "https://files.pythonhosted.org/packages/a2/55/8f8cab2afd404cf578136ef2cc5dfb50baa1761b68c9da1fb1e4eed343c9/docopt-0.6.2.tar.gz"
sha256 "49b3a825280bd66b3aa83585ef59c4a8c82f2c8a522dbe754a8bc8d08c85c491"
end
resource "idna" do
url "https://files.pythonhosted.org/packages/ea/b7/e0e3c1c467636186c39925827be42f16fee389dc404ac29e930e9136be70/idna-2.10.tar.gz"
sha256 "b307872f855b18632ce0c21c5e45be78c0ea7ae4c15c828c20788b26921eb3f6"
end
resource "jmespath" do
url "https://files.pythonhosted.org/packages/3c/56/3f325b1eef9791759784aa5046a8f6a1aff8f7c898a2e34506771d3b99d8/jmespath-0.10.0.tar.gz"
sha256 "b85d0567b8666149a93172712e68920734333c0ce7e89b78b3e987f71e5ed4f9"
end
resource "localstack-client" do
url "https://files.pythonhosted.org/packages/08/2e/529afb53f3c20419709c36f51b4004215432bca04029619cb04c5c2b24b5/localstack-client-1.6.tar.gz"
sha256 "262a94c48c9992ff8114ebb8bae0ac81667d7256cf7bd0fb6d9955a75c580cb8"
end
resource "localstack-ext" do
url "https://files.pythonhosted.org/packages/63/d0/68d38e712e166b487d8ec34288e1451f211d7ab5d6a489b2d05b60f41cd0/localstack-ext-0.11.43.6.tar.gz"
sha256 "65a74045918b9ec6de25a0dcf5d1f322b7ae00e09e047485c80962389cd1c499"
end
resource "pyaes" do
url "https://files.pythonhosted.org/packages/44/66/2c17bae31c906613795711fc78045c285048168919ace2220daa372c7d72/pyaes-1.6.1.tar.gz"
sha256 "02c1b1405c38d3c370b085fb952dd8bea3fadcee6411ad99f312cc129c536d8f"
end
resource "python-dateutil" do
url "https://files.pythonhosted.org/packages/be/ed/5bbc91f03fa4c839c4c7360375da77f9659af5f7086b7a7bdda65771c8e0/python-dateutil-2.8.1.tar.gz"
sha256 "73ebfe9dbf22e832286dafa60473e4cd239f8592f699aa5adaf10050e6e1823c"
end
resource "requests" do
url "https://files.pythonhosted.org/packages/da/67/672b422d9daf07365259958912ba533a0ecab839d4084c487a5fe9a5405f/requests-2.24.0.tar.gz"
sha256 "b3559a131db72c33ee969480840fff4bb6dd111de7dd27c8ee1f820f4f00231b"
end
resource "s3transfer" do
url "https://files.pythonhosted.org/packages/50/de/2b688c062107942486c81a739383b1432a72717d9a85a6a1a692f003c70c/s3transfer-0.3.3.tar.gz"
sha256 "921a37e2aefc64145e7b73d50c71bb4f26f46e4c9f414dc648c6245ff92cf7db"
end
resource "six" do
url "https://files.pythonhosted.org/packages/6b/34/415834bfdafca3c5f451532e8a8d9ba89a21c9743a0c59fbd0205c7f9426/six-1.15.0.tar.gz"
sha256 "30639c035cdb23534cd4aa2dd52c3bf48f06e5f4a941509c8bafd8ce11080259"
end
resource "urllib3" do
url "https://files.pythonhosted.org/packages/76/d9/bbbafc76b18da706451fa91bc2ebe21c0daf8868ef3c30b869ac7cb7f01d/urllib3-1.25.11.tar.gz"
sha256 "8d7eaa5a82a1cac232164990f04874c594c9453ec55eef02eab885aa02fc17a2"
end
def install
virtualenv_install_with_resources
end
test do
ENV["DOCKER_HOST"] = "unix://" + (testpath/"invalid.sock")
assert_match version.to_s, shell_output("#{bin}/localstack --version")
output = shell_output("#{bin}/localstack start --docker", 125)
assert_match "Starting local dev environment", output
assert_match "Cannot connect to the Docker daemon", output
end
end