openvcloud / 0-templates

Apache License 2.0
1 stars 5 forks source link

Can't create account with not expired jwt #102

Closed Dinaamagdy closed 6 years ago

Dinaamagdy commented 6 years ago

issue

use `j.clients.itsyouonline.get(instance="main").jwt to generate token , it returns token not expired but it result the following error through run create account blueprint

 can't be refreshed. Please choose another refreshable token
[Wed11 11:16] - IYOFactory.py     :29  :j.clients.itsyouonline - INFO     - Specified token can't be refreshed. Please choose another refreshable token
[Wed11 11:16] - OVCClient.py      :84  :-sto-en01-001.gig.tech - INFO     - Get OpenvCloud client on URL: se-sto-en01-001.gig.tech

Blueprint

services:
  - github.com/openvcloud/0-templates/sshkey/0.0.1__0ba6b62c:
       name: '68cf7148'
       dir: '/root/.ssh/'
       passphrase: '78543f84'
  - github.com/openvcloud/0-templates/openvcloud/0.0.1__8a8b2ba7:
      name: 'se-sto-en01-001.gig.tech'
      address: 'se-sto-en01-001.gig.tech'
      login: 'gig_qa_1@itsyouonline'
      token: ''
      location: 'se-gen-1'
  - github.com/openvcloud/0-templates/vdcuser/0.0.1__gig_qa_1:
      provider: itsyouonline
      name: gig_qa_1
      email: dina.magdy.mohammed+123@gmail.com
      openvcloud: 8a8b2ba7
  - github.com/openvcloud/0-templates/vdcuser/0.0.1__7d352066:
      provider: itsyouonline
      name: ddb82100
      groups: ['user']
      email: aed2e01c@test.com
      openvcloud: 8a8b2ba7

  - github.com/openvcloud/0-templates/account/0.0.1__c7ae125b:
      maxDiskCapacity: 26
      name: 241f1f1a
      maxNumPublicIP: 15
      openvcloud: 8a8b2ba7
      users:
        - name: 7d352066
          accesstype: CXDRAU
      maxCPUCapacity: 17
      maxMemoryCapacity: 27
  - github.com/openvcloud/0-templates/account/0.0.1__fa742f80:
      name: 7e77f4e3
      openvcloud: 8a8b2ba7

actions:
  - template: github.com/openvcloud/0-templates/openvcloud/0.0.1
    actions: ['install']
  - template: github.com/openvcloud/0-templates/account/0.0.1
    actions: ['install']
  - template: github.com/openvcloud/0-templates/vdcuser/0.0.1
    actions: ['install']
katia-e commented 6 years ago

@Dinaamagdy , Message about refreshable token seems to be just a log info, it's not an error. I tested it several times and despite this message, I still could install account service, vdc and create a node. I can't recreate the situation when I fail to create an account with valid unrefreshable jwt. Please try it again and let me know if the error keeps reproducing.

For the log message, I'm not sure why this log has to appear for valid tokens, but this is issue of js9, not 0-templates.

Dinaamagdy commented 6 years ago

the log msg still appear on zrobot server but account created successfully