Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 18 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
version: 2
updates:
- package-ecosystem: github-actions
directory: "/"
schedule:
interval: monthly
open-pull-requests-limit: 10
labels:
- enhancement
- dependency-management
- package-ecosystem: terraform
directory: "/"
schedule:
interval: monthly
open-pull-requests-limit: 10
labels:
- enhancement
- dependency-management
20 changes: 20 additions & 0 deletions .github/workflows/auto-assign.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
name: Auto-assign Issue
on:
issues:
types: [opened]
pull_request:
types: [opened, edited, synchronize, reopened]
jobs:
run:
runs-on: ubuntu-latest
permissions:
issues: write
pull-requests: write

steps:
- name: "auto-assign issue"
uses: pozil/auto-assign-issue@v2
with:
repo-token: ${{ secrets.PAT_GITHUB }}
teams: devops-ia
removePreviousAssignees: true
12 changes: 6 additions & 6 deletions .github/workflows/lock.yml
Original file line number Diff line number Diff line change
@@ -1,21 +1,21 @@
name: 'Lock Threads'
name: "Lock Threads"

on:
schedule:
- cron: '50 1 * * *'
- cron: "50 1 * * *"

jobs:
lock:
runs-on: ubuntu-latest
steps:
- uses: dessant/lock-threads@v4
- uses: dessant/lock-threads@v5
with:
github-token: ${{ secrets.GH_TOKEN }}
github-token: ${{ secrets.GITHUB_TOKEN }}
issue-comment: >
I'm going to lock this issue because it has been closed for _30 days_ ⏳. This helps our maintainers find and focus on the active issues.
If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.
issue-inactive-days: '30'
issue-inactive-days: "30"
pr-comment: >
I'm going to lock this pull request because it has been closed for _30 days_ ⏳. This helps our maintainers find and focus on the active issues.
If you have found a problem that seems related to this change, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.
pr-inactive-days: '30'
pr-inactive-days: "30"
4 changes: 2 additions & 2 deletions .github/workflows/pr-tittle.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name: 'Validate PR title'
name: "Validate PR title"

on:
pull_request_target:
pull_request:
types:
- opened
- edited
Expand Down
35 changes: 25 additions & 10 deletions .github/workflows/pre-commit.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,10 @@ on:
pull_request:
branches:
- main
- master

env:
TERRAFORM_DOCS_VERSION: v0.16.0
TFLINT_VERSION: v0.44.1
TFLINT_VERSION: v0.50.3

jobs:
collectInputs:
Expand All @@ -22,7 +21,7 @@ jobs:

- name: Get root directories
id: dirs
uses: clowdhaus/terraform-composite-actions/directories@v1.8.3
uses: clowdhaus/terraform-composite-actions/directories@v1.9.0

preCommitMinVersions:
name: Min TF pre-commit
Expand All @@ -32,38 +31,54 @@ jobs:
matrix:
directory: ${{ fromJson(needs.collectInputs.outputs.directories) }}
steps:
# https://github.com/orgs/community/discussions/25678#discussioncomment-5242449
- name: Delete huge unnecessary tools folder
run: |
rm -rf /opt/hostedtoolcache/CodeQL
rm -rf /opt/hostedtoolcache/Java_Temurin-Hotspot_jdk
rm -rf /opt/hostedtoolcache/Ruby
rm -rf /opt/hostedtoolcache/go

- name: Checkout
uses: actions/checkout@v4

- name: Terraform min/max versions
id: minMax
uses: clowdhaus/terraform-min-max@v1.2.7
uses: clowdhaus/terraform-min-max@v1.3.0
with:
directory: ${{ matrix.directory }}

- name: Pre-commit Terraform ${{ steps.minMax.outputs.minVersion }}
# Run only validate pre-commit check on min version supported
if: ${{ matrix.directory != '.' }}
uses: clowdhaus/terraform-composite-actions/pre-commit@v1.8.3
uses: clowdhaus/terraform-composite-actions/pre-commit@v1.9.0
with:
terraform-version: ${{ steps.minMax.outputs.minVersion }}
tflint-version: ${{ env.TFLINT_VERSION }}
args: 'terraform_validate --color=always --show-diff-on-failure --files ${{ matrix.directory }}/*'
args: "terraform_validate --color=always --show-diff-on-failure --files ${{ matrix.directory }}/*"

- name: Pre-commit Terraform ${{ steps.minMax.outputs.minVersion }}
# Run only validate pre-commit check on min version supported
if: ${{ matrix.directory == '.' }}
uses: clowdhaus/terraform-composite-actions/pre-commit@v1.8.3
uses: clowdhaus/terraform-composite-actions/pre-commit@v1.9.0
with:
terraform-version: ${{ steps.minMax.outputs.minVersion }}
tflint-version: ${{ env.TFLINT_VERSION }}
args: 'terraform_validate --color=always --show-diff-on-failure --files $(ls *.tf)'
args: "terraform_validate --color=always --show-diff-on-failure --files $(ls *.tf)"

preCommitMaxVersion:
name: Max TF pre-commit
runs-on: ubuntu-latest
needs: collectInputs
steps:
# https://github.com/orgs/community/discussions/25678#discussioncomment-5242449
- name: Delete huge unnecessary tools folder
run: |
rm -rf /opt/hostedtoolcache/CodeQL
rm -rf /opt/hostedtoolcache/Java_Temurin-Hotspot_jdk
rm -rf /opt/hostedtoolcache/Ruby
rm -rf /opt/hostedtoolcache/go

- name: Checkout
uses: actions/checkout@v4
with:
Expand All @@ -72,10 +87,10 @@ jobs:

- name: Terraform min/max versions
id: minMax
uses: clowdhaus/terraform-min-max@v1.2.7
uses: clowdhaus/terraform-min-max@v1.3.0

- name: Pre-commit Terraform ${{ steps.minMax.outputs.maxVersion }}
uses: clowdhaus/terraform-composite-actions/pre-commit@v1.8.3
uses: clowdhaus/terraform-composite-actions/pre-commit@v1.9.0
with:
terraform-version: ${{ steps.minMax.outputs.maxVersion }}
tflint-version: ${{ env.TFLINT_VERSION }}
Expand Down
23 changes: 11 additions & 12 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,19 +5,18 @@ on:
push:
branches:
- main
- master
paths:
- '**/*.tpl'
- '**/*.py'
- '**/*.tf'
- '.github/workflows/release.yml'
- "**/*.tpl"
- "**/*.py"
- "**/*.tf"
- ".github/workflows/release.yml"

jobs:
release:
name: Release
runs-on: ubuntu-latest
# Skip running release workflow on forks
if: github.repository_owner == 'terraform-nexus-modules'
if: github.repository_owner == 'devops-ia'
steps:
- name: Checkout
uses: actions/checkout@v4
Expand All @@ -26,12 +25,12 @@ jobs:
fetch-depth: 0

- name: Release
uses: cycjimmy/semantic-release-action@v3
uses: cycjimmy/semantic-release-action@v4
with:
semantic_version: 18.0.0
semantic_version: 23.0.2
extra_plugins: |
@semantic-release/changelog@6.0.0
@semantic-release/git@10.0.0
conventional-changelog-conventionalcommits@4.6.3
@semantic-release/changelog@6.0.3
@semantic-release/git@10.0.1
conventional-changelog-conventionalcommits@7.0.2
env:
GITHUB_TOKEN: ${{ secrets.GH_TOKEN }}
GITHUB_TOKEN: ${{ secrets.PAT_GITHUB }}
8 changes: 4 additions & 4 deletions .github/workflows/stale-actions.yaml
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
name: 'Mark or close stale issues and PRs'
name: "Mark or close stale issues and PRs"
on:
schedule:
- cron: '0 0 * * *'
- cron: "0 0 * * *"

jobs:
stale:
runs-on: ubuntu-latest
steps:
- uses: actions/stale@v6
- uses: actions/stale@v9
with:
repo-token: ${{ secrets.GH_TOKEN }}
repo-token: ${{ secrets.GITHUB_TOKEN }}
# Staling issues and PR's
days-before-stale: 30
stale-issue-label: stale
Expand Down
36 changes: 13 additions & 23 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Nexus Security

This module allows you to create **Nexus Security as a global resource** and **individual Nexus Security resources.** For individual examples, see the usage snippets and [examples](https://github.com/terraform-nexus-modules/terraform-nexus-security/tree/main/examples).
This module allows you to create **Nexus Security as a global resource** and **individual Nexus Security resources.** For individual examples, see the usage snippets and [examples](https://github.com/devops-ia/terraform-nexus-security/tree/main/examples).

## Provider
You need use a [Nexus provider](https://registry.terraform.io/providers/datadrivers/nexus/latest/docs).
Expand All @@ -19,8 +19,7 @@ provider "nexus" {

```hcl
module "nexus_security" {
source = "terraform-nexus-modules/security/nexus"
version = "1.0.0"
source = "devops-ia/security/nexus"

nexus_security_anonymous = [
{
Expand Down Expand Up @@ -118,8 +117,7 @@ module "nexus_security" {

```hcl
module "nexus_security_anonymous" {
source = "terraform-nexus-modules/security/nexus//modules/nexus-security-anonymous"
version = "1.0.0"
source = "devops-ia/security/nexus//modules/nexus-security-anonymous"

enabled = true
realm_name = "NexusAuthorizingRealm"
Expand All @@ -131,8 +129,7 @@ module "nexus_security_anonymous" {

```hcl
module "nexus_security_content_selector" {
source = "terraform-nexus-modules/security/nexus//modules/nexus-security-content-selector"
version = "1.0.0"
source = "devops-ia/security/nexus//modules/nexus-security-content-selector"

name = "example"
description = "example content selector"
Expand All @@ -144,8 +141,7 @@ module "nexus_security_content_selector" {

```hcl
module "nexus_security_ldap" {
source = "terraform-nexus-modules/security/nexus//modules/nexus-security-ldap"
version = "1.0.0"
source = "devops-ia/security/nexus//modules/nexus-security-ldap"

name = "example-ldap"
auth_schema = "NONE"
Expand Down Expand Up @@ -184,8 +180,7 @@ module "nexus_security_ldap" {

```hcl
module "nexus_security_ldap_order" {
source = "terraform-nexus-modules/security/nexus//modules/nexus-security-ldap-order"
version = "1.0.0"
source = "devops-ia/security/nexus//modules/nexus-security-ldap-order"

order = [
"server1",
Expand All @@ -198,8 +193,7 @@ module "nexus_security_ldap_order" {

```hcl
module "nexus_privilege_script" {
source = "terraform-nexus-modules/security/nexus//modules/nexus-security-realms"
version = "1.0.0"
source = "devops-ia/security/nexus//modules/nexus-security-realms"

active = [
"NexusAuthenticatingRealm",
Expand All @@ -212,8 +206,7 @@ module "nexus_privilege_script" {

```hcl
module "nexus_security_role" {
source = "terraform-nexus-modules/security/nexus//modules/nexus-security-role"
version = "1.0.0"
source = "devops-ia/security/nexus//modules/nexus-security-role"

description = "Docker deployment role"
name = "docker-deploy"
Expand All @@ -228,8 +221,7 @@ module "nexus_security_role" {

```hcl
module "nexus_security_saml" {
source = "terraform-nexus-modules/security/nexus//modules/nexus-security-saml"
version = "1.0.0"
source = "devops-ia/security/nexus//modules/nexus-security-saml"

idp_metadata = "<EntityDescriptor ...>...</EntityDescriptor>"
entity_id = "http://nexus.example/service/rest/v1/security/saml/metadata"
Expand All @@ -247,8 +239,7 @@ module "nexus_security_saml" {

```hcl
module "nexus_security_user" {
source = "terraform-nexus-modules/security/nexus//modules/nexus-security-user"
version = "1.0.0"
source = "devops-ia/security/nexus//modules/nexus-security-user"

userid = "admin"
firstname = "Administrator"
Expand All @@ -264,8 +255,7 @@ module "nexus_security_user" {

```hcl
module "nexus_security_user_token" {
source = "terraform-nexus-modules/security/nexus//modules/nexus-security-token"
version = "1.0.0"
source = "devops-ia/security/nexus//modules/nexus-security-token"

enabled = true
protect_content = false
Expand Down Expand Up @@ -324,8 +314,8 @@ No resources.

## Authors

Module is maintained by [DevOps IA](https://github.com/devops-ia) with help from [these awesome contributors](https://github.com/terraform-nexus-modules/terraform-nexus-security/graphs/contributors).
Module is maintained by [DevOps IA](https://github.com/devops-ia) with help from [these awesome contributors](https://github.com/devops-ia/terraform-nexus-security/graphs/contributors).

## License

Apache 2 Licensed. See [LICENSE](https://github.com/terraform-nexus-modules/terraform-nexus-security/blob/main/LICENSE) for full details.
Apache 2 Licensed. See [LICENSE](https://github.com/devops-ia/terraform-nexus-security/blob/main/LICENSE) for full details.