{"id":18367824,"url":"https://github.com/gantsign/ansible_role_sdkman_init","last_synced_at":"2026-04-20T10:03:18.074Z","repository":{"id":39652055,"uuid":"145205497","full_name":"gantsign/ansible_role_sdkman_init","owner":"gantsign","description":"Ansible role for initializing SDKMAN","archived":false,"fork":false,"pushed_at":"2022-08-03T22:43:18.000Z","size":86,"stargazers_count":3,"open_issues_count":1,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-04-10T19:34:49.510Z","etag":null,"topics":["ansible","ansible-role","java","sdkman"],"latest_commit_sha":null,"homepage":null,"language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/gantsign.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-08-18T09:01:20.000Z","updated_at":"2022-06-18T01:59:47.000Z","dependencies_parsed_at":"2022-08-09T15:08:48.687Z","dependency_job_id":null,"html_url":"https://github.com/gantsign/ansible_role_sdkman_init","commit_stats":null,"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"purl":"pkg:github/gantsign/ansible_role_sdkman_init","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gantsign%2Fansible_role_sdkman_init","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gantsign%2Fansible_role_sdkman_init/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gantsign%2Fansible_role_sdkman_init/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gantsign%2Fansible_role_sdkman_init/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/gantsign","download_url":"https://codeload.github.com/gantsign/ansible_role_sdkman_init/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gantsign%2Fansible_role_sdkman_init/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32042294,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-20T00:18:06.643Z","status":"online","status_checked_at":"2026-04-20T02:00:06.527Z","response_time":94,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["ansible","ansible-role","java","sdkman"],"created_at":"2024-11-05T23:23:36.807Z","updated_at":"2026-04-20T10:03:18.043Z","avatar_url":"https://github.com/gantsign.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"Ansible Role: SDKMAN init\n=========================\n\n[![Tests](https://github.com/gantsign/ansible_role_sdkman_init/workflows/Tests/badge.svg)](https://github.com/gantsign/ansible_role_sdkman_init/actions?query=workflow%3ATests)\n[![Ansible Galaxy](https://img.shields.io/badge/ansible--galaxy-gantsign.sdkman__init-blue.svg)](https://galaxy.ansible.com/gantsign/sdkman_init)\n[![License](https://img.shields.io/badge/license-Apache_2-blue.svg)](https://raw.githubusercontent.com/gantsign/ansible_role_sdkman_init/master/LICENSE)\n\nRole to initialize [SDKMAN](https://sdkman.io/) the software development kit\nmanager. This role allows you to install particular SDKs as part of your Ansible\nprovisioning and set which versions should be use by default.\n\n**Important:** this role requires SDKMAN to be already installed. You can use\nour [gantsign.sdkman](https://galaxy.ansible.com/gantsign/sdkman) role to\ninstall SDKMAN.\n\nRequirements\n------------\n\n* Ansible \u003e= 2.9\n\n* Linux Distribution\n\n    * Debian Family\n\n        * Debian\n\n            * Stretch (9)\n            * Buster (10)\n            * Bullseye (11)\n\n        * Ubuntu\n\n            * Bionic (18.04)\n            * Focal (20.04)\n\n    * RedHat Family\n\n        * Rocky Linux\n\n            * 8\n\n        * Fedora\n\n            * 35\n\n    * SUSE Family\n\n        * openSUSE\n\n            * 15.3\n\n    * Note: other versions are likely to work but have not been tested.\n\nRole Variables\n--------------\n\nThe following variables will change the behavior of this role:\n\n```yaml\n# SDKMAN is initialized per user so you must specify at least one user\nusers:\n  - username: # User to initialize SDKMAN for\n    sdkman_install:\n      - candidate: # Candidate SDK name e.g. java\n        version: # Candidate version to install\n        path: # Optional. To add an existing SDK install to SDKMAN.\n              # The `version` for the existing SDK can't be the same any of\n              # those provided by SDKMAN. The version string is just an\n              # identifier so you can give it any value you like (as long as it\n              # doesn't clash with any other versions for this candidate).\n    sdkman_default:\n      _candidate_sdk_name_here_: # Optional. Default version\n```\n\nExample Playbooks\n-----------------\n\nThis is an example configuration for this role by itself (without the necessary\nrole for installing SDKMAN).\n\n```yaml\n- hosts: servers\n  roles:\n    - role: gantsign.sdkman_init\n      users:\n        - username: example_username\n          sdkman_install:\n            - candidate: java\n              version: '8.0.181-zulu'\n            - candidate: java\n              version: '10'\n              path: '/opt/java/jdk-10.0.2'\n            - candidate: maven\n              version: '3.5.4'\n          sdkman_default:\n            java: '10'\n            maven: '3.5.4'\n```\n\nThis is a complete example that uses the `gantsign.sdkman` role to install\nSDKMAN. Notice how the `gantsign.sdkman_init` role can be used more than once\nwith Ansible tags to conditionally install particular SDKs.\n\n```yaml\n- hosts: servers\n  roles:\n    - role: gantsign.sdkman\n      sdkman_users:\n        - example_username\n\n    - role: gantsign.sdkman_init\n      tags:\n        - java\n      users:\n        - username: example_username\n          sdkman_install:\n            - candidate: java\n              version: '8.0.181-zulu'\n            - candidate: java\n              version: '10'\n              path: '/opt/java/jdk-10.0.2'\n          sdkman_default:\n            java: '10'\n\n    - role: gantsign.sdkman_init\n      tags:\n        - java\n        - maven\n      users:\n        - username: example_username\n          sdkman_install:\n            - candidate: maven\n              version: '3.5.4'\n          sdkman_default:\n            maven: '3.5.4'\n```\n\nMore Roles From GantSign\n------------------------\n\nYou can find more roles from GantSign on\n[Ansible Galaxy](https://galaxy.ansible.com/gantsign).\n\nDevelopment \u0026 Testing\n---------------------\n\nThis project uses [Molecule](http://molecule.readthedocs.io/) to aid in the\ndevelopment and testing; the role is unit tested using\n[Testinfra](http://testinfra.readthedocs.io/) and\n[pytest](http://docs.pytest.org/).\n\nTo develop or test you'll need to have installed the following:\n\n* Linux (e.g. [Ubuntu](http://www.ubuntu.com/))\n* [Docker](https://www.docker.com/)\n* [Python](https://www.python.org/) (including python-pip)\n* [Ansible](https://www.ansible.com/)\n* [Molecule](http://molecule.readthedocs.io/)\n\nBecause the above can be tricky to install, this project includes\n[Molecule Wrapper](https://github.com/gantsign/molecule-wrapper). Molecule\nWrapper is a shell script that installs Molecule and it's dependencies (apart\nfrom Linux) and then executes Molecule with the command you pass it.\n\nTo test this role using Molecule Wrapper run the following command from the\nproject root:\n\n```bash\n./moleculew test\n```\n\nNote: some of the dependencies need `sudo` permission to install.\n\nLicense\n-------\n\nApache 2\n\nAuthor Information\n------------------\n\nJohn Freeman\n\nGantSign Ltd.\nCompany No. 06109112 (registered in England)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgantsign%2Fansible_role_sdkman_init","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgantsign%2Fansible_role_sdkman_init","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgantsign%2Fansible_role_sdkman_init/lists"}