Skip to content

Commit

Permalink
Merge pull request #861 from atc0005/use-local-job-defs-for-scheduled…
Browse files Browse the repository at this point in the history
…-jobs

Use local job defs for scheduled jobs
  • Loading branch information
atc0005 authored Feb 16, 2023
2 parents f60dd7e + df7b3fe commit 159c2c9
Show file tree
Hide file tree
Showing 3 changed files with 32 additions and 36 deletions.
31 changes: 0 additions & 31 deletions .github/workflows/build-images.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,37 +16,6 @@ on:
types: [opened, synchronize]

jobs:
# build_all_images_using_makefile:
# name: Build all images using Makefile
# runs-on: ubuntu-latest
# # Default: 360 minutes
# timeout-minutes: 20
#
# steps:
# - name: Print Docker version
# run: docker --version
#
# - name: Check out code into the Go module directory
# uses: actions/checkout@v3
#
# # Mark the current working directory as a safe directory in git to
# # resolve "dubious ownership" complaints.
# #
# # https://docs.github.com/en/actions/learn-github-actions/variables#default-environment-variables
# # https://confluence.atlassian.com/bbkb/git-command-returns-fatal-error-about-the-repository-being-owned-by-someone-else-1167744132.html
# # https://github.com/actions/runner-images/issues/6775
# # https://github.com/actions/checkout/issues/766
# - name: Mark the current working directory as a safe directory in git
# # run: git config --global --add safe.directory "$GITHUB_WORKSPACE"
# run: git config --global --add safe.directory "${PWD}"
#
# # bsdmainutils provides "column" which is used by the Makefile
# - name: Install Ubuntu packages
# run: sudo apt-get update && sudo apt-get install -y --no-install-recommends make gcc bsdmainutils
#
# - name: Build images using project Makefile
# run: make build

build_stable_image_using_makefile:
name: Build stable image using Makefile
runs-on: ubuntu-latest
Expand Down
33 changes: 30 additions & 3 deletions .github/workflows/scheduled-monthly.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,33 @@ on:
- cron: "30 4 1 * *"

jobs:
lint:
name: Monthly Tasks
uses: atc0005/shared-project-resources/.github/workflows/scheduled-monthly.yml@master
build_all_images_using_makefile:
name: Build all images using Makefile
runs-on: ubuntu-latest
# Default: 360 minutes
timeout-minutes: 20

steps:
- name: Print Docker version
run: docker --version

- name: Check out code into the Go module directory
uses: actions/checkout@v3

# Mark the current working directory as a safe directory in git to
# resolve "dubious ownership" complaints.
#
# https://docs.github.com/en/actions/learn-github-actions/variables#default-environment-variables
# https://confluence.atlassian.com/bbkb/git-command-returns-fatal-error-about-the-repository-being-owned-by-someone-else-1167744132.html
# https://github.com/actions/runner-images/issues/6775
# https://github.com/actions/checkout/issues/766
- name: Mark the current working directory as a safe directory in git
# run: git config --global --add safe.directory "$GITHUB_WORKSPACE"
run: git config --global --add safe.directory "${PWD}"

# bsdmainutils provides "column" which is used by the Makefile
- name: Install Ubuntu packages
run: sudo apt-get update && sudo apt-get install -y --no-install-recommends make gcc bsdmainutils

- name: Build images using project Makefile
run: make build
4 changes: 2 additions & 2 deletions .github/workflows/scheduled-weekly.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,5 +17,5 @@ on:

jobs:
lint:
name: Weekly Tasks
uses: atc0005/shared-project-resources/.github/workflows/scheduled-weekly.yml@master
name: Lint
uses: atc0005/shared-project-resources/.github/workflows/lint-project-files.yml@master

0 comments on commit 159c2c9

Please # to comment.