mirror of
https://github.com/project-zot/zot.git
synced 2025-03-18 02:22:53 -05:00
Changed Github workflow to cache dependencies
Signed-off-by: Catalin Hofnar <catalin.hofnar@gmail.com>
This commit is contained in:
parent
799eab63a9
commit
7c477f5ba3
1 changed files with 14 additions and 2 deletions
16
.github/workflows/ci-cd.yml
vendored
16
.github/workflows/ci-cd.yml
vendored
|
@ -40,11 +40,23 @@ jobs:
|
|||
go-version: 1.17.x
|
||||
- name: Check out source code
|
||||
uses: actions/checkout@v1
|
||||
- name: Install dependencies
|
||||
- name: Cache go dependencies
|
||||
id: cache-go-dependencies
|
||||
uses: actions/cache@v3
|
||||
with:
|
||||
path: |
|
||||
~/.cache/go-build
|
||||
~/go/pkg/mod
|
||||
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
|
||||
restore-keys: |
|
||||
${{ runner.os }}-go-
|
||||
- name: Install go dependencies
|
||||
if: steps.cache-go-dependencies.outputs.cache-hit != 'true'
|
||||
run: go mod download
|
||||
- name: Install other dependencies
|
||||
run: |
|
||||
cd $GITHUB_WORKSPACE
|
||||
go install github.com/swaggo/swag/cmd/swag@latest
|
||||
go mod download
|
||||
sudo apt-get update
|
||||
sudo apt-get install rpm
|
||||
sudo apt-get install snapd
|
||||
|
|
Loading…
Add table
Reference in a new issue