Skip to content

Conversation

@joao-aveiro
Copy link
Collaborator

@joao-aveiro joao-aveiro commented Mar 24, 2025

This pull request includes updates to the action.yaml file for the Ethiack Job Manager Action. The most important changes include the addition of new inputs and the corresponding logic to handle these inputs in the runs section.

Updates to action.yaml:

  • Author Information Update:

    • Removed the comma from the author's name. ([action.yamlL3-R3](https://github.com/ethiack/github-action/pull/2/files#diff-fab4d7fb461bc6fbe9587f6c03fff98102b1c744145edcf2a993f2ff7cb05a0dL3-R3))
  • New Inputs Added:

    • Added beacon_id input, which is optional for the "launch" and "check" commands. ([action.yamlR21-R28](https://github.com/ethiack/github-action/pull/2/files#diff-fab4d7fb461bc6fbe9587f6c03fff98102b1c744145edcf2a993f2ff7cb05a0dR21-R28))
    • Added event_slug input, which is also optional for the "launch" and "check" commands. ([action.yamlR21-R28](https://github.com/ethiack/github-action/pull/2/files#diff-fab4d7fb461bc6fbe9587f6c03fff98102b1c744145edcf2a993f2ff7cb05a0dR21-R28))
  • Logic to Handle New Inputs:

    • Included logic to add the beacon_id input to the command if provided for the "launch" or "check" commands. ([action.yamlL71-R90](https://github.com/ethiack/github-action/pull/2/files#diff-fab4d7fb461bc6fbe9587f6c03fff98102b1c744145edcf2a993f2ff7cb05a0dL71-R90))
    • Included logic to add the event_slug input to the command if provided for the "launch" or "check" commands. ([action.yamlL71-R90](https://github.com/ethiack/github-action/pull/2/files#diff-fab4d7fb461bc6fbe9587f6c03fff98102b1c744145edcf2a993f2ff7cb05a0dL71-R90))Users can now specify the Beacon and the Event they want to run the scans on, thus enabling CI/CD scanning of internal assets and multiple machine events.

Users can now specify the Beacon and the Event they want to run
the scans on, thus enabling CI/CD scanning of internal assets
and multiple machine events.

BREAKING: New multi-event logic may break existing environments
where event disambiguation might be required.
@joao-aveiro joao-aveiro requested a review from jmartinhoj March 24, 2025 12:29
@joao-aveiro joao-aveiro requested a review from Copilot April 3, 2025 16:45
@joao-aveiro joao-aveiro marked this pull request as ready for review April 3, 2025 16:45
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR adds support for Beacon and Multi-Event capabilities in the Ethiack Job Manager Action for GitHub Actions.

  • Modified the author field for branding consistency.
  • Added new inputs (beacon_id and event_slug) in the action configuration.
  • Updated the command construction logic to include beacon_id and event_slug when the command is "launch" or "check".
Comments suppressed due to low confidence (2)

action.yaml:3

  • [nitpick] The author field has changed from 'Ethiack, Lda.' to 'Ethiack, Lda'. Consider restoring the trailing period for consistency, if that was originally intended.
author: 'Ethiack, Lda'

action.yaml:80

  • The conditional syntax using parentheses combined with [ tests ] may not be portable across all shell environments. Consider revising the condition to a more standard format, for example by using 'if [[ "${{ inputs.command }}" == "launch" || "${{ inputs.command }}" == "check" ]] && [ -n "${{ inputs.beacon_id }}" ]; then' or splitting the conditions for clarity.
if ([ "${{ inputs.command }}" = "launch" ] || [ "${{ inputs.command }}" = "check" ]) && [ -n "${{ inputs.beacon_id }}" ]; then

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
@joao-aveiro joao-aveiro requested a review from Copilot April 3, 2025 16:47
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR adds Beacon and Multi-Event capabilities, enabling users to specify a beacon ID and an event slug to target specific scans.

  • Introduces new inputs for beacon_id and event_slug in the action configuration.
  • Updates the command construction logic to include the new inputs when executing launch or check commands.
Comments suppressed due to low confidence (1)

action.yaml:84

  • The conditional for event_slug lacks proper grouping for the OR conditions, which may lead to an incorrect evaluation of the input. Consider using parentheses to group the command comparisons similar to the beacon_id condition.
if [ "${{ inputs.command }}" = "launch" ] || [ "${{ inputs.command }}" = "check" ] && [ -n "${{ inputs.event_slug }}" ]; then

@joao-aveiro joao-aveiro requested a review from Copilot April 3, 2025 16:53
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR adds support for beacon and multi-event capabilities to the Ethiack Job Manager Action, enabling users to specify a beacon ID and an event slug when launching or checking scans.

  • Added new YAML inputs for beacon_id and event_slug.
  • Updated the command generation logic to include these new inputs when applicable.
  • Minor update to the author field in the action metadata.
Comments suppressed due to low confidence (1)

action.yaml:3

  • [nitpick] The removal of the period from 'Ethiack, Lda.' might be unintentional. Please confirm if the punctuation change is deliberate.
author: 'Ethiack, Lda'

@joao-aveiro joao-aveiro merged commit aff8cec into staging Apr 8, 2025
1 check passed
github-actions bot pushed a commit that referenced this pull request Apr 8, 2025
## [1.1.0-rc.1](1.0.0...1.1.0-rc.1) (2025-04-08)

### 🚀 Features

* add Beacon and Multi-Event capabilities ([#2](#2)) ([aff8cec](aff8cec))
@github-actions
Copy link

github-actions bot commented Apr 8, 2025

🎉 This PR is included in version 1.1.0-rc.1 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

github-actions bot pushed a commit that referenced this pull request Apr 10, 2025
## [1.1.0](1.0.0...1.1.0) (2025-04-10)

### 🦊 CI/CD

* update commitlint config ([df9d096](df9d096))

### 🚀 Features

* add Beacon and Multi-Event capabilities ([#2](#2)) ([aff8cec](aff8cec))
@github-actions
Copy link

🎉 This PR is included in version 1.1.0 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants