3scale toolbox giving error whenever used --config-file option to store remote instances

Solution Verified - Updated -

Issue

  • Would like to persist remote access credentials for 3scale toolbox docker container
  • I have tried the following command:

    docker run local.docker.registry:xxxx/3scale-amp2/toolbox-rhel7:3scale2.7 3scale remote add saas     https://{access_token}@3scale-{admin-domain} -k --config-file  /opt/.3scalerc.yaml
    
  • I am experiencing the following error:

    ===== MESSAGE:
    
    Errno::EACCES: Permission denied @ rb_sysopen - /opt/.3scalerc.yaml
    
    ===== BACKTRACE:
    
    /opt/rh/rh-ruby25/root/usr/share/ruby/pstore.rb:389:in `initialize'
    /opt/rh/rh-ruby25/root/usr/share/ruby/pstore.rb:389:in `new'
    /opt/rh/rh-ruby25/root/usr/share/ruby/pstore.rb:389:in `open_and_lock_file'
    /opt/rh/rh-ruby25/root/usr/share/ruby/pstore.rb:325:in `transaction'
    /opt/toolbox/lib/3scale_toolbox/configuration.rb:19:in `update'
    /opt/toolbox/lib/3scale_toolbox/remotes.rb:67:in `update'
    /opt/toolbox/lib/3scale_toolbox/remotes.rb:33:in `add'
    /opt/toolbox/lib/3scale_toolbox/remotes.rb:29:in `add_uri'
    /opt/toolbox/lib/3scale_toolbox/commands/remote_command/remote_add.rb:42:in `add_remote'
    /opt/toolbox/lib/3scale_toolbox/commands/remote_command/remote_add.rb:21:in `run'
    /opt/toolbox/vendor/bundle/ruby/2.5.0/gems/cri-2.15.9/lib/cri/command_runner.rb:34:in `call'
    /opt/toolbox/vendor/bundle/ruby/2.5.0/gems/cri-2.15.9/lib/cri/command_dsl.rb:303:in `block in runner'
    /opt/toolbox/vendor/bundle/ruby/2.5.0/gems/cri-2.15.9/lib/cri/command.rb:360:in `run_this'
    /opt/toolbox/vendor/bundle/ruby/2.5.0/gems/cri-2.15.9/lib/cri/command.rb:296:in `run'
    /opt/toolbox/vendor/bundle/ruby/2.5.0/gems/cri-2.15.9/lib/cri/command.rb:314:in `run'
    /opt/toolbox/vendor/bundle/ruby/2.5.0/gems/cri-2.15.9/lib/cri/command.rb:314:in `run'
    /opt/toolbox/lib/3scale_toolbox/cli.rb:43:in `block in run'
    /opt/toolbox/lib/3scale_toolbox/cli/error_handler.rb:5:in `block in error_watchdog'
    /opt/toolbox/lib/3scale_toolbox/cli/error_handler.rb:11:in `error_watchdog'
    /opt/toolbox/lib/3scale_toolbox/cli/error_handler.rb:5:in `error_watchdog'
    /opt/toolbox/lib/3scale_toolbox/cli.rb:40:in `run'
    /opt/toolbox/exe/3scale:15:in `<top (required)>'
    /opt/toolbox/bin/3scale:29:in `load'
    /opt/toolbox/bin/3scale:29:in `<main>'
    /opt/toolbox/lib/3scale_toolbox/cli/error_handler.rb:42:in `initialize': Permission denied @ rb_sysopen -     crash.log (Errno::EACCES)
            from /opt/toolbox/lib/3scale_toolbox/cli/error_handler.rb:42:in `open'
            from /opt/toolbox/lib/3scale_toolbox/cli/error_handler.rb:42:in `print_error'
            from /opt/toolbox/lib/3scale_toolbox/cli/error_handler.rb:26:in `handle_error'
            from /opt/toolbox/lib/3scale_toolbox/cli/error_handler.rb:13:in `rescue in error_watchdog'
            from /opt/toolbox/lib/3scale_toolbox/cli/error_handler.rb:9:in `error_watchdog'
            from /opt/toolbox/lib/3scale_toolbox/cli/error_handler.rb:5:in `error_watchdog'
            from /opt/toolbox/lib/3scale_toolbox/cli.rb:40:in `run'
            from /opt/toolbox/exe/3scale:15:in `<top (required)>'
            from /opt/toolbox/bin/3scale:29:in `load'
            from /opt/toolbox/bin/3scale:29:in `<main>'
    
  • Please suggest a solution.

Environment

  • Red Hat 3scale API Management 2.7.0 On-premises

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase of over 48,000 articles and solutions.

Current Customers and Partners

Log in for full access

Log In