Rolle entfernt: Java (#470)
Co-authored-by: Michael Grote <michael.grote@posteo.de> Reviewed-on: #470
This commit is contained in:
parent
405dbc54f7
commit
c8f6842b2a
30 changed files with 0 additions and 506 deletions
|
@ -1,3 +0,0 @@
|
|||
skip_list:
|
||||
- 'yaml'
|
||||
- 'role-name'
|
4
roles/geerlingguy.java/.github/FUNDING.yml
vendored
4
roles/geerlingguy.java/.github/FUNDING.yml
vendored
|
@ -1,4 +0,0 @@
|
|||
# These are supported funding model platforms
|
||||
---
|
||||
github: geerlingguy
|
||||
patreon: geerlingguy
|
56
roles/geerlingguy.java/.github/stale.yml
vendored
56
roles/geerlingguy.java/.github/stale.yml
vendored
|
@ -1,56 +0,0 @@
|
|||
# Configuration for probot-stale - https://github.com/probot/stale
|
||||
|
||||
# Number of days of inactivity before an Issue or Pull Request becomes stale
|
||||
daysUntilStale: 90
|
||||
|
||||
# Number of days of inactivity before an Issue or Pull Request with the stale label is closed.
|
||||
# Set to false to disable. If disabled, issues still need to be closed manually, but will remain marked as stale.
|
||||
daysUntilClose: 30
|
||||
|
||||
# Only issues or pull requests with all of these labels are check if stale. Defaults to `[]` (disabled)
|
||||
onlyLabels: []
|
||||
|
||||
# Issues or Pull Requests with these labels will never be considered stale. Set to `[]` to disable
|
||||
exemptLabels:
|
||||
- pinned
|
||||
- security
|
||||
- planned
|
||||
|
||||
# Set to true to ignore issues in a project (defaults to false)
|
||||
exemptProjects: false
|
||||
|
||||
# Set to true to ignore issues in a milestone (defaults to false)
|
||||
exemptMilestones: false
|
||||
|
||||
# Set to true to ignore issues with an assignee (defaults to false)
|
||||
exemptAssignees: false
|
||||
|
||||
# Label to use when marking as stale
|
||||
staleLabel: stale
|
||||
|
||||
# Limit the number of actions per hour, from 1-30. Default is 30
|
||||
limitPerRun: 30
|
||||
|
||||
pulls:
|
||||
markComment: |-
|
||||
This pull request has been marked 'stale' due to lack of recent activity. If there is no further activity, the PR will be closed in another 30 days. Thank you for your contribution!
|
||||
|
||||
Please read [this blog post](https://www.jeffgeerling.com/blog/2020/enabling-stale-issue-bot-on-my-github-repositories) to see the reasons why I mark pull requests as stale.
|
||||
|
||||
unmarkComment: >-
|
||||
This pull request is no longer marked for closure.
|
||||
|
||||
closeComment: >-
|
||||
This pull request has been closed due to inactivity. If you feel this is in error, please reopen the pull request or file a new PR with the relevant details.
|
||||
|
||||
issues:
|
||||
markComment: |-
|
||||
This issue has been marked 'stale' due to lack of recent activity. If there is no further activity, the issue will be closed in another 30 days. Thank you for your contribution!
|
||||
|
||||
Please read [this blog post](https://www.jeffgeerling.com/blog/2020/enabling-stale-issue-bot-on-my-github-repositories) to see the reasons why I mark issues as stale.
|
||||
|
||||
unmarkComment: >-
|
||||
This issue is no longer marked for closure.
|
||||
|
||||
closeComment: >-
|
||||
This issue has been closed due to inactivity. If you feel this is in error, please reopen the issue or file a new issue with the relevant details.
|
70
roles/geerlingguy.java/.github/workflows/ci.yml
vendored
70
roles/geerlingguy.java/.github/workflows/ci.yml
vendored
|
@ -1,70 +0,0 @@
|
|||
---
|
||||
name: CI
|
||||
'on':
|
||||
pull_request:
|
||||
push:
|
||||
branches:
|
||||
- master
|
||||
schedule:
|
||||
- cron: "0 7 * * 2"
|
||||
|
||||
defaults:
|
||||
run:
|
||||
working-directory: 'geerlingguy.java'
|
||||
|
||||
jobs:
|
||||
|
||||
lint:
|
||||
name: Lint
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Check out the codebase.
|
||||
uses: actions/checkout@v2
|
||||
with:
|
||||
path: 'geerlingguy.java'
|
||||
|
||||
- name: Set up Python 3.
|
||||
uses: actions/setup-python@v2
|
||||
with:
|
||||
python-version: '3.x'
|
||||
|
||||
- name: Install test dependencies.
|
||||
run: pip3 install yamllint
|
||||
|
||||
- name: Lint code.
|
||||
run: |
|
||||
yamllint .
|
||||
|
||||
molecule:
|
||||
name: Molecule
|
||||
runs-on: ubuntu-latest
|
||||
strategy:
|
||||
matrix:
|
||||
distro:
|
||||
- centos8
|
||||
- centos7
|
||||
- ubuntu2004
|
||||
- ubuntu1804
|
||||
- debian10
|
||||
- debian9
|
||||
|
||||
steps:
|
||||
- name: Check out the codebase.
|
||||
uses: actions/checkout@v2
|
||||
with:
|
||||
path: 'geerlingguy.java'
|
||||
|
||||
- name: Set up Python 3.
|
||||
uses: actions/setup-python@v2
|
||||
with:
|
||||
python-version: '3.x'
|
||||
|
||||
- name: Install test dependencies.
|
||||
run: pip3 install ansible molecule[docker] docker
|
||||
|
||||
- name: Run Molecule tests.
|
||||
run: molecule test
|
||||
env:
|
||||
PY_COLORS: '1'
|
||||
ANSIBLE_FORCE_COLOR: '1'
|
||||
MOLECULE_DISTRO: ${{ matrix.distro }}
|
|
@ -1,38 +0,0 @@
|
|||
---
|
||||
# This workflow requires a GALAXY_API_KEY secret present in the GitHub
|
||||
# repository or organization.
|
||||
#
|
||||
# See: https://github.com/marketplace/actions/publish-ansible-role-to-galaxy
|
||||
# See: https://github.com/ansible/galaxy/issues/46
|
||||
|
||||
name: Release
|
||||
'on':
|
||||
push:
|
||||
tags:
|
||||
- '*'
|
||||
|
||||
defaults:
|
||||
run:
|
||||
working-directory: 'geerlingguy.java'
|
||||
|
||||
jobs:
|
||||
|
||||
release:
|
||||
name: Release
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Check out the codebase.
|
||||
uses: actions/checkout@v2
|
||||
with:
|
||||
path: 'geerlingguy.java'
|
||||
|
||||
- name: Set up Python 3.
|
||||
uses: actions/setup-python@v2
|
||||
with:
|
||||
python-version: '3.x'
|
||||
|
||||
- name: Install Ansible.
|
||||
run: pip3 install ansible-base
|
||||
|
||||
- name: Trigger a new import on Galaxy.
|
||||
run: ansible-galaxy role import --api-key ${{ secrets.GALAXY_API_KEY }} $(echo ${{ github.repository }} | cut -d/ -f1) $(echo ${{ github.repository }} | cut -d/ -f2)
|
5
roles/geerlingguy.java/.gitignore
vendored
5
roles/geerlingguy.java/.gitignore
vendored
|
@ -1,5 +0,0 @@
|
|||
*.retry
|
||||
*/__pycache__
|
||||
*.pyc
|
||||
.cache
|
||||
|
|
@ -1,11 +0,0 @@
|
|||
---
|
||||
extends: default
|
||||
|
||||
rules:
|
||||
line-length:
|
||||
max: 120
|
||||
level: warning
|
||||
|
||||
ignore: |
|
||||
.github/stale.yml
|
||||
.travis.yml
|
|
@ -1,20 +0,0 @@
|
|||
The MIT License (MIT)
|
||||
|
||||
Copyright (c) 2017 Jeff Geerling
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy of
|
||||
this software and associated documentation files (the "Software"), to deal in
|
||||
the Software without restriction, including without limitation the rights to
|
||||
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
|
||||
the Software, and to permit persons to whom the Software is furnished to do so,
|
||||
subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all
|
||||
copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
|
||||
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
|
||||
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
|
||||
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
|
||||
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
|
@ -1,67 +0,0 @@
|
|||
# Ansible Role: Java
|
||||
|
||||
[![CI](https://github.com/geerlingguy/ansible-role-java/workflows/CI/badge.svg?event=push)](https://github.com/geerlingguy/ansible-role-java/actions?query=workflow%3ACI)
|
||||
|
||||
Installs Java for RedHat/CentOS and Debian/Ubuntu linux servers.
|
||||
|
||||
## Requirements
|
||||
|
||||
None.
|
||||
|
||||
## Role Variables
|
||||
|
||||
Available variables are listed below, along with default values:
|
||||
|
||||
# The defaults provided by this role are specific to each distribution.
|
||||
java_packages:
|
||||
- java-1.8.0-openjdk
|
||||
|
||||
Set the version/development kit of Java to install, along with any other necessary Java packages. Some other options include are included in the distribution-specific files in this role's 'defaults' folder.
|
||||
|
||||
java_home: ""
|
||||
|
||||
If set, the role will set the global environment variable `JAVA_HOME` to this value.
|
||||
|
||||
## Dependencies
|
||||
|
||||
None.
|
||||
|
||||
## Example Playbook (using default package)
|
||||
|
||||
- hosts: servers
|
||||
roles:
|
||||
- role: geerlingguy.java
|
||||
become: yes
|
||||
|
||||
## Example Playbook (install OpenJDK 8)
|
||||
|
||||
For RHEL / CentOS:
|
||||
|
||||
- hosts: server
|
||||
roles:
|
||||
- role: geerlingguy.java
|
||||
when: "ansible_os_family == 'RedHat'"
|
||||
java_packages:
|
||||
- java-1.8.0-openjdk
|
||||
|
||||
For Ubuntu < 16.04:
|
||||
|
||||
- hosts: server
|
||||
tasks:
|
||||
- name: installing repo for Java 8 in Ubuntu
|
||||
apt_repository: repo='ppa:openjdk-r/ppa'
|
||||
|
||||
- hosts: server
|
||||
roles:
|
||||
- role: geerlingguy.java
|
||||
when: "ansible_os_family == 'Debian'"
|
||||
java_packages:
|
||||
- openjdk-8-jdk
|
||||
|
||||
## License
|
||||
|
||||
MIT / BSD
|
||||
|
||||
## Author Information
|
||||
|
||||
This role was created in 2014 by [Jeff Geerling](https://www.jeffgeerling.com/), author of [Ansible for DevOps](https://www.ansiblefordevops.com/).
|
|
@ -1,6 +0,0 @@
|
|||
---
|
||||
# Set java_packages if you would like to use a different version than the
|
||||
# default for the OS (see defaults per OS in `vars` directory).
|
||||
# java_packages: []
|
||||
|
||||
java_home: ""
|
|
@ -1,42 +0,0 @@
|
|||
---
|
||||
dependencies: []
|
||||
|
||||
galaxy_info:
|
||||
role_name: java
|
||||
author: geerlingguy
|
||||
description: Java for Linux
|
||||
company: "Midwestern Mac, LLC"
|
||||
license: "license (BSD, MIT)"
|
||||
min_ansible_version: 2.4
|
||||
platforms:
|
||||
- name: EL
|
||||
versions:
|
||||
- 7
|
||||
- 8
|
||||
- name: Fedora
|
||||
versions:
|
||||
- all
|
||||
- name: Debian
|
||||
versions:
|
||||
- wheezy
|
||||
- jessie
|
||||
- stretch
|
||||
- buster
|
||||
- name: Ubuntu
|
||||
versions:
|
||||
- precise
|
||||
- trusty
|
||||
- xenial
|
||||
- bionic
|
||||
- focal
|
||||
- name: FreeBSD
|
||||
versions:
|
||||
- 10.2
|
||||
galaxy_tags:
|
||||
- development
|
||||
- system
|
||||
- web
|
||||
- java
|
||||
- jdk
|
||||
- openjdk
|
||||
- oracle
|
|
@ -1,13 +0,0 @@
|
|||
---
|
||||
- name: Converge
|
||||
hosts: all
|
||||
become: true
|
||||
|
||||
pre_tasks:
|
||||
- name: Update apt cache.
|
||||
apt: update_cache=true cache_valid_time=600
|
||||
when: ansible_os_family == 'Debian'
|
||||
changed_when: false
|
||||
|
||||
roles:
|
||||
- role: geerlingguy.java
|
|
@ -1,17 +0,0 @@
|
|||
---
|
||||
dependency:
|
||||
name: galaxy
|
||||
driver:
|
||||
name: docker
|
||||
platforms:
|
||||
- name: instance
|
||||
image: "geerlingguy/docker-${MOLECULE_DISTRO:-centos7}-ansible:latest"
|
||||
command: ${MOLECULE_DOCKER_COMMAND:-""}
|
||||
volumes:
|
||||
- /sys/fs/cgroup:/sys/fs/cgroup:ro
|
||||
privileged: true
|
||||
pre_build_image: true
|
||||
provisioner:
|
||||
name: ansible
|
||||
playbooks:
|
||||
converge: ${MOLECULE_PLAYBOOK:-converge.yml}
|
|
@ -1,41 +0,0 @@
|
|||
---
|
||||
- name: Include OS-specific variables for Fedora or FreeBSD.
|
||||
include_vars: "{{ ansible_distribution }}.yml"
|
||||
when: ansible_distribution == 'FreeBSD' or ansible_distribution == 'Fedora'
|
||||
|
||||
- name: Include version-specific variables for CentOS/RHEL.
|
||||
include_vars: "RedHat-{{ ansible_distribution_version.split('.')[0] }}.yml"
|
||||
when: ansible_distribution == 'CentOS' or
|
||||
ansible_distribution == 'Red Hat Enterprise Linux' or
|
||||
ansible_distribution == 'RedHat'
|
||||
|
||||
- name: Include version-specific variables for Ubuntu.
|
||||
include_vars: "{{ ansible_distribution }}-{{ ansible_distribution_version.split('.')[0] }}.yml"
|
||||
when: ansible_distribution == 'Ubuntu'
|
||||
|
||||
- name: Include version-specific variables for Debian.
|
||||
include_vars: "{{ ansible_distribution|title }}-{{ ansible_distribution_version.split('.')[0] }}.yml"
|
||||
when: ansible_os_family == 'Debian'
|
||||
|
||||
- name: Define java_packages.
|
||||
set_fact:
|
||||
java_packages: "{{ __java_packages | list }}"
|
||||
when: java_packages is not defined
|
||||
|
||||
# Setup/install tasks.
|
||||
- include_tasks: setup-RedHat.yml
|
||||
when: ansible_os_family == 'RedHat'
|
||||
|
||||
- include_tasks: setup-Debian.yml
|
||||
when: ansible_os_family == 'Debian'
|
||||
|
||||
- include_tasks: setup-FreeBSD.yml
|
||||
when: ansible_os_family == 'FreeBSD'
|
||||
|
||||
# Environment setup.
|
||||
- name: Set JAVA_HOME if configured.
|
||||
template:
|
||||
src: java_home.sh.j2
|
||||
dest: /etc/profile.d/java_home.sh
|
||||
mode: 0644
|
||||
when: java_home is defined and java_home
|
|
@ -1,16 +0,0 @@
|
|||
---
|
||||
# See: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=863199 and
|
||||
# https://github.com/geerlingguy/ansible-role-java/issues/64
|
||||
- name: Ensure 'man' directory exists.
|
||||
file: # noqa 208
|
||||
path: /usr/share/man/man1
|
||||
state: directory
|
||||
recurse: true
|
||||
when:
|
||||
- ansible_distribution == 'Ubuntu'
|
||||
- ansible_distribution_major_version | int >= 18
|
||||
|
||||
- name: Ensure Java is installed.
|
||||
apt:
|
||||
name: "{{ java_packages }}"
|
||||
state: present
|
|
@ -1,11 +0,0 @@
|
|||
---
|
||||
- name: Ensure Java is installed.
|
||||
pkgng:
|
||||
name: "{{ java_packages }}"
|
||||
state: present
|
||||
|
||||
- name: ensure proc is mounted
|
||||
mount: name=/proc fstype=procfs src=proc opts=rw state=mounted
|
||||
|
||||
- name: ensure fdesc is mounted
|
||||
mount: name=/dev/fd fstype=fdescfs src=fdesc opts=rw state=mounted
|
|
@ -1,5 +0,0 @@
|
|||
---
|
||||
- name: Ensure Java is installed.
|
||||
package:
|
||||
name: "{{ java_packages }}"
|
||||
state: present
|
|
@ -1 +0,0 @@
|
|||
export JAVA_HOME={{ java_home }}
|
|
@ -1,6 +0,0 @@
|
|||
---
|
||||
# JDK version options include:
|
||||
# - java
|
||||
# - openjdk-11-jdk
|
||||
__java_packages:
|
||||
- openjdk-11-jdk
|
|
@ -1,7 +0,0 @@
|
|||
---
|
||||
# JDK version options include:
|
||||
# - java
|
||||
# - openjdk-6-jdk
|
||||
# - openjdk-7-jdk
|
||||
__java_packages:
|
||||
- openjdk-7-jdk
|
|
@ -1,6 +0,0 @@
|
|||
---
|
||||
# JDK version options include:
|
||||
# - java
|
||||
# - openjdk-8-jdk
|
||||
__java_packages:
|
||||
- openjdk-8-jdk
|
|
@ -1,6 +0,0 @@
|
|||
---
|
||||
# JDK version options include:
|
||||
# - java
|
||||
# - java-1.8.0-openjdk
|
||||
__java_packages:
|
||||
- java-1.8.0-openjdk
|
|
@ -1,7 +0,0 @@
|
|||
---
|
||||
# JDK version options for FreeBSD include:
|
||||
# - openjdk
|
||||
# - openjdk6
|
||||
# - openjdk8
|
||||
__java_packages:
|
||||
- openjdk
|
|
@ -1,8 +0,0 @@
|
|||
---
|
||||
# JDK version options include:
|
||||
# - java
|
||||
# - java-1.6.0-openjdk
|
||||
# - java-1.7.0-openjdk
|
||||
# - java-1.8.0-openjdk
|
||||
__java_packages:
|
||||
- java-1.8.0-openjdk
|
|
@ -1,7 +0,0 @@
|
|||
---
|
||||
# JDK version options include:
|
||||
# - java-1.8.0-openjdk
|
||||
# - java-11-openjdk
|
||||
# - java-latest-openjdk
|
||||
__java_packages:
|
||||
- java-11-openjdk
|
|
@ -1,7 +0,0 @@
|
|||
---
|
||||
# JDK version options include:
|
||||
# - java
|
||||
# - openjdk-6-jdk
|
||||
# - openjdk-7-jdk
|
||||
__java_packages:
|
||||
- openjdk-7-jdk
|
|
@ -1,7 +0,0 @@
|
|||
---
|
||||
# JDK version options include:
|
||||
# - java
|
||||
# - openjdk-6-jdk
|
||||
# - openjdk-7-jdk
|
||||
__java_packages:
|
||||
- openjdk-7-jdk
|
|
@ -1,7 +0,0 @@
|
|||
---
|
||||
# JDK version options include:
|
||||
# - java
|
||||
# - openjdk-8-jdk
|
||||
# - openjdk-9-jdk
|
||||
__java_packages:
|
||||
- openjdk-8-jdk
|
|
@ -1,6 +0,0 @@
|
|||
---
|
||||
# JDK version options include:
|
||||
# - java
|
||||
# - openjdk-11-jdk
|
||||
__java_packages:
|
||||
- openjdk-11-jdk
|
|
@ -1,6 +0,0 @@
|
|||
---
|
||||
# JDK version options include:
|
||||
# - java
|
||||
# - openjdk-11-jdk
|
||||
__java_packages:
|
||||
- openjdk-11-jdk
|
Loading…
Reference in a new issue