Skip to content

Commit 9f2717a

Browse files
[#426] replaced faker with ffaker in runtime for linux bin
1 parent 578b045 commit 9f2717a

File tree

6 files changed

+9
-5
lines changed

6 files changed

+9
-5
lines changed

Gemfile.lock

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ PATH
44
uffizzi-cli (2.4.16)
55
activesupport
66
awesome_print
7+
ffaker (~> 2.22)
78
launchy
89
minitar
910
open3
@@ -41,6 +42,7 @@ GEM
4142
fakefs (1.8.0)
4243
faker (3.5.1)
4344
i18n (>= 1.8.11, < 2)
45+
ffaker (2.24.0)
4446
hashdiff (1.0.1)
4547
i18n (1.8.11)
4648
concurrent-ruby (~> 1.0)

lib/uffizzi/cli/cluster.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# frozen_string_literal: true
22

33
require 'psych'
4-
require 'faker'
4+
require 'ffaker'
55
require 'uffizzi'
66
require 'uffizzi/auth_helper'
77
require 'uffizzi/helpers/config_helper'

lib/uffizzi/cli/install.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ def helm_set_repo
6464
def build_installation_options(uri)
6565
{
6666
uri: uri,
67-
controller_username: Faker::Lorem.characters(number: 10),
67+
controller_username: FFaker::Lorem.characters(10),
6868
controller_password: generate_password,
6969
cert_email: options[:email],
7070
cluster_issuer: options[:issuer] || InstallService::DEFAULT_CLUSTER_ISSUER,

lib/uffizzi/helpers/project_helper.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# frozen_string_literal: true
22

3-
require 'faker'
3+
require 'ffaker'
44

55
module Uffizzi
66
module ProjectHelper
@@ -34,7 +34,7 @@ def default_description
3434
end
3535

3636
def generate_name
37-
Faker::Lorem.word
37+
FFaker::Lorem.word
3838
end
3939
end
4040
end

lib/uffizzi/services/cluster_service.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ def wait_cluster_scale_down(cluster_name, cluster_api_connection_params)
7575
end
7676

7777
def generate_name
78-
name = Faker::Internet.domain_word[0..CLUSTER_NAME_MAX_LENGTH]
78+
name = FFaker::InternetSE.domain_word[0..CLUSTER_NAME_MAX_LENGTH]
7979

8080
return name if valid_name?(name)
8181

uffizzi.gemspec

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,8 @@ Gem::Specification.new do |spec|
2828

2929
spec.add_dependency 'activesupport'
3030
spec.add_dependency 'awesome_print'
31+
# Added ffaker for runtime because rubyc used for linux bin generation has Ruby version 2.7 and the faker library is incompatible
32+
spec.add_dependency 'ffaker', '~> 2.22'
3133
spec.add_dependency 'launchy'
3234
spec.add_dependency 'minitar'
3335
spec.add_dependency 'open3'

0 commit comments

Comments
 (0)