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

GitHub Actions: Rename "Update GitHub Data" to "Schedule Daily 1100" #2222

Closed
9 of 10 tasks
macho-catt opened this issue Sep 3, 2021 · 3 comments · Fixed by #3368
Closed
9 of 10 tasks

GitHub Actions: Rename "Update GitHub Data" to "Schedule Daily 1100" #2222

macho-catt opened this issue Sep 3, 2021 · 3 comments · Fixed by #3368
Assignees
Labels
Complexity: Medium Feature: Board/GitHub Maintenance Project board maintenance that we have to do repeatedly Feature: Refactor GHA Refactoring GitHub actions to fit latest architectural norms role: back end/devOps Tasks for back-end developers size: 1pt Can be done in 4-6 hours Status: Updated No blockers and update is ready for review

Comments

@macho-catt
Copy link
Member

macho-catt commented Sep 3, 2021

Overview

As a member of the backend team, github actions are much more maintainable and easier to understand if they are structured based on triggers and functionality. For this issue, we want to update github-data.yml and rename the action to 'Schedule Daily 1100' so all scheduled actions that occur on 11am daily can live in this file.

Action Items

  • Review the notes below to understand recent changes to our architecture
  • Rename the file from 'github-data.yml' to 'schedule-daily-1100.yml'
  • Rename the name of the action from 'Update GitHub Data' to 'Schedule Daily 1100'
    • The name of the job should still stay the same (line 9)
  • Update the location of the accompanying js file
    • If not created yet, create a new directory under /github-actions/ called trigger-schedule
    • Create a subdirectory under /github-actions/trigger-schedule called github-data
    • Move the js file get-project-data.js under /github-actions/trigger-schedule/github-data
    • Update the github action's js requirement to reflect the change in directory
  • If possible, do a test on your local environment and make sure it still works

Resources/Instructions

Never done GitHub actions? Start here!
add-update-label-weekly.yml
GitHub Actions Workflow Directory
Accompanying JS

Architecture Notes

The idea behind the refactor is to organize our GitHub Actions so that developers can easily maintain and understand them. Currently, we want our GitHub Actions to be structured like so based on this proposal:

  • Schedules (military time)
    - Schedule Friday 0700
    - Schedule Thursday 1100
    - Schedule Daily 1100
  • Linters
    - Lint SCSS
  • PR Trigger
    - Add Linked Issue Labels to Pull Request
    - Add Pull Request Instructions
  • Issue Trigger
    - Add Missing Labels To Issues
  • WR - PR Trigger
    - WR Add Linked Issue Labels to Pull Request
    - WR Add Pull Request Instructions
  • WR - Issue Trigger

Actions with the same triggers (excluding linters, which will be their own category) will live in the same github action file. Scheduled actions will live in the same file if they trigger on the same schedule (i.e. all files that trigger everyday at 11am will live in one file, while files that trigger on Friday at 7am will be on a separate file).

That said, this structure is not set in stone. If any part of it feels strange, or you have questions, feel free to bring it up with the team so we can evolve this format!

Additional resources:

Events that trigger workflows
Workflow syntax for GitHub Actions
actions/github-script
GitHub RESTAPI
GitHub GraphQL

@macho-catt macho-catt added role: back end/devOps Tasks for back-end developers Complexity: Medium Feature: Refactor JS / Liquid Page is working fine - JS / Liquid needs changes to become consistent with other pages Feature: Board/GitHub Maintenance Project board maintenance that we have to do repeatedly labels Sep 3, 2021
@github-actions
Copy link

github-actions bot commented Sep 3, 2021

Hi @macho-catt.

Good job adding the required labels to this issue.

Just a friendly reminder to also move the issue into the "New Issue Approval" column under the Project Board. For more info on that, check Github's documentation here.
Thanks!

Additional Resources:
Wiki: How to add status labels to issues (WIP. Link will be updated when the wiki is done)
Wiki: How to create issues (WIP. Link will be updated when the wiki is done)

@ExperimentsInHonesty ExperimentsInHonesty added this to the y. Technical debt milestone Sep 5, 2021
@macho-catt macho-catt added Feature: Refactor GHA Refactoring GitHub actions to fit latest architectural norms and removed Feature: Refactor JS / Liquid Page is working fine - JS / Liquid needs changes to become consistent with other pages labels Sep 6, 2021
@macho-catt macho-catt changed the title Refactor GH-Action: Rename "Update GitHub Data" to "Schedule Daily 1100" GitHub Actions: Rename "Update GitHub Data" to "Schedule Daily 1100" Oct 19, 2021
@SAUMILDHANKAR SAUMILDHANKAR added the size: 1pt Can be done in 4-6 hours label Jun 18, 2022
@lilyarj lilyarj self-assigned this Jul 12, 2022
@github-actions
Copy link

Hi @lilyarj, thank you for taking up this issue! Hfla appreciates you :)

Do let fellow developers know about your:-
i. Availability: (When are you available to work on the issue/answer questions other programmers might have about your issue?)
ii. ETA: (When do you expect this issue to be completed?)

You're awesome!

P.S. - You may not take up another issue until this issue gets merged (or closed). Thanks again :)

@lilyarj
Copy link
Member

lilyarj commented Jul 13, 2022

Availability: 3hrs
ETA: 7/14

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Complexity: Medium Feature: Board/GitHub Maintenance Project board maintenance that we have to do repeatedly Feature: Refactor GHA Refactoring GitHub actions to fit latest architectural norms role: back end/devOps Tasks for back-end developers size: 1pt Can be done in 4-6 hours Status: Updated No blockers and update is ready for review
Projects
Development

Successfully merging a pull request may close this issue.

4 participants