Skip to content

Commit

Permalink
lowered threshold to use EFS, updated gems, added dockerignore, modif…
Browse files Browse the repository at this point in the history
…ied ecr-push to use docker buildx
  • Loading branch information
genschmitt committed Aug 26, 2024
1 parent 2900351 commit 7e33503
Show file tree
Hide file tree
Showing 4 changed files with 34 additions and 20 deletions.
10 changes: 10 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
# Git
/.git
/.idea

# Docker
/Dockerfile

# Application
/ecr-push.sh
README.*
40 changes: 22 additions & 18 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -2,43 +2,46 @@ GEM
remote: https://rubygems.org/
specs:
aws-eventstream (1.3.0)
aws-partitions (1.940.0)
aws-sdk-core (3.197.0)
aws-partitions (1.968.0)
aws-sdk-core (3.201.5)
aws-eventstream (~> 1, >= 1.3.0)
aws-partitions (~> 1, >= 1.651.0)
aws-sigv4 (~> 1.8)
aws-sigv4 (~> 1.9)
jmespath (~> 1, >= 1.6.1)
aws-sdk-kms (1.83.0)
aws-sdk-core (~> 3, >= 3.197.0)
aws-sigv4 (~> 1.1)
aws-sdk-s3 (1.151.0)
aws-sdk-core (~> 3, >= 3.194.0)
aws-sdk-kms (1.88.0)
aws-sdk-core (~> 3, >= 3.201.0)
aws-sigv4 (~> 1.5)
aws-sdk-s3 (1.159.0)
aws-sdk-core (~> 3, >= 3.201.0)
aws-sdk-kms (~> 1)
aws-sigv4 (~> 1.8)
aws-sdk-sqs (1.74.0)
aws-sdk-core (~> 3, >= 3.193.0)
aws-sigv4 (~> 1.1)
aws-sigv4 (1.8.0)
aws-sigv4 (~> 1.5)
aws-sdk-sqs (1.80.0)
aws-sdk-core (~> 3, >= 3.201.0)
aws-sigv4 (~> 1.5)
aws-sigv4 (1.9.1)
aws-eventstream (~> 1, >= 1.0.2)
config (5.5.1)
deep_merge (~> 1.2, >= 1.2.1)
deep_merge (1.2.2)
docile (1.4.0)
docile (1.4.1)
ffi (1.17.0-arm64-darwin)
ffi (1.17.0-x86_64-darwin)
ffi-libarchive (1.1.14)
ffi (~> 1.0)
jmespath (1.6.2)
mime-types (3.5.2)
mime-types-data (~> 3.2015)
mime-types-data (3.2024.0507)
mime-types-data (3.2024.0820)
mimemagic (0.3.10)
nokogiri (~> 1)
rake
minitest (5.23.1)
nokogiri (1.16.5-x86_64-darwin)
minitest (5.25.1)
nokogiri (1.16.7-arm64-darwin)
racc (~> 1.4)
nokogiri (1.16.7-x86_64-darwin)
racc (~> 1.4)
os (1.1.4)
racc (1.8.0)
racc (1.8.1)
rake (13.2.1)
rubyzip (2.3.2)
simplecov (0.22.0)
Expand All @@ -49,6 +52,7 @@ GEM
simplecov_json_formatter (0.1.4)

PLATFORMS
arm64-darwin-23
x86_64-darwin-21

DEPENDENCIES
Expand Down
2 changes: 1 addition & 1 deletion ecr-push.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,6 @@
#

aws ecr get-login-password --region us-east-2 | docker login --username AWS --password-stdin 721945215539.dkr.ecr.us-east-2.amazonaws.com
docker build -t databank-archive-extractor-prod .
docker buildx build -t databank-archive-extractor-prod .
docker tag databank-archive-extractor-prod:latest 721945215539.dkr.ecr.us-east-2.amazonaws.com/databank-archive-extractor-prod:latest
docker push 721945215539.dkr.ecr.us-east-2.amazonaws.com/databank-archive-extractor-prod:latest
2 changes: 1 addition & 1 deletion lib/archive_extractor.rb
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ def get_storage_path
})
object_size = resp.object_size
LOGGER.info("#{@web_id} size: #{object_size}")
object_size > 19 * GIGABYTE ? Settings.aws.efs.mount_point : Settings.ephemeral_storage_path
object_size > 15 * GIGABYTE ? Settings.aws.efs.mount_point : Settings.ephemeral_storage_path
end

def get_object(local_path, error)
Expand Down

0 comments on commit 7e33503

Please sign in to comment.