idealista / java_role Goto Github PK
View Code? Open in Web Editor NEWAnsible role to install Java (OpenJDK, AdoptOpenJDK and Corretto)
Home Page: https://hub.docker.com/r/idealista/jdk
License: Apache License 2.0
Ansible role to install Java (OpenJDK, AdoptOpenJDK and Corretto)
Home Page: https://hub.docker.com/r/idealista/jdk
License: Apache License 2.0
openjdk-8-jre-headless package is not available in Debian Jessie repositories, it should be installed from backports
https://packages.debian.org/jessie-backports/openjdk-8-jre-headless
Run role against any Jessie
3.0.0
IMHO the tag name should include installed java version number instead of role version name:
$ docker run -it idealista/jdk:3.3.0-debian9-openjdk /usr/bin/java -version
openjdk version "1.8.0_181"
OpenJDK Runtime Environment (build 1.8.0_181-8u181-b13-2~deb9u1-b13)
OpenJDK 64-Bit Server VM (build 25.181-b13, mixed mode)
Probably 3.3.0
is meaningless for the majority of java users and 1.8.0_181 should be used.
Note: The problem is to extract this version name, because in openjdk isn't explicitly specified. Related issue: #57
Add Support for 11.5.x
In the new Docker Hub image, systemd is not available. Make another image with it.
role fails with java_implementation: "oraclejdk"
Expected behavior: Role run ok
Actual behavior: Role fails
Reproduces how often: Always
3.0.3
The role is unable to download default Oracle Java version from their site.
- include_role:
name: idealista.java_role
vars:
java_implementation: 'oraclejdk'
You can also use it with the latest version available inside the role:
- include_role:
name: idealista.java_role
vars:
java_implementation: 'oraclejdk'
java_oracle_jdk_version: '1.8.0_192'
Expected behavior: [What you expect to happen]
Oracle Java downloaded and installed with default values.
Actual behavior: [What actually happens]
I get the following error:
TASK [idealista.java_role : Java | Download .tar.gz file containing binaries from Oracle website] **************************************
Wednesday 16 January 2019 15:39:48 +0100 (0:00:00.863) 0:03:33.792 *****
[DEPRECATION WARNING]: Supplying `headers` as a string is deprecated. Please use dict/hash format for `headers`. This feature will be
removed in version 2.10. Deprecation warnings can be disabled by setting deprecation_warnings=False in ansible.cfg.
fatal: [myhost02]: FAILED! => {"changed": false, "dest": "/tmp/jdk-1.8.0_191.tar.gz", "msg": "Request failed", "response": "HTTP Error 404: Not Found", "state": "absent", "status_code": 404, "url": "http://download.oracle.com/otn-pub/java/jdk/8u191-b12/2787e4a523244c269598db4e85c51e0c/jdk-8u191-linux-x64.tar.gz"}
And it's the same with version 1.8.0_192.
Reproduces how often: [What percentage of the time does it reproduce?]
All the times.
Current master branch version.
ansible 2.7.5
config file = None
configured module search path = ['/Users/mmolinac/.ansible/plugins/modules', '/usr/share/ansible/plugins/modules']
ansible python module location = /usr/local/Cellar/ansible/2.7.5/libexec/lib/python3.7/site-packages/ansible
executable location = /usr/local/bin/ansible
python version = 3.7.2 (default, Jan 13 2019, 12:50:01) [Clang 10.0.0 (clang-1000.11.45.5)]
Add to LD_LIBRARY_PATH java libraries in jdk
this: $JAVA_HOME/jre/lib/amd64/server
and maybe this $JAVA_HOME/jre/lib/amd64
Woulfd be fine to add this to
/etc/profile.d/jdk.sh
When trying to install the role in some -slim
Docker images, the path /usr/share/man/man1
is not present and is required if installing OpenJDK. A fix was add in that Molecule scenario, but should be add in the role.
debian:stretch-slim
Docker imageExpected behavior: Java is installed and everything works flawlessly
Actual behavior: Flawlessly fails.
Reproduces how often: 100%
All? At least, 4.1.0
IMHO OpenJDK should be installed using headless package, because 99.9% of time users doesn't need graphical interface (executing non GUI Java programs).
Probably this speed up OpenJDK installation.
all
Add support for Centos 7
What do you think?
On debian stretch, cannot update to java 11 if java 8 was installed previous
Expected behavior: Java 11 should be installed
Actual behavior: Java 8 isnt update to java 11
Reproduces how often: 100%
5.2.0
Support java 11
Deprecation warnings are displayed when running the role:
[DEPRECATION WARNING]: The use of 'include' for tasks has been deprecated. Use
'import_tasks' for static inclusions or 'include_tasks' for dynamic inclusions.
This feature will be removed in a future release. Deprecation warnings can be
disabled by setting deprecation_warnings=False in ansible.cfg.
[DEPRECATION WARNING]: include is kept for backwards compatibility but usage is
discouraged. The module documentation details page may explain more about this
rationale.. This feature will be removed in a future release. Deprecation
warnings can be disabled by setting deprecation_warnings=False in ansible.cfg.
Actual behavior: Deprecation warnings
Reproduces how often: Always
2.0.2
Cannot run this role under Debian Jessie because jessie-backports is not configured. These instructions should be followed in order to enable jessie-backports in jessie:
https://backports.debian.org/Instructions/
Expected behavior: Openjdk 8 installed
Actual behavior: An error ocurred
Reproduces how often: 100%
[Description of the issue]
Expected behavior: [What you expect to happen]
Actual behavior: [What actually happens]
Reproduces how often: [What percentage of the time does it reproduce?]
The version/s you notice the behavior.
Any additional information, configuration or data that might be necessary to reproduce the issue.
In the new release a shell step was added in Packer, but Travis can't find the script. Guess that needs the {{ template_dir }}
variable before, like in here
Travis deployment to Docker Hub is broken because open_jdk_java_version
is no longer in defaults/main.yml
3.4.0
Solve Ansible Galaxy warnings:
Warnings: 3
2 E405: Remote package tasks should have a retry
1 E204: Lines should be no longer than 120 chars
OracleJDK is not working because depends on webupd8 PPA that is raising a HTTP 404 Not Found error when tries to install Java.
Image size could be reduced cleaning APT cache after install packages
We should add CI to this role using the stack below:
We should configure Travis to run the unit tests in each push/merge: http://molecule.readthedocs.io/en/stable-1.18/usage.html
When trying to use the role with OracleJDK, it gets the following error:
fatal: [oraclejdk]: FAILED! => {"changed": false, "dest": "/tmp/jdk-1.8.0_151.tar.gz", "failed": true, "msg": "Request failed", "response": "HTTP Error 404: Not Found", "state": "absent", "status_code": 404, "url": "http://download.oracle.com/otn-pub/java/jdk/8u151-b12/e758a0de34e24606bca991d704f6dcbf/jdk-8u151-linux-x64.tar.gz"}
java_implementation: oraclejdk
java_oracle_jdk_version: 1.8.0_151
or java_oracle_jdk_version: 1.8.0_152
Expected behavior:
Install OracleJDK
Actual behavior:
Download task fails, getting 404 code.
Reproduces how often:
Always
Enable openjdk installation
Due to update_cache option in install dependencies for openJDK, idempotence check fails because every time this task is executed the apt cache is updated, and this task is marked with "changed": true.
Expected behavior: If no changes are performed, idempotence check should pass
Actual behavior: idempotence check doesn't pass
Reproduces how often: 100%
All versions
This behavior is described and detected as bug in Ansible:
Some JRE versions are outdated, causing travis test failing. They must be updated.
Debian Jessie is out of support, configurations must be removed.
5.2.0
No funciona instalando la oracle Java7. Realizaré unas modificaciones y os pasaré la PR.
Muchas gracias
Traza:
"Downloading Oracle Java 7...",
"--2017-09-01 09:34:09-- http://download.oracle.com/otn-pub/java/jdk/7u80-b15/jdk-7u80-linux-x64.tar.gz",
"Resolving download.oracle.com (download.oracle.com)... 92.123.73.186, 92.123.73.83",
"Connecting to download.oracle.com (download.oracle.com)|92.123.73.186|:80... connected.",
"HTTP request sent, awaiting response... 302 Moved Temporarily",
"Location: https://edelivery.oracle.com/otn-pub/java/jdk/7u80-b15/jdk-7u80-linux-x64.tar.gz [following]",
"--2017-09-01 09:34:09-- https://edelivery.oracle.com/otn-pub/java/jdk/7u80-b15/jdk-7u80-linux-x64.tar.gz",
"Resolving edelivery.oracle.com (edelivery.oracle.com)... 23.37.165.204, 2a02:26f0:b1:282::2d3e, 2a02:26f0:b1:283::2d3e",
"Connecting to edelivery.oracle.com (edelivery.oracle.com)|23.37.165.204|:443... connected.",
"HTTP request sent, awaiting response... 302 Moved Temporarily",
"Location: http://download.oracle.com/otn-pub/java/jdk/7u80-b15/jdk-7u80-linux-x64.tar.gz?AuthParam=1504258569_4447ea6ade9e3d2cae83b1ba585e35ae [following]",
"--2017-09-01 09:34:09-- http://download.oracle.com/otn-pub/java/jdk/7u80-b15/jdk-7u80-linux-x64.tar.gz?AuthParam=1504258569_4447ea6ade9e3d2cae83b1ba585e35ae",
"Connecting to download.oracle.com (download.oracle.com)|92.123.73.186|:80... connected.",
"HTTP request sent, awaiting response... 404 Not Found",
"2017-09-01 09:34:10 ERROR 404: Not Found."
The role cannot be deployed to Ansible Galaxy because of missing parameters in the role metadata
Now we're using Geerlingguy's Docker images as base image for our Java role's image in Dockerhub. Though they're perfectly fine, the way the images are built is not the best and leaves the container with Ansible and the Java Role installed, when is not necessary at all. So we'll look for creating images without Ansible on them and based on Debian Slim images.
Sometimes fails building an Ansible compatible image when latest Docker versioned image is used as dependency. I need this Image to speed up solrcloud role execution 😢.
IMHO we should build images for every Java version this role could create . It would be nice if the word "Ansible" is removed from the image name.
Expected behavior: Normal test execution
Actual behavior: Fails when is "building an Ansible compatible Image":
TASK [Build an Ansible compatible image] ***************************************
failed: [localhost] (item={'_ansible_parsed': True, u'src': u'/Users/dortega/.ansible/tmp/ansible-tmp-1543327408.45-231462761729504/source', '_ansible_item_result': True, u'group': u'staff', u'uid': 502, u'size': 793, 'item': {'image_version': u'3.0.1-debian8', 'name': u'zookeeper', 'image': u'idealista/java-debian-ansible', 'capabilities': [u'SYS_ADMIN'], 'privileged': True, 'command': u'/lib/systemd/systemd', 'groups': [u'zookeeper_group'], 'volumes': [u'/sys/fs/cgroup:/sys/fs/cgroup:ro'], 'networks': [{'name': u'solr-network', 'aliases': [u'zookeeper']}]}, u'dest': u'/var/folders/5n/g2ggh_bj56bc2pw09yfhqh480000gp/T/molecule/solrcloud-role/default/Dockerfile_idealista_java_debian_ansible', u'checksum': u'cd4b2e390a16761272a517f568c372fc5ad5a846', u'changed': True, 'failed': False, u'state': u'file', u'gid': 20, u'mode': u'0644', u'invocation': {u'module_args': {u'directory_mode': None, u'force': True, u'remote_src': None, u'owner': None, u'follow': False, u'local_follow': None, u'group': None, u'unsafe_writes': None, u'setype': None, u'content': None, u'serole': None, u'dest': u'/var/folders/5n/g2ggh_bj56bc2pw09yfhqh480000gp/T/molecule/solrcloud-role/default/Dockerfile_idealista_java_debian_ansible', u'selevel': None, u'original_basename': u'Dockerfile.j2', u'regexp': None, u'validate': None, u'src': u'/Users/dortega/.ansible/tmp/ansible-tmp-1543327408.45-231462761729504/source', u'checksum': u'cd4b2e390a16761272a517f568c372fc5ad5a846', u'seuser': None, u'delimiter': None, u'mode': None, u'attributes': None, u'backup': False}}, u'owner': u'dortega', 'diff': [], u'md5sum': u'ef3d61319249b3651eb2b932d891bf30', '_ansible_ignore_errors': None, '_ansible_no_log': False}) => {"changed": false, "item": {"changed": true, "checksum": "cd4b2e390a16761272a517f568c372fc5ad5a846", "dest": "/var/folders/5n/g2ggh_bj56bc2pw09yfhqh480000gp/T/molecule/solrcloud-role/default/Dockerfile_idealista_java_debian_ansible", "diff": [], "failed": false, "gid": 20, "group": "staff", "invocation": {"module_args": {"attributes": null, "backup": false, "checksum": "cd4b2e390a16761272a517f568c372fc5ad5a846", "content": null, "delimiter": null, "dest": "/var/folders/5n/g2ggh_bj56bc2pw09yfhqh480000gp/T/molecule/solrcloud-role/default/Dockerfile_idealista_java_debian_ansible", "directory_mode": null, "follow": false, "force": true, "group": null, "local_follow": null, "mode": null, "original_basename": "Dockerfile.j2", "owner": null, "regexp": null, "remote_src": null, "selevel": null, "serole": null, "setype": null, "seuser": null, "src": "/Users/dortega/.ansible/tmp/ansible-tmp-1543327408.45-231462761729504/source", "unsafe_writes": null, "validate": null}}, "item": {"capabilities": ["SYS_ADMIN"], "command": "/lib/systemd/systemd", "groups": ["zookeeper_group"], "image": "idealista/java-debian-ansible", "image_version": "3.0.1-debian8", "name": "zookeeper", "networks": [{"aliases": ["zookeeper"], "name": "solr-network"}], "privileged": true, "volumes": ["/sys/fs/cgroup:/sys/fs/cgroup:ro"]}, "md5sum": "ef3d61319249b3651eb2b932d891bf30", "mode": "0644", "owner": "dortega", "size": 793, "src": "/Users/dortega/.ansible/tmp/ansible-tmp-1543327408.45-231462761729504/source", "state": "file", "uid": 502}, "msg": "Error building molecule_local/idealista/java-debian-ansible - code: 100, message: The command '/bin/sh -c if [ $(command -v apt-get) ]; then apt-get update && apt-get upgrade -y && apt-get install -y python sudo bash ca-certificates && apt-get clean; elif [ $(command -v dnf) ]; then dnf makecache && dnf --assumeyes install python sudo python-devel python2-dnf bash && dnf clean all; elif [ $(command -v yum) ]; then yum makecache fast && yum update -y && yum install -y python sudo yum-plugin-ovl bash && sed -i 's/plugins=0/plugins=1/g' /etc/yum.conf && yum clean all; elif [ $(command -v zypper) ]; then zypper refresh && zypper update -y && zypper install -y python sudo bash python-xml && zypper clean -a; elif [ $(command -v apk) ]; then apk update && apk add --no-cache python sudo bash ca-certificates; fi' returned a non-zero code: 100, logs: [u'Step 1/2 : FROM idealista/java-debian-ansible', u'\\n', u' ---> 41764fa940e2\\n', u\"Step 2/2 : RUN if [ $(command -v apt-get) ]; then apt-get update && apt-get upgrade -y && apt-get install -y python sudo bash ca-certificates && apt-get clean; elif [ $(command -v dnf) ]; then dnf makecache && dnf --assumeyes install python sudo python-devel python2-dnf bash && dnf clean all; elif [ $(command -v yum) ]; then yum makecache fast && yum update -y && yum install -y python sudo yum-plugin-ovl bash && sed -i 's/plugins=0/plugins=1/g' /etc/yum.conf && yum clean all; elif [ $(command -v zypper) ]; then zypper refresh && zypper update -y && zypper install -y python sudo bash python-xml && zypper clean -a; elif [ $(command -v apk) ]; then apk update && apk add --no-cache python sudo bash ca-certificates; fi\", u'\\n', u' ---> Running in ae15a5e6564e\\n', u'Ign:2 http://cdn-fastly.deb.debian.org/debian stretch InRelease\\nIgn:3 http://cdn-fastly.deb.debian.org/debian stretch InRelease\\n', u'Get:1 http://security-cdn.debian.org/debian-security stretch/updates InRelease [94.3 kB]\\n', u'Get:4 http://cdn-fastly.deb.debian.org/debian stretch-updates InRelease [91.0 kB]\\n', u'Hit:5 http://cdn-fastly.deb.debian.org/debian stretch Release\\n', u'Hit:6 http://cdn-fastly.deb.debian.org/debian stretch Release\\n', u'Err:6 http://cdn-fastly.deb.debian.org/debian stretch Release\\n Failed to stat - stat (2: No such file or directory)\\n', u'Get:7 http://security-cdn.debian.org/debian-security stretch/updates/main amd64 Packages [460 kB]\\n', u'Reading package lists...', u'\\n', u\"\\x1b[91mE: The repository 'http://http.debian.net/debian stretch Release' does no longer have a Release file.\\n\\x1b[0m\", u'Removing intermediate container ae15a5e6564e\\n']"}
failed: [localhost] (item={'_ansible_parsed': True, u'changed': False, u'group': u'staff', u'uid': 502, 'item': {'image_version': u'3.0.1-debian8', 'name': u'solrcloud', 'image': u'idealista/java-debian-ansible', 'capabilities': [u'SYS_ADMIN'], 'privileged': True, 'command': u'/lib/systemd/systemd', 'groups': [u'solrcloud_group'], 'volumes': [u'/sys/fs/cgroup:/sys/fs/cgroup:ro'], 'networks': [{'name': u'solr-network', 'links': [u'zookeeper:zookeeper'], 'aliases': [u'solrcloud']}]}, 'dest': u'/var/folders/5n/g2ggh_bj56bc2pw09yfhqh480000gp/T/molecule/solrcloud-role/default/Dockerfile_idealista_java_debian_ansible', 'checksum': u'cd4b2e390a16761272a517f568c372fc5ad5a846', '_ansible_item_result': True, 'failed': False, u'state': u'file', u'gid': 20, u'mode': u'0644', u'invocation': {u'module_args': {u'directory_mode': None, u'force': False, u'remote_src': None, u'path': u'/var/folders/5n/g2ggh_bj56bc2pw09yfhqh480000gp/T/molecule/solrcloud-role/default/Dockerfile_idealista_java_debian_ansible', u'owner': None, u'follow': False, u'group': None, u'unsafe_writes': None, u'serole': None, u'content': None, u'state': u'file', u'diff_peek': None, u'setype': None, u'dest': u'/var/folders/5n/g2ggh_bj56bc2pw09yfhqh480000gp/T/molecule/solrcloud-role/default/Dockerfile_idealista_java_debian_ansible', u'selevel': None, u'original_basename': u'Dockerfile.j2', u'regexp': None, u'validate': None, u'src': u'Dockerfile.j2', u'seuser': None, u'recurse': False, u'delimiter': None, u'mode': None, u'attributes': None, u'backup': None}}, u'owner': u'dortega', u'path': u'/var/folders/5n/g2ggh_bj56bc2pw09yfhqh480000gp/T/molecule/solrcloud-role/default/Dockerfile_idealista_java_debian_ansible', u'size': 793, 'diff': {u'after': {u'path': u'/var/folders/5n/g2ggh_bj56bc2pw09yfhqh480000gp/T/molecule/solrcloud-role/default/Dockerfile_idealista_java_debian_ansible'}, u'before': {u'path': u'/var/folders/5n/g2ggh_bj56bc2pw09yfhqh480000gp/T/molecule/solrcloud-role/default/Dockerfile_idealista_java_debian_ansible'}}, '_ansible_ignore_errors': None, '_ansible_no_log': False}) => {"changed": false, "item": {"changed": false, "checksum": "cd4b2e390a16761272a517f568c372fc5ad5a846", "dest": "/var/folders/5n/g2ggh_bj56bc2pw09yfhqh480000gp/T/molecule/solrcloud-role/default/Dockerfile_idealista_java_debian_ansible", "diff": {"after": {"path": "/var/folders/5n/g2ggh_bj56bc2pw09yfhqh480000gp/T/molecule/solrcloud-role/default/Dockerfile_idealista_java_debian_ansible"}, "before": {"path": "/var/folders/5n/g2ggh_bj56bc2pw09yfhqh480000gp/T/molecule/solrcloud-role/default/Dockerfile_idealista_java_debian_ansible"}}, "failed": false, "gid": 20, "group": "staff", "invocation": {"module_args": {"attributes": null, "backup": null, "content": null, "delimiter": null, "dest": "/var/folders/5n/g2ggh_bj56bc2pw09yfhqh480000gp/T/molecule/solrcloud-role/default/Dockerfile_idealista_java_debian_ansible", "diff_peek": null, "directory_mode": null, "follow": false, "force": false, "group": null, "mode": null, "original_basename": "Dockerfile.j2", "owner": null, "path": "/var/folders/5n/g2ggh_bj56bc2pw09yfhqh480000gp/T/molecule/solrcloud-role/default/Dockerfile_idealista_java_debian_ansible", "recurse": false, "regexp": null, "remote_src": null, "selevel": null, "serole": null, "setype": null, "seuser": null, "src": "Dockerfile.j2", "state": "file", "unsafe_writes": null, "validate": null}}, "item": {"capabilities": ["SYS_ADMIN"], "command": "/lib/systemd/systemd", "groups": ["solrcloud_group"], "image": "idealista/java-debian-ansible", "image_version": "3.0.1-debian8", "name": "solrcloud", "networks": [{"aliases": ["solrcloud"], "links": ["zookeeper:zookeeper"], "name": "solr-network"}], "privileged": true, "volumes": ["/sys/fs/cgroup:/sys/fs/cgroup:ro"]}, "mode": "0644", "owner": "dortega", "path": "/var/folders/5n/g2ggh_bj56bc2pw09yfhqh480000gp/T/molecule/solrcloud-role/default/Dockerfile_idealista_java_debian_ansible", "size": 793, "state": "file", "uid": 502}, "msg": "Error building molecule_local/idealista/java-debian-ansible - code: 100, message: The command '/bin/sh -c if [ $(command -v apt-get) ]; then apt-get update && apt-get upgrade -y && apt-get install -y python sudo bash ca-certificates && apt-get clean; elif [ $(command -v dnf) ]; then dnf makecache && dnf --assumeyes install python sudo python-devel python2-dnf bash && dnf clean all; elif [ $(command -v yum) ]; then yum makecache fast && yum update -y && yum install -y python sudo yum-plugin-ovl bash && sed -i 's/plugins=0/plugins=1/g' /etc/yum.conf && yum clean all; elif [ $(command -v zypper) ]; then zypper refresh && zypper update -y && zypper install -y python sudo bash python-xml && zypper clean -a; elif [ $(command -v apk) ]; then apk update && apk add --no-cache python sudo bash ca-certificates; fi' returned a non-zero code: 100, logs: [u'Step 1/2 : FROM idealista/java-debian-ansible', u'\\n', u' ---> 41764fa940e2\\n', u\"Step 2/2 : RUN if [ $(command -v apt-get) ]; then apt-get update && apt-get upgrade -y && apt-get install -y python sudo bash ca-certificates && apt-get clean; elif [ $(command -v dnf) ]; then dnf makecache && dnf --assumeyes install python sudo python-devel python2-dnf bash && dnf clean all; elif [ $(command -v yum) ]; then yum makecache fast && yum update -y && yum install -y python sudo yum-plugin-ovl bash && sed -i 's/plugins=0/plugins=1/g' /etc/yum.conf && yum clean all; elif [ $(command -v zypper) ]; then zypper refresh && zypper update -y && zypper install -y python sudo bash python-xml && zypper clean -a; elif [ $(command -v apk) ]; then apk update && apk add --no-cache python sudo bash ca-certificates; fi\", u'\\n', u' ---> Running in 622b8184d5cc\\n', u'Get:1 http://security-cdn.debian.org/debian-security stretch/updates InRelease [94.3 kB]\\n', u'Ign:2 http://cdn-fastly.deb.debian.org/debian stretch InRelease\\nIgn:3 http://cdn-fastly.deb.debian.org/debian stretch InRelease\\n', u'Get:4 http://cdn-fastly.deb.debian.org/debian stretch-updates InRelease [91.0 kB]\\n', u'Hit:5 http://cdn-fastly.deb.debian.org/debian stretch Release\\n', u'Hit:6 http://cdn-fastly.deb.debian.org/debian stretch Release\\n', u'Err:6 http://cdn-fastly.deb.debian.org/debian stretch Release\\n Failed to stat - stat (2: No such file or directory)\\n', u'Get:7 http://security-cdn.debian.org/debian-security stretch/updates/main amd64 Packages [460 kB]\\n', u'Reading package lists...', u'\\n', u\"\\x1b[91mE: The repository 'http://deb.debian.org/debian stretch Release' does no longer have a Release file.\\n\\x1b[0m\", u'Removing intermediate container 622b8184d5cc\\n']"}
Reproduces how often: most times
versions >= 3.0.1
Any additional information, configuration or data that might be necessary to reproduce the issue.
At least in Ubuntu Bionic, APT has to download 125MB of packages installing openJDK. Sometime fails in Travis because the 10 minutes timeout. Should this source repositories be replaced by faster ones?
Expected behavior: Pass travis build (at least install openJDK packages)
Actual behavior: Sometimes fails because 10 minutes timeout
Reproduces how often: ~75%
Since Ubuntu is supported in this role
Installation fails in debian 10 systems.
All
Any additional information, configuration or data that might be necessary to reproduce the issue.
Should support for OracleJDK be dropped? I've been trying to debug the new updated OracleJDK urls, it requires registering a developer account, and using a limited time auth token in the URL to download. In theory I could add an Ansible step to login with my Oracle developer credentials, and grep the auth token from the HTTP response...
Any additional information, configuration or data that might be necessary to reproduce the issue.
Currently specific openjdk version isn't declared, so is impossible to know what version of openjdk will be installed
Add CentOS 8 support
I'll open a new PR for this over the weekend.
[Description of the issue]
Expected behavior: [What you expect to happen]
Actual behavior: [What actually happens]
Reproduces how often: [What percentage of the time does it reproduce?]
The version/s you notice the behavior.
Any additional information, configuration or data that might be necessary to reproduce the issue.
The role is unable to download current Oracle Java versions from their site.
- include_role:
name: idealista.java_role
vars:
java_implementation: 'oraclejdk'
You can also use it with the latest version available inside the role:
- include_role:
name: idealista.java_role
vars:
java_implementation: 'oraclejdk'
java_oracle_jdk_version: '1.8.0_202'
Expected behavior: [What you expect to happen]
Oracle Java downloaded and installed with default values.
Actual behavior: [What actually happens]
I get the following error:
TASK [idealista.java_role : Java | Download .tar.gz file containing binaries from Oracle website] ***
FAILED - RETRYING: Java | Download .tar.gz file containing binaries from Oracle website (3 retries left).
FAILED - RETRYING: Java | Download .tar.gz file containing binaries from Oracle website (2 retries left).
FAILED - RETRYING: Java | Download .tar.gz file containing binaries from Oracle website (1 retries left).
[DEPRECATION WARNING]: Supplying `headers` as a string is deprecated. Please
use dict/hash format for `headers`. This feature will be removed in version
2.10. Deprecation warnings can be disabled by setting
deprecation_warnings=False in ansible.cfg.
fatal: [tools02-dev]: FAILED! => {"attempts": 3, "changed": false, "dest": "/tmp/jdk-1.8.0_202.tar.gz", "msg": "Connection failure: ('The read operation timed out',)", "state": "absent", "url": "https://download.oracle.com/otn-pub/java/jdk/8u202-b08/1961070e4c9b4e26a04e7f5a083f551e/jdk-8u202-linux-x64.tar.gz"}
Reproduces how often: [What percentage of the time does it reproduce?]
Always
Current master branch version.
ansible 2.7.10
config file = None
configured module search path = ['/Users/mmolinac/.ansible/plugins/modules', '/usr/share/ansible/plugins/modules']
ansible python module location = /usr/local/Cellar/ansible/2.7.10/libexec/lib/python3.7/site-packages/ansible
executable location = /usr/local/bin/ansible
python version = 3.7.3 (default, Mar 27 2019, 09:23:15) [Clang 10.0.1 (clang-1001.0.46.3)]
Due to a change in Debian repositories, this role fails adding Jessie-backports repositories:
TASK [java_role : Java | Add required repositories] ****************************
task path: /Users/dortega/workspace/java_role/tasks/install_openjdk.yml:20
Using module file /Users/dortega/.local/share/virtualenvs/java_role-P7W2Vlq3/lib/python3.6/site-packages/ansible/modules/packaging/os/apt_repository.py
<openjdk> ESTABLISH DOCKER CONNECTION FOR USER: root
<openjdk> EXEC ['/usr/local/bin/docker', b'exec', b'-i', 'openjdk', '/bin/sh', '-c', "/bin/sh -c 'echo ~ && sleep 0'"]
<openjdk> EXEC ['/usr/local/bin/docker', b'exec', b'-i', 'openjdk', '/bin/sh', '-c', '/bin/sh -c \'( umask 77 && mkdir -p "` echo /root/.ansible/tmp/ansible-tmp-1553760514.536889-153022047652162 `" && echo ansible-tmp-1553760514.536889-153022047652162="` echo /root/.ansible/tmp/ansible-tmp-1553760514.536889-153022047652162 `" ) && sleep 0\'']
<openjdk> PUT /var/folders/5n/g2ggh_bj56bc2pw09yfhqh480000gp/T/tmpkc8tj2xe TO /root/.ansible/tmp/ansible-tmp-1553760514.536889-153022047652162/apt_repository.py
<openjdk> EXEC ['/usr/local/bin/docker', b'exec', b'-i', 'openjdk', '/bin/sh', '-c', "/bin/sh -c 'chmod u+x /root/.ansible/tmp/ansible-tmp-1553760514.536889-153022047652162/ /root/.ansible/tmp/ansible-tmp-1553760514.536889-153022047652162/apt_repository.py && sleep 0'"]
<openjdk> EXEC ['/usr/local/bin/docker', b'exec', b'-i', 'openjdk', '/bin/sh', '-c', '/bin/sh -c \'/usr/bin/python /root/.ansible/tmp/ansible-tmp-1553760514.536889-153022047652162/apt_repository.py; rm -rf "/root/.ansible/tmp/ansible-tmp-1553760514.536889-153022047652162/" > /dev/null 2>&1 && sleep 0\'']
The full traceback is:
Traceback (most recent call last):
File "/tmp/ansible_sBpSq3/ansible_module_apt_repository.py", line 556, in <module>
main()
File "/tmp/ansible_sBpSq3/ansible_module_apt_repository.py", line 544, in main
cache.update()
File "/usr/lib/python2.7/dist-packages/apt/cache.py", line 443, in update
raise FetchFailedException(e)
apt.cache.FetchFailedException: W:Failed to fetch http://ftp.debian.org/debian/dists/jessie-backports/main/binary-amd64/Packages 404 Not Found
, E:Some index files failed to download. They have been ignored, or old ones used instead.
failed: [openjdk] (item=deb http://ftp.debian.org/debian jessie-backports main) => {
"changed": false,
"failed": true,
"item": "deb http://ftp.debian.org/debian jessie-backports main",
"module_stderr": "Traceback (most recent call last):\n File \"/tmp/ansible_sBpSq3/ansible_module_apt_repository.py\", line 556, in <module>\n main()\n File \"/tmp/ansible_sBpSq3/ansible_module_apt_repository.py\", line 544, in main\n cache.update()\n File \"/usr/lib/python2.7/dist-packages/apt/cache.py\", line 443, in update\n raise FetchFailedException(e)\napt.cache.FetchFailedException: W:Failed to fetch http://ftp.debian.org/debian/dists/jessie-backports/main/binary-amd64/Packages 404 Not Found\n, E:Some index files failed to download. They have been ignored, or old ones used instead.\n",
"module_stdout": "",
"msg": "MODULE FAILURE",
"rc": 0
}
Every installation under Debian environment
Reproduces how often: 100%
All
https://lists.debian.org/debian-devel-announce/2019/03/msg00006.html
After #52 and #59, the role started to support Ubuntu Bionic (18.04). It would be great to add it on Docker Hub.
When there is a new java package in the same minor release of a OS distribution, the role tests crash because they can't download the old fixed version. It forces us to create new PR's to upgrade the default java version, and all the playbooks that use this role.
Expected behavior:
The java package is installed.
Actual behavior:
The role crashes because it can't find an older java package than the new release.
Reproduces how often:
Always.
All.
Problems with the new version 3.4.0. java_open_jdk_version is required.
Expected behavior: Role would be works with defaults variable as previous version.
Actual behavior: undefined variable error is thrown.
Reproduces how often: Always
3.4.0
update java oracle to last versions 1.8.0_181 and 10.0.2
The java 8 version from oracle return a 404:
fatal: [oraclejdk]: FAILED! => {"changed": false, "dest": "/tmp/jdk-1.8.0_161.tar.gz", "failed": true, "msg": "Request failed", "response": "HTTP Error 404: Not Found", "state": "absent", "status_code": 404, "url": "http://download.oracle.com/otn-pub/java/jdk/8u161-b12/2f38c3b165be4555a1fa6e98c45e0808/jdk-8u161-linux-x64.tar.gz"}
Expected behavior: Installs java 8
Actual behavior: Error
Reproduces how often: Always
2.0.1
Any additional information, configuration or data that might be necessary to reproduce the issue.
It would be nice if this role:
Upload to dockerhub images for debian-buster with adoptopenjdk
N/A
Expected behavior: With each new release, a docker image debian-buster with adoptopenjdk is pushed.
Actual behavior: Not implemented yet
Reproduces how often: N/A
N/A
N/A
There are some files that are very similar (molecule.yml files in each scenario). Probably these files could be merged in one using molecule.interpolation.Interpolator class, and adding these values as environment variables.
Should this role support Amazon Corretto?
Note: AFAIK only supports Amazon Linux, MacOS, Windows and Docker (but with additional support planned for General Availability)
It would be nice to add documentation showing how to compile Java classes using docker image hosted in Docker Hub.
https://hub.docker.com/_/golang/?tab=description Has good examples showing how to compile a project in Go
It would be nice if this role has support for Ubuntu Bionic (18.04).
Docker Hub badge refers to pull for our deprecated Docker Image java-debian-ansible
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.