Skip to content
This repository has been archived by the owner on Jul 6, 2022. It is now read-only.

ovirt-flexvolume-driver-apb deployment fails with DEPRECATED: APB playbooks should be stored at /opt/apb/project #66

Closed
jirib opened this issue Sep 14, 2018 · 4 comments

Comments

@jirib
Copy link

jirib commented Sep 14, 2018

Describe the bug

ovirt-flexvolume-driver-apb fails with DEPRECATED: APB playbooks should be stored at /opt/apb/project

+ docker run --rm --net=host -v /root/.kube:/opt/apb/.kube:z -u 0 quay.io/rgolangh/ovirt-flexvolume-driver-apb provision -e admin_password=pass -e admin_user=developer -e cluster=openshift -e namespace=default -e engine_password=xxxxxx -e engine_url=https://example.com/ovirt-engine/api -e engine_username=admin@internal
Unable to find image 'quay.io/rgolangh/ovirt-flexvolume-driver-apb:latest' locally
Trying to pull repository quay.io/rgolangh/ovirt-flexvolume-driver-apb ...
latest: Pulling from quay.io/rgolangh/ovirt-flexvolume-driver-apb
7dc0dca2b151: Pull complete
1bdeea372afe: Pull complete
18396704926e: Pull complete
12618e5abaa7: Pull complete
ff4473a53327: Pull complete
8f96e52a9ad7: Pull complete
ebd533f3c4f0: Pull complete
d5eb5f5ecfed: Pull complete
a3e752816294: Pull complete
70c9ec9f8393: Pull complete
81c5ed045aa5: Pull complete
a9d8b6cd6df2: Pull complete
343d3e7398d7: Pull complete
8d5dfb34a1b3: Pull complete
b42c142b7817: Pull complete
Digest: sha256:fbd052207f936cf89b291e5eaf9600cccd34a7bff36909428a350d0027424c8a
Status: Downloaded newer image for quay.io/rgolangh/ovirt-flexvolume-driver-apb:latest
DEPRECATED: APB playbooks should be stored at /opt/apb/project
Usage: ansible-playbook [options] playbook.yml [playbook2 ...]

Runs Ansible playbooks, executing the defined tasks on the targeted hosts.

Options:
  --ask-vault-pass      ask for vault password
  -C, --check           don't make any changes; instead, try to predict some
                        of the changes that may occur
  -D, --diff            when changing (small) files and templates, show the
                        differences in those files; works great with --check
  -e EXTRA_VARS, --extra-vars=EXTRA_VARS
                        set additional variables as key=value or YAML/JSON, if
                        filename prepend with @
  --flush-cache         clear the fact cache for every host in inventory
  --force-handlers      run handlers even if a task fails
  -f FORKS, --forks=FORKS
                        specify number of parallel processes to use
                        (default=5)
  -h, --help            show this help message and exit
  -i INVENTORY, --inventory=INVENTORY, --inventory-file=INVENTORY
                        specify inventory host path or comma separated host
                        list. --inventory-file is deprecated

  -l SUBSET, --limit=SUBSET
                        further limit selected hosts to an additional pattern
  --list-hosts          outputs a list of matching hosts; does not execute
                        anything else
  --list-tags           list all available tags
  --list-tasks          list all tasks that would be executed
  -M MODULE_PATH, --module-path=MODULE_PATH
                        prepend colon-separated path(s) to module library
                        (default=[u'/opt/apb/.ansible/plugins/modules',
                        u'/usr/share/ansible/plugins/modules'])
  --skip-tags=SKIP_TAGS
                        only run plays and tasks whose tags do not match these
                        values
  --start-at-task=START_AT_TASK
                        start the playbook at the task matching this name
  --step                one-step-at-a-time: confirm each task before running
  --syntax-check        perform a syntax check on the playbook, but do not
                        execute it
  -t TAGS, --tags=TAGS  only run plays and tasks tagged with these values
  --vault-id=VAULT_IDS  the vault identity to use
  --vault-password-file=VAULT_PASSWORD_FILES
                        vault password file
  -v, --verbose         verbose mode (-vvv for more, -vvvv to enable
                        connection debugging)
  --version             show program's version number and exit

  Connection Options:
    control as whom and how to connect to hosts

    -k, --ask-pass      ask for connection password
    --private-key=PRIVATE_KEY_FILE, --key-file=PRIVATE_KEY_FILE
                        use this file to authenticate the connection
    -u REMOTE_USER, --user=REMOTE_USER
                        connect as this user (default=None)
    -c CONNECTION, --connection=CONNECTION
                        connection type to use (default=smart)
    -T TIMEOUT, --timeout=TIMEOUT
                        override the connection timeout in seconds

                        (default=10)
    --ssh-common-args=SSH_COMMON_ARGS
                        specify common arguments to pass to sftp/scp/ssh (e.g.
                        ProxyCommand)
    --sftp-extra-args=SFTP_EXTRA_ARGS
                        specify extra arguments to pass to sftp only (e.g. -f,
                        -l)
    --scp-extra-args=SCP_EXTRA_ARGS
                        specify extra arguments to pass to scp only (e.g. -l)
    --ssh-extra-args=SSH_EXTRA_ARGS
                        specify extra arguments to pass to ssh only (e.g. -R)

  Privilege Escalation Options:
    control how and which user you become as on target hosts

    -s, --sudo          run operations with sudo (nopasswd) (deprecated, use
                        become)
    -U SUDO_USER, --sudo-user=SUDO_USER
                        desired sudo user (default=root) (deprecated, use
                        become)
    -S, --su            run operations with su (deprecated, use become)
    -R SU_USER, --su-user=SU_USER
                        run operations with su as this user (default=None)
                        (deprecated, use become)
    -b, --become        run operations with become (does not imply password
                        prompting)
    --become-method=BECOME_METHOD
                        privilege escalation method to use (default=sudo),
                        valid choices: [ sudo | su | pbrun | pfexec | doas |
                        dzdo | ksu | runas | pmrun | enable | machinectl ]
    --become-user=BECOME_USER
                        run operations as this user (default=root)
    --ask-sudo-pass     ask for sudo password (deprecated, use become)
    --ask-su-pass       ask for su password (deprecated, use become)
    -K, --ask-become-pass
                        ask for privilege escalation password
ERROR! Invalid extra vars data supplied. '@/opt/apb/env/extravars' could not be made into a dictionary

To Reproduce
Steps to reproduce the behavior:

  1. docker run --rm --net=host -v /root/.kube:/opt/apb/.kube:z -u 0 quay.io/rgolangh/ovirt-flexvolume-driver-apb provision -e admin_password=pass -e admin_user=developer -e cluster=openshift -e namespace=default -e engine_password=xxxxxx -e engine_url=https://example.com/ovirt-engine/api -e engine_username=admin@internal

Expected behavior
deployment should finish

Versions (please complete the following information):

  • OS: Red Hat Enterprise Linux Server release 7.5 (Maipo)
  • Openshift|kubernetes version:
oc v3.10.34
kubernetes v1.10.0+b81c8f8
features: Basic-Auth GSSAPI Kerberos SPNEGO

Server https://lb0.example.com:8443
openshift v3.10.34
kubernetes v1.10.0+b81c8f8
  • oVirt version: ovirt-engine-4.2.6.4-0.1.el7ev.noarch
@jirib jirib changed the title ovirt-flexvolume-driver-apb fails with DEPRECATED: APB playbooks should be stored at /opt/apb/project ovirt-flexvolume-driver-apb deployment fails with DEPRECATED: APB playbooks should be stored at /opt/apb/project Sep 14, 2018
@rgolangh
Copy link
Contributor

rgolangh commented Sep 16, 2018

Looks like this change in apb broke it:
ansibleplaybookbundle/apb-base#46

Replacing every -e key1=value1 -e key2=value2 to one big json string '{"key1":"value1", "key2":"value2"} solves this.

@rgolangh
Copy link
Contributor

rgolangh commented Sep 16, 2018

Can you try:

docker run --rm --net=host -v /root/.kube:/opt/apb/.kube:z -u 0 quay.io/rgolangh/ovirt-flexvolume-driver-apb provision '{"admin_password":"pass","admin_user":"developer","cluster":"openshift","namespace":"default","engine_password":"xxxxxx","engine_url":"https://example.com/ovirtngine/api","engine_username":"admin@internal"}'

@jirib
Copy link
Author

jirib commented Sep 17, 2018

Still fails, I tried with:

docker run \
 --rm \
 --net=host \
 -v $HOME/.kube:/opt/apb/.kube:z \
 -u $UID quay.io/rgolangh/ovirt-flexvolume-driver-apb \
 provision \
'{"admin_password":"pass","admin_user":"developer","cluster":"openshift","namespace":"default","engine_password":"xxxxxxx","engine_url":"https://example.com/ovirt-engine/api","engine_username":"admin@internal"}'

@rgolangh
Copy link
Contributor

rgolangh commented Sep 17, 2018

After reading their code I see they expect another flag, so just add after provision, --extra-args and then the rest of the json string

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants