Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ci: Add draft GH workflow to test all playbooks #180

Merged
merged 14 commits into from
Jun 18, 2024
Merged

Conversation

topher-lo
Copy link
Contributor

@topher-lo topher-lo commented Jun 18, 2024

NOTE:

This is an incomplete PR. Need to deal with accessing docker / localhost from within github actions issues in a follow-up PR.

What changed

  • Add workflow to run playbooks via pytest (very similar setup to ci: Add python tests suite #177)
  • Made webhooks secret
  • Gave each playbook trigger ref a meaningful name

Comments

  • Assumes no data is sent to webhook
  • Need to extend this test suite to support playbooks with incoming data into the trigger
  • Need to extend this test suite with scheduled workflows

@topher-lo topher-lo added tests Changes to unit and integration tests cicd Changes to CICD workflows and configurations labels Jun 18, 2024
@topher-lo topher-lo self-assigned this Jun 18, 2024
@github-actions github-actions bot added engine Improvements or additions to the workflow engine frontend Improvements or additions to the frontend internal Internal changes labels Jun 18, 2024
Signed-off-by: Chris Lo <46541035+topher-lo@users.noreply.github.com>
@topher-lo topher-lo removed frontend Improvements or additions to the frontend engine Improvements or additions to the workflow engine internal Internal changes labels Jun 18, 2024
# 3. Activate the workflow
subprocess.run(["tracecat", "workflow", "up", "--webhook", workflow_id])
# 4. Run the workflow
subprocess.run(["tracecat", "workflow", "run", workflow_id])
Copy link
Contributor Author

Choose a reason for hiding this comment

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

@daryllimyt how we can run this without ngrok?

@topher-lo topher-lo changed the title ci: Add GH workflow to test all playbooks ci: [INCOMPLETE] Add GH workflow to test all playbooks Jun 18, 2024
@github-actions github-actions bot added engine Improvements or additions to the workflow engine frontend Improvements or additions to the frontend internal Internal changes labels Jun 18, 2024
@topher-lo topher-lo changed the title ci: [INCOMPLETE] Add GH workflow to test all playbooks ci: Add draft GH workflow to test all playbooks Jun 18, 2024
@topher-lo topher-lo merged commit 43e6d5a into main Jun 18, 2024
5 of 6 checks passed
@topher-lo topher-lo deleted the ci/test-playbooks branch June 18, 2024 12:52
@topher-lo topher-lo removed frontend Improvements or additions to the frontend engine Improvements or additions to the workflow engine internal Internal changes labels Jun 18, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cicd Changes to CICD workflows and configurations tests Changes to unit and integration tests
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants