fastlane-plugin-blackberry_mam 1.0.0 → 1.1.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 29818af27a8703ac3622e1fc30c973b3f0fe61ab
4
- data.tar.gz: a122a5211d65bb89f6f7c21baa7390bff5420bb6
3
+ metadata.gz: 4b558e182a605cc507a29caaacad57e5ad0d283a
4
+ data.tar.gz: 9a511933fdf36606755b27c8dda3362ca30752f3
5
5
  SHA512:
6
- metadata.gz: 698f461004132c85f4fd17ead3a3124886d08ba280c4b6d29fef8ea24c03cbc846c895a67b776e97640ca080ccd165551f3c32fb4cc4b7f95b882f70a0a2b37d
7
- data.tar.gz: 8da3bfc6fe635dd14cf3536a85361f77dc6ad92655597ad4e5fe29c6f101ba16b47a703ef4fd82940a1006c07e2845587a9da2c1daa22cf3208be9234d6e9ced
6
+ metadata.gz: 8ff4d00c210bfeaf1ebbd59d915d0f625e72f7fb626f3b89881df7838d302e8ddd79283211a1635d7e1a60790e25cde9cc0f159aa2acaf2a6e6647036c31ee33
7
+ data.tar.gz: a62af2961bd10a52b02891fd98ed27fbba2dcfb33e40783c5528bd3e3ca6f8546cd0b4bff9319469607472b7669bbbc08ee14e64340319ae9971b12417559987
data/README.md CHANGED
@@ -12,16 +12,17 @@ fastlane add_plugin blackberry_mam
12
12
 
13
13
  ## About blackberry_mam
14
14
 
15
- A fastlane plugin that works with Blackberry Dynamics (formerly Good Dynamics) provides Mobile Application Management
15
+ A fastlane plugin that works with Blackberry Dynamics (formerly Good Dynamics) provides Mobile Application Management. It includes
16
+ the following actions:
16
17
 
17
- **Note to author:** Add a more detailed description about this plugin here. If your plugin contains multiple actions, make sure to mention them here.
18
+ - blackberry_mam_network_check: checks to see if the required network ports for BlackBerry Dynamics are open on the network
19
+ - blackberry_mam_version_action: checks the version of the installed Good framework
20
+ - update_info_plist_for_blackberry_mam: updates the plist so that the built application can be deployed and managed within BlackBerry's Good Dynamics Control Center for Enterprise Mobility Management
18
21
 
19
22
  ## Example
20
23
 
21
24
  Check out the [example `Fastfile`](fastlane/Fastfile) to see how to use this plugin. Try it by cloning the repo, running `fastlane install_plugins` and `bundle exec fastlane test`.
22
25
 
23
- **Note to author:** Please set up a sample project to make it easy for users to explore what your plugin does. Provide everything that is necessary to try out the plugin in this project (including a sample Xcode/Android project if necessary)
24
-
25
26
  ## Run tests for this plugin
26
27
 
27
28
  To run both the tests, and code style validation, run
@@ -0,0 +1,107 @@
1
+ module Fastlane
2
+ module Actions
3
+ class BlackberryMamNetworkCheckAction < Action
4
+ require 'socket'
5
+ require 'timeout'
6
+
7
+ def self.run(params)
8
+ are_all_connections_open = true
9
+ connections = [
10
+ {
11
+ address: 'bxcheckin.good.com',
12
+ port: '443'
13
+ },
14
+ {
15
+ address: 'bxenroll.good.com',
16
+ port: '443'
17
+ },
18
+ {
19
+ address: 'gdentgw.good.com',
20
+ port: '443'
21
+ },
22
+ {
23
+ address: 'gdmdc.good.com',
24
+ port: '443'
25
+ },
26
+ {
27
+ address: 'gdmdc.good.com',
28
+ port: '49152'
29
+ },
30
+ {
31
+ address: 'gdrelay.good.com',
32
+ port: '443'
33
+ },
34
+ {
35
+ address: 'gdrelay.good.com',
36
+ port: '15000'
37
+ },
38
+ {
39
+ address: 'gdweb.good.com',
40
+ port: '443'
41
+ }
42
+ ]
43
+ connections << { address: 'gdcloudgc.good.com', port: '49160' } if params[:check_cloud_control]
44
+
45
+ connections.each do |connection|
46
+ is_open = is_port_open?(connection[:address], connection[:port])
47
+ are_all_connections_open &&= is_open
48
+ UI.message("Checking #{connection[:address]}:#{connection[:port]}: #{is_open ? '✅' : '❌'}")
49
+ end
50
+ are_all_connections_open
51
+ end
52
+
53
+ def self.is_port_open?(ip, port)
54
+ begin
55
+ Timeout.timeout(1) do
56
+ begin
57
+ s = TCPSocket.new(ip, port)
58
+ s.close
59
+ return true
60
+ rescue Errno::ECONNREFUSED, Errno::EHOSTUNREACH
61
+ return false
62
+ end
63
+ end
64
+ rescue Timeout::Error
65
+ end
66
+
67
+ return false
68
+ end
69
+
70
+ #####################################################
71
+ # @!group Documentation
72
+ #####################################################
73
+
74
+ def self.description
75
+ "Checks to see if the required network ports for BlackBerry Dynamics are open on the network"
76
+ end
77
+
78
+ def self.details
79
+ "Make sure that devices and iOS Simulators can connect via your network to BlackBerry Dynamics Servers."
80
+ end
81
+
82
+ def self.available_options
83
+ [
84
+ FastlaneCore::ConfigItem.new(
85
+ key: :check_cloud_control,
86
+ env_name: "FL_BLACKBERRY_MAM_NETWORK_CHECK_CLOUD_CONTROL",
87
+ description: "API Token for BlackberryMamNetworkCheckAction",
88
+ type: TrueClass,
89
+ default_value: true
90
+ )
91
+ ]
92
+ end
93
+
94
+ def self.return_value
95
+ 'True if network ports for BlackBerry Dynamics servers are open. False otherwise.'
96
+ end
97
+
98
+ def self.authors
99
+ ["lyndsey-ferguson/@ldferguson"]
100
+ end
101
+
102
+ def self.is_supported?(platform)
103
+ platform == :ios
104
+ end
105
+ end
106
+ end
107
+ end
@@ -69,7 +69,7 @@ module Fastlane
69
69
  #####################################################
70
70
 
71
71
  def self.description
72
- "This plugin will update the plist so that the built application can be deployed and managed within BlackBerry's Good Dynamics Control Center for Enterprise Mobility Management."
72
+ "updates the plist so that the built application can be deployed and managed within BlackBerry's Good Dynamics Control Center for Enterprise Mobility Management."
73
73
  end
74
74
 
75
75
  def self.available_options
@@ -1,5 +1,5 @@
1
1
  module Fastlane
2
2
  module BlackberryMam
3
- VERSION = "1.0.0"
3
+ VERSION = "1.1.0"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fastlane-plugin-blackberry_mam
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0
4
+ version: 1.1.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Lyndsey Ferguson
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-04-26 00:00:00.000000000 Z
11
+ date: 2017-11-17 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: pry
@@ -24,6 +24,20 @@ dependencies:
24
24
  - - ">="
25
25
  - !ruby/object:Gem::Version
26
26
  version: '0'
27
+ - !ruby/object:Gem::Dependency
28
+ name: pry-byebug
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - ">="
32
+ - !ruby/object:Gem::Version
33
+ version: '0'
34
+ type: :development
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - ">="
39
+ - !ruby/object:Gem::Version
40
+ version: '0'
27
41
  - !ruby/object:Gem::Dependency
28
42
  name: bundler
29
43
  requirement: !ruby/object:Gem::Requirement
@@ -95,7 +109,7 @@ dependencies:
95
109
  - !ruby/object:Gem::Version
96
110
  version: 2.28.3
97
111
  description:
98
- email: lyndsey.ferguson@gmail.com
112
+ email: ldf.public+github@outlook.com
99
113
  executables: []
100
114
  extensions: []
101
115
  extra_rdoc_files: []
@@ -103,6 +117,7 @@ files:
103
117
  - LICENSE
104
118
  - README.md
105
119
  - lib/fastlane/plugin/blackberry_mam.rb
120
+ - lib/fastlane/plugin/blackberry_mam/actions/blackberry_mam_network_check.rb
106
121
  - lib/fastlane/plugin/blackberry_mam/actions/blackberry_mam_version_action.rb
107
122
  - lib/fastlane/plugin/blackberry_mam/actions/update_info_plist_for_blackberry_mam_action.rb
108
123
  - lib/fastlane/plugin/blackberry_mam/version.rb
@@ -126,9 +141,10 @@ required_rubygems_version: !ruby/object:Gem::Requirement
126
141
  version: '0'
127
142
  requirements: []
128
143
  rubyforge_project:
129
- rubygems_version: 2.5.2
144
+ rubygems_version: 2.6.11
130
145
  signing_key:
131
146
  specification_version: 4
132
147
  summary: A fastlane plugin that works with Blackberry Dynamics (formerly Good Dynamics)
133
148
  provides Mobile Application Management
134
149
  test_files: []
150
+ has_rdoc: