generated from 39services/ansible_collection_39systems.template
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #3 from func0der/add_phpstorm
- Loading branch information
Showing
26 changed files
with
835 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
--- | ||
# This workflow requires a GALAXY_API_KEY secret present in the GitHub | ||
# repository or organization. | ||
|
||
name: CI | ||
|
||
"on": | ||
push: | ||
branches: | ||
- main | ||
paths: | ||
- "roles/phpstorm/**" | ||
workflow_dispatch: | ||
|
||
jobs: | ||
molecule: | ||
runs-on: ubuntu-20.04 | ||
name: Molecule test "phpstorm" role | ||
strategy: | ||
fail-fast: false | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
|
||
- name: "Free Disk Space." | ||
uses: jlumbroso/free-disk-space@main | ||
with: | ||
tool-cache: true | ||
|
||
- name: Set up Python | ||
uses: actions/setup-python@v4 | ||
with: | ||
python-version: '3.x' | ||
|
||
- name: Install dependencies. | ||
working-directory: roles/phpstorm | ||
run: pip3 install -r requirements.txt | ||
|
||
- name: Install Ansible dependencies. | ||
run: ansible-galaxy install -r requirements.yml | ||
|
||
- name: Install Ansible dependencies specific to role. | ||
working-directory: roles/phpstorm | ||
run: ansible-galaxy install -r requirements.yml | ||
|
||
- name: Run molecule | ||
working-directory: roles/phpstorm | ||
run: "molecule test" | ||
|
||
... |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
--- | ||
skip_list: | ||
- "var-naming[no-role-prefix]" # Allow _ and __ internal vars | ||
- run-once[task] # This check is broken | ||
|
||
# Exclude downloaded roles and collections from linting | ||
exclude_paths: | ||
- collections/** | ||
- roles/** | ||
- changelogs | ||
|
||
... |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,153 @@ | ||
# Editors | ||
.idea/ | ||
.vscode/ | ||
|
||
# Credentials | ||
**/kubeconfig.yaml | ||
.*vault* | ||
|
||
# Terraform | ||
**/.terraform/* | ||
*.tfstate | ||
*.tfstate.* | ||
.terraform.lock.hcl | ||
|
||
# Ansible | ||
/tests/output/ | ||
/changelogs/.plugin-cache.yaml | ||
output/ | ||
.collection_root/* | ||
|
||
**/collections/** | ||
!**/collections/requirements.yml | ||
**/roles/** | ||
!**/roles/requirements.yml | ||
!/**/.gitkeep | ||
|
||
# Byte-compiled / optimized / DLL files | ||
__pycache__/ | ||
*.py[cod] | ||
*$py.class | ||
|
||
# C extensions | ||
*.so | ||
|
||
# Distribution / packaging | ||
.Python | ||
build/ | ||
develop-eggs/ | ||
dist/ | ||
downloads/ | ||
eggs/ | ||
.eggs/ | ||
lib/ | ||
lib64/ | ||
parts/ | ||
sdist/ | ||
var/ | ||
wheels/ | ||
pip-wheel-metadata/ | ||
share/python-wheels/ | ||
*.egg-info/ | ||
.installed.cfg | ||
*.egg | ||
MANIFEST | ||
|
||
# PyInstaller | ||
# Usually these files are written by a python script from a template | ||
# before PyInstaller builds the exe, so as to inject date/other infos into it. | ||
*.manifest | ||
*.spec | ||
|
||
# Installer logs | ||
pip-log.txt | ||
pip-delete-this-directory.txt | ||
|
||
# Unit test / coverage reports | ||
htmlcov/ | ||
.tox/ | ||
.nox/ | ||
.coverage | ||
.coverage.* | ||
.cache | ||
nosetests.xml | ||
coverage.xml | ||
*.cover | ||
*.py,cover | ||
.hypothesis/ | ||
.pytest_cache/ | ||
|
||
# Translations | ||
*.mo | ||
*.pot | ||
|
||
# Django stuff: | ||
*.log | ||
local_settings.py | ||
db.sqlite3 | ||
db.sqlite3-journal | ||
|
||
# Flask stuff: | ||
instance/ | ||
.webassets-cache | ||
|
||
# Scrapy stuff: | ||
.scrapy | ||
|
||
# Sphinx documentation | ||
docs/_build/ | ||
|
||
# PyBuilder | ||
target/ | ||
|
||
# Jupyter Notebook | ||
.ipynb_checkpoints | ||
|
||
# IPython | ||
profile_default/ | ||
ipython_config.py | ||
|
||
# pyenv | ||
.python-version | ||
|
||
# pipenv | ||
# According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control. | ||
# However, in case of collaboration, if having platform-specific dependencies or dependencies | ||
# having no cross-platform support, pipenv may install dependencies that don't work, or not | ||
# install all needed dependencies. | ||
#Pipfile.lock | ||
|
||
# PEP 582; used by e.g. github.com/David-OConnor/pyflow | ||
__pypackages__/ | ||
|
||
# Celery stuff | ||
celerybeat-schedule | ||
celerybeat.pid | ||
|
||
# SageMath parsed files | ||
*.sage.py | ||
|
||
# Environments | ||
.venv | ||
venv/ | ||
ENV/ | ||
env.bak/ | ||
venv.bak/ | ||
|
||
# Spyder project settings | ||
.spyderproject | ||
.spyproject | ||
|
||
# Rope project settings | ||
.ropeproject | ||
|
||
# mkdocs documentation | ||
/site | ||
|
||
# mypy | ||
.mypy_cache/ | ||
.dmypy.json | ||
dmypy.json | ||
|
||
# Pyre type checker | ||
.pyre/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
--- | ||
repos: | ||
- repo: https://github.com/pre-commit/pre-commit-hooks | ||
rev: v4.4.0 | ||
hooks: | ||
- id: trailing-whitespace | ||
args: [--markdown-linebreak-ext=md] | ||
- id: end-of-file-fixer | ||
- id: check-added-large-files | ||
- id: check-yaml | ||
files: .*\.(yaml|yml)$ | ||
args: [--unsafe] | ||
- id: check-json | ||
- id: check-xml | ||
- id: check-toml | ||
- id: check-case-conflict | ||
- id: check-merge-conflict | ||
- id: detect-private-key | ||
- id: check-shebang-scripts-are-executable | ||
- id: check-executables-have-shebangs | ||
- id: check-added-large-files | ||
|
||
- repo: https://github.com/ansible/ansible-lint | ||
rev: v6.17.0 | ||
hooks: | ||
- id: ansible-lint | ||
files: \.(yaml|yml)$ | ||
entry: sh -c 'python3 -m pip install -r requirements.txt; python3 -m ansiblelint -v --force-color' | ||
|
||
... |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
MIT License | ||
|
||
Copyright (c) 2023 diademiemi | ||
|
||
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. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,86 @@ | ||
Ansible Role PhpStorm | ||
========= | ||
|
||
[![Molecule test](https://github.com/diademiemi/ansible_collection_diademiemi.jetbrains/actions/workflows/ansible-role-phpstorm.yml/badge.svg)](https://github.com/diademiemi/ansible_collection_diademiemi.jetbrains/actions/workflows/ansible-role-phpstorm.yml) | ||
|
||
This is an Ansible role to install and configure phpstorm. | ||
|
||
Include more information about phpstorm in this section. | ||
|
||
Requirements | ||
------------ | ||
These platforms are supported: | ||
- Ubuntu 20.04 | ||
- Ubuntu 22.04 | ||
- Debian 10 | ||
- Debian 11 | ||
- Debian 12 | ||
- EL 8 (Tested on Rocky Linux 8) | ||
- EL 9 (Tested on Rocky Linux 9) | ||
- Fedora 38 | ||
- openSUSE Leap 15.5 | ||
|
||
<!-- | ||
- List hardware requirements here | ||
--> | ||
|
||
Role Variables | ||
-------------- | ||
|
||
Variable | Default | Description | ||
--- | --- | --- | ||
`jetbrains_phpstorm_version` | `2023.1.4` | Version of phpstorm to install | ||
`jetbrains_phpstorm_plugins` | `[]` | List of plugin IDs to install | ||
`jetbrains_phpstorm_plugins_user` | `{{ ansible_user_id }}` | User to install plugins for. Defaults to the remote user | ||
`jetbrains_phpstorm_plugins_group` | `{{ ansible_user_id }}` | Group to install plugins for. Defaults to the remote user | ||
<!-- | ||
`variable` | `default` | Variable example | ||
`long_variable` | See [defaults/main.yml](./defaults/main.yml) | Variable referring to defaults | ||
`distro_specific_variable` | See [vars/debian.yml](./vars/debian.yml) | Variable referring to distro-specific variables | ||
--> | ||
|
||
Dependencies | ||
------------ | ||
<!-- List dependencies on other roles or criteria --> | ||
- `diademiemi.jetbrains.common` role | ||
|
||
|
||
Example Playbook | ||
---------------- | ||
|
||
```yaml | ||
- name: Use diademiemi.jetbrains.phpstorm role | ||
hosts: "{{ target | default('phpstorm') }}" | ||
roles: | ||
- role: "diademiemi.jetbrains.phpstorm" | ||
tags: ['diademiemi', 'phpstorm', 'setup'] ``` | ||
|
||
``` | ||
|
||
License | ||
------- | ||
|
||
MIT | ||
|
||
Author Information | ||
------------------ | ||
|
||
- diademiemi (@diademiemi) | ||
|
||
Role Testing | ||
------------ | ||
|
||
This repository comes with Molecule that run in Podman on the supported platforms. | ||
Install Molecule by running | ||
|
||
```bash | ||
pip3 install -r requirements.txt | ||
``` | ||
|
||
Run the tests with | ||
|
||
```bash | ||
molecule test | ||
``` | ||
|
||
These tests are automatically ran by GitHub Actions on push. If the tests are successful, the role is automatically published to Ansible Galaxy. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
{ | ||
"folders": [ | ||
{ | ||
"path": "." | ||
} | ||
], | ||
"settings": { | ||
"ansible.python.interpreterPath": "/bin/python3", | ||
"files.associations": { | ||
"**/tasks/**/*.yml": "ansible", | ||
"**/vars/**/*.yml": "ansible", | ||
"**/molecule/*.yml": "ansible", | ||
"**/molecule/molecule.yml": "ansible", | ||
"**/handlers/**/*.yml": "ansible", | ||
"**/defaults/*.yml": "ansible", | ||
"**/host_vars/**/*.yml": "ansible", | ||
"**/group_vars/**/*.yml": "ansible", | ||
"**/inventories/*.yml": "ansible", | ||
"**/meta/*.yml": "ansible", | ||
"**/requirements.yml": "ansible", | ||
"**/terraform/**": "terraform", | ||
"**/inventories/terraform/**": "ansible" | ||
} | ||
}, | ||
"extensions": { | ||
"recommendations": [ | ||
"redhat.ansible", | ||
"redhat.vscode-yaml", | ||
"hashicorp.terraform", | ||
"GitHub.copilot-nightly", | ||
"GitLab.gitlab-workflow", | ||
"yzhang.markdown-all-in-one" | ||
] | ||
} | ||
} |
Oops, something went wrong.