Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ubuntu Installation of Java 8 example points to Java 10 files #98

Closed
guzmonne opened this issue Oct 16, 2018 · 3 comments · Fixed by #101
Closed

Ubuntu Installation of Java 8 example points to Java 10 files #98

guzmonne opened this issue Oct 16, 2018 · 3 comments · Fixed by #101

Comments

@guzmonne
Copy link

The current example to install Java 8 on Ubuntu with this role says:

- role: ansiblebit.oracle-java
        oracle_java_use_defaults: no
        oracle_java_apt_repository: "ppa:webupd8team/java"
        oracle_java_cache_valid_time: 3600
        oracle_java_deb_package: 'oracle-java10-installer'
        oracle_java_debconf_package_default: 'oracle-java10-set-default'
        oracle_java_home: "/usr/lib/jvm/java-10-oracle"
        oracle_java_set_as_default: no
        oracle_java_state: latest

But it should say:

- role: ansiblebit.oracle-java
        oracle_java_use_defaults: no
        oracle_java_apt_repository: "ppa:webupd8team/java"
        oracle_java_cache_valid_time: 3600
        oracle_java_deb_package: 'oracle-java8-installer'
        oracle_java_debconf_package_default: 'oracle-java8-set-default'
        oracle_java_home: "/usr/lib/jvm/java-8-oracle"
        oracle_java_set_as_default: no
        oracle_java_state: latest
@d4rkd0s
Copy link
Contributor

d4rkd0s commented Oct 19, 2018

@guzmonne I also noticed that, I'm able to successfully install on CentOS 7, but when trying Ubuntu 18.04 Server even when using your above code, it just "skips" the steps to install... here is the full output with debug, if anyone knows whats up... I'm trying to figure it out.

PLAY [gl-runner-1] **********************************************************************************************************************

TASK [Gathering Facts] ******************************************************************************************************************
ok: [IPREMOVED]

TASK [ansiblebit.oracle-java : include OS family/distribution specific variables] *******************************************************
ok: [IPREMOVED] => (item=roles/ansiblebit.oracle-java/defaults/debian-ubuntu.yml)

TASK [ansiblebit.oracle-java : determine if Java is already installed] ******************************************************************
changed: [IPREMOVED]

TASK [ansiblebit.oracle-java : set fact oracle_java_installed] **************************************************************************
ok: [IPREMOVED]

TASK [ansiblebit.oracle-java : determine which Java version is installed] ***************************************************************
skipping: [IPREMOVED]

TASK [ansiblebit.oracle-java : set fact oracle_java_installed_version] ******************************************************************
skipping: [IPREMOVED]

TASK [ansiblebit.oracle-java : debug] ***************************************************************************************************
ok: [IPREMOVED] => (item=oracle_java_installed) => {
    "item": "oracle_java_installed", 
    "oracle_java_installed": false
}
ok: [IPREMOVED] => (item=oracle_java_task_installed) => {
    "item": "oracle_java_task_installed", 
    "oracle_java_task_installed": {
        "changed": true, 
        "cmd": "which java", 
        "delta": "0:00:00.001613", 
        "end": "2018-10-19 16:21:26.407580", 
        "failed": false, 
        "failed_when_result": false, 
        "msg": "non-zero return code", 
        "rc": 1, 
        "start": "2018-10-19 16:21:26.405967", 
        "stderr": "", 
        "stderr_lines": [], 
        "stdout": "", 
        "stdout_lines": []
    }
}
ok: [IPREMOVED] => (item=oracle_java_task_version) => {
    "item": "oracle_java_task_version", 
    "oracle_java_task_version": {
        "changed": false, 
        "skip_reason": "Conditional result was False", 
        "skipped": true
    }
}
ok: [IPREMOVED] => (item=oracle_java_version_installed) => {
    "item": "oracle_java_version_installed", 
    "oracle_java_version_installed": "VARIABLE IS NOT DEFINED!"
}

TASK [ansiblebit.oracle-java : debug] ***************************************************************************************************
ok: [IPREMOVED] => (item=oracle_java_cache_valid_time) => {
    "item": "oracle_java_cache_valid_time", 
    "oracle_java_cache_valid_time": 3600
}
ok: [IPREMOVED] => (item=oracle_java_home) => {
    "item": "oracle_java_home", 
    "oracle_java_home": "/usr/lib/jvm/java-8-oracle"
}
ok: [IPREMOVED] => (item=oracle_java_installed) => {
    "item": "oracle_java_installed", 
    "oracle_java_installed": false
}
ok: [IPREMOVED] => (item=oracle_java_os_supported) => {
    "item": "oracle_java_os_supported", 
    "oracle_java_os_supported": true
}
ok: [IPREMOVED] => (item=oracle_java_apt_repository) => {
    "item": "oracle_java_apt_repository", 
    "oracle_java_apt_repository": "ppa:webupd8team/java"
}
ok: [IPREMOVED] => (item=oracle_java_apt_repository_key) => {
    "item": "oracle_java_apt_repository_key", 
    "oracle_java_apt_repository_key": "VARIABLE IS NOT DEFINED!"
}
ok: [IPREMOVED] => (item=oracle_java_set_as_default) => {
    "item": "oracle_java_set_as_default", 
    "oracle_java_set_as_default": false
}
ok: [IPREMOVED] => (item=oracle_java_state) => {
    "item": "oracle_java_state", 
    "oracle_java_state": "latest"
}
ok: [IPREMOVED] => (item=oracle_java_version_installed) => {
    "item": "oracle_java_version_installed", 
    "oracle_java_version_installed": "VARIABLE IS NOT DEFINED!"
}
ok: [IPREMOVED] => (item=oracle_java_version_string) => {
    "item": "oracle_java_version_string", 
    "oracle_java_version_string": "VARIABLE IS NOT DEFINED!"
}

TASK [ansiblebit.oracle-java : check if operating system is suported] *******************************************************************
skipping: [IPREMOVED]

TASK [ansiblebit.oracle-java : include OS family/distribution specific task file] *******************************************************
skipping: [IPREMOVED] => (item=roles/ansiblebit.oracle-java/tasks/installation/debian/main.yml) 

TASK [ansiblebit.oracle-java : determine if Java is already installed] ******************************************************************
changed: [IPREMOVED]

TASK [ansiblebit.oracle-java : set fact oracle_java_installed] **************************************************************************
ok: [IPREMOVED]

TASK [ansiblebit.oracle-java : determine which Java version is installed] ***************************************************************
skipping: [IPREMOVED]

TASK [ansiblebit.oracle-java : set fact oracle_java_installed_version] ******************************************************************
skipping: [IPREMOVED]

TASK [ansiblebit.oracle-java : debug] ***************************************************************************************************
ok: [IPREMOVED] => (item=oracle_java_installed) => {
    "item": "oracle_java_installed", 
    "oracle_java_installed": false
}
ok: [IPREMOVED] => (item=oracle_java_task_installed) => {
    "item": "oracle_java_task_installed", 
    "oracle_java_task_installed": {
        "changed": true, 
        "cmd": "which java", 
        "delta": "0:00:00.001572", 
        "end": "2018-10-19 16:21:27.185605", 
        "failed": false, 
        "failed_when_result": false, 
        "msg": "non-zero return code", 
        "rc": 1, 
        "start": "2018-10-19 16:21:27.184033", 
        "stderr": "", 
        "stderr_lines": [], 
        "stdout": "", 
        "stdout_lines": []
    }
}
ok: [IPREMOVED] => (item=oracle_java_task_version) => {
    "item": "oracle_java_task_version", 
    "oracle_java_task_version": {
        "changed": false, 
        "skip_reason": "Conditional result was False", 
        "skipped": true
    }
}
ok: [IPREMOVED] => (item=oracle_java_version_installed) => {
    "item": "oracle_java_version_installed", 
    "oracle_java_version_installed": "VARIABLE IS NOT DEFINED!"
}

PLAY RECAP ******************************************************************************************************************************
IPREMOVED               : ok=9    changed=2    unreachable=0    failed=0 

@steenzout
Copy link
Member

@guzmonne and @d4rkd0s docs updated.

note: if you haven't already, please star the repo. thank you!

@steenzout
Copy link
Member

6.22.6 Release Notes

This release includes support for Java 11.

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

Successfully merging a pull request may close this issue.

3 participants