gz_release 0.0.6 → 0.0.7

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,15 +1,15 @@
1
1
  ---
2
2
  !binary "U0hBMQ==":
3
3
  metadata.gz: !binary |-
4
- OTM1NmY3OTkyNzJkY2IzOWZmZTIyOGRmOWJkYTI1YzFjNmIxMjNkYw==
4
+ ZjUwZDE2YTgzZmUyNGZkYzRkMzJmZmRhYjI2YzIzZmVmNWU3Y2I1Ng==
5
5
  data.tar.gz: !binary |-
6
- ZGE3YzZjMzIzM2FmNDE0ZjNhZTNmNDhjYzdhOGE2MzZiM2YwMzc4OA==
6
+ NWJmN2Q0YjYzNjFhYmNjNWE3MTU1NmExMDI1YTU1NWZlMGEyZmRiZg==
7
7
  SHA512:
8
8
  metadata.gz: !binary |-
9
- NDVlNjdhZTY0ZGIyZTViZDkyOWRhNjEzMzk1MWE4YWYxZTUwYzU3OTgzMTI4
10
- YTEwOWRiMzI0OTBhNTg1MzExMWI1OTUzYTkxYzgzMzc4NmRhY2RhMjYzZTg0
11
- ZjA3NTllODE3MjkwZDhjMzFiMzQyZjk1NjU0YWQxMWVmOTE3MWM=
9
+ MjVmZGRlZjM1OWIxMGFjN2EyZGI2NDQxNjk3MWUxZjEyZmMwMDI5MzE4YmQw
10
+ ZjgzYzI1ZDQ1ZmFhZDg3YTYwZjNjYWQxOWQyZTUxNDQzNWE5OWQ4ZGY4ODQ0
11
+ ZjA5NzhkYzhhNjI0ZTg1M2ZhYTM3MDY4YzE4MDMxMDMyN2JlZTU=
12
12
  data.tar.gz: !binary |-
13
- OWE5ZGFlYzAzMWNhODhkZmI2OTA5MzQxNjg4Mzg5ZGYwYjE1ZjgxNTgwYjk3
14
- ODYwOGI2MzdkNzExM2JjZjAyNjY1NjdjNjJhODczNmFmZjc1YjcyYjQ0Y2I1
15
- YzdlZTk1ZDgzNWY1NDBlZTVmYTg5ZTM0YWQ5M2M4MGRmZWZmNDE=
13
+ Mjk3YzhjODljNjMzMTIzZjlhYmIzNWI1YmFiZmRhMTU5OTM4ZTE1OWY0ZmIw
14
+ NjkzNzE5ZmM2Zjg0YTE5YjRhZTAwMDM3ZDljMWRmNDdmMDdlNGNiOTA2ODgz
15
+ MzY1ZTZkMjY3NWQ2ODg2NDEzYzk0MGEzODdiODcwZTM5NzcyZTU=
@@ -16,7 +16,7 @@ module GzRelease
16
16
  end
17
17
  end
18
18
 
19
- attr_reader :image_name, :version
19
+ attr_reader :version
20
20
 
21
21
  def initialize(options = {})
22
22
  @image_name, @version = options.values_at(:image_name, :version)
@@ -133,7 +133,7 @@ module GzRelease
133
133
  errors << 'Missing DOCKER_PASSWORD environment variable.' unless password
134
134
  raise BuildError, "Encountered the following errors:\n #{errors.join("\n")}" if errors.any?
135
135
 
136
- run("docker login -e #{email} -u #{user} -p #{password}", display_command: false)
136
+ run("docker login -e #{email} -u #{user} -p #{password} #{docker_repository}", display_command: false)
137
137
  end
138
138
 
139
139
  def run(command, options = {display_command: true})
@@ -143,6 +143,14 @@ module GzRelease
143
143
  raise BuildError, 'There was a problem executing this command.' unless $CHILD_STATUS == 0
144
144
  end
145
145
 
146
+ def image_name
147
+ "#{docker_repository}/#{@image_name}"
148
+ end
149
+
150
+ def docker_repository
151
+ ENV['DOCKER_REPOSITORY'] || ''
152
+ end
153
+
146
154
  # SHA
147
155
  def image_sha
148
156
  "#{image_name}:#{sha}"
@@ -1,4 +1,4 @@
1
1
  # Version
2
2
  module GzRelease
3
- VERSION = '0.0.6'
3
+ VERSION = '0.0.7'
4
4
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gz_release
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.6
4
+ version: 0.0.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - Allen Madsen