Bugzilla will be upgraded to version 5.0. The upgrade date is tentatively scheduled for 2 December 2018, pending final testing and feedback.
Bug 1538969 - [APB] The apb tool should support display version info
[APB] The apb tool should support display version info
Status: CLOSED ERRATA
Product: OpenShift Container Platform
Classification: Red Hat
Component: Service Broker (Show other bugs)
3.9.0
Unspecified Unspecified
medium Severity medium
: ---
: 3.9.0
Assigned To: Dylan Murray
Jian Zhang
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2018-01-26 04:48 EST by Jian Zhang
Modified: 2018-03-28 10:23 EDT (History)
3 users (show)

See Also:
Fixed In Version:
Doc Type: No Doc Update
Doc Text:
undefined
Story Points: ---
Clone Of:
Environment:
Last Closed: 2018-03-28 10:23:11 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)


External Trackers
Tracker ID Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2018:0489 None None None 2018-03-28 10:23 EDT

  None (edit)
Comment 1 Dylan Murray 2018-01-30 11:44:27 EST
Need to update the build scripts to set the version as a global veriable to do this properly. Will have a PR tomorrow printing this out once I get acclimated to the build process.
Comment 2 Dylan Murray 2018-01-31 10:50:35 EST
https://github.com/ansibleplaybookbundle/ansible-playbook-bundle/pull/219

Didn't have to mess with the build scripts to get this working thankfully.

You can now do `apb version` and it will print out the current version.
Comment 4 Jian Zhang 2018-02-04 21:03:47 EST
1, RPM installation:
[root@localhost jzhang]# rpm -qa|grep apb
apb-1.1.7-1.20180202175805.el7.centos.noarch
[root@localhost jzhang]# apb --help
usage: apb [-h] [--debug] [--project BASE_PATH]
           {relist,run,help,test,prepare,setup,bootstrap,list,remove,init,version,build,push,serviceinstance}
           ...

APB tooling for assisting in building and packaging APBs.

optional arguments:
  -h, --help            show this help message and exit
  --debug               Enable debug output
  --project BASE_PATH, -p BASE_PATH
                        Specify a path to your project. Defaults to CWD.

subcommand:
  {relist,run,help,test,prepare,setup,bootstrap,list,remove,init,version,build,push,serviceinstance}
    relist              Relist the APBs available within the Service Catalog
    run                 Run APB
    help                Display this help message
    test                Test the APB
    prepare             Prepare an ansible-container project for APB packaging
    setup               Initialize OpenShift with APB development environment
    bootstrap           Tell Ansible Service Broker to reload APBs from the
                        container repository
    list                List APBs from the target Ansible Service Broker
    remove              Remove APBs from the target Ansible Service Broker
    init                Initialize the directory for APB development
    version             Get current version of APB tool
    build               Build and package APB container
    push                Push local APB spec to an Ansible Service Broker
    serviceinstance     Create a ServiceInstance template based on apb.yaml

[root@localhost jzhang]# apb version
Version: apb-1.1.7

2, Running apb from a container:
[root@host-172-16-120-78 ~]# apb --help
groupadd: GID '0' already exists
usermod: group 'apb' does not exist
usage: apb [-h] [--debug] [--project BASE_PATH]
           
           {relist,run,help,test,prepare,setup,bootstrap,list,remove,init,version,build,push,serviceinstance}
           ...

APB tooling for assisting in building and packaging APBs.

optional arguments:
  -h, --help            show this help message and exit
  --debug               Enable debug output
  --project BASE_PATH, -p BASE_PATH
                        Specify a path to your project. Defaults to CWD.

subcommand:
  {relist,run,help,test,prepare,setup,bootstrap,list,remove,init,version,build,push,serviceinstance}
    relist              Relist the APBs available within the Service Catalog
    run                 Run APB
    help                Display this help message
    test                Test the APB
    prepare             Prepare an ansible-container project for APB packaging
    setup               Initialize OpenShift with APB development environment
    bootstrap           Tell Ansible Service Broker to reload APBs from the
                        container repository
    list                List APBs from the target Ansible Service Broker
    remove              Remove APBs from the target Ansible Service Broker
    init                Initialize the directory for APB development
    version             Get current version of APB tool
    build               Build and package APB container
    push                Push local APB spec to an Ansible Service Broker
    serviceinstance     Create a ServiceInstance template based on apb.yaml

[root@host-172-16-120-78 ~]# apb version
groupadd: GID '0' already exists
usermod: group 'apb' does not exist
Version: apb-1.1.7

The subcomamnd "version" works well! LGTM.
Comment 7 errata-xmlrpc 2018-03-28 10:23:11 EDT
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2018:0489

Note You need to log in before you can comment on or make changes to this bug.