Add docker_action.yaml
This commit is contained in:
25
.gitea/workflows/014_docker_action.yaml
Normal file
25
.gitea/workflows/014_docker_action.yaml
Normal file
@@ -0,0 +1,25 @@
|
||||
# Run git update-index --chmod=+x entrypoint.sh to enable execution of action
|
||||
name: Docker Action
|
||||
|
||||
on:
|
||||
workflow_dispatch:
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- name: Checkout Repository
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Run Custom Action
|
||||
id: custom-action
|
||||
uses: ./.gitea/actions/docker-action
|
||||
with: # provide input parameter to above action
|
||||
name: 'Hang' # name is one of the inputs defined inside the action’s action.yml
|
||||
|
||||
- name: Print Processed Name
|
||||
run: |
|
||||
echo "Processed Name: ${{ steps.custom-action.outputs.processed-name }}"
|
||||
echo "workdir"
|
||||
ls -la
|
||||
@@ -1,29 +0,0 @@
|
||||
name: Caching with Go
|
||||
|
||||
on:
|
||||
workflow_dispatch:
|
||||
|
||||
jobs:
|
||||
Cache-Go:
|
||||
name: Cache Go
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
- uses: actions/setup-go@v3
|
||||
with:
|
||||
go-version: '>=1.20.1'
|
||||
- uses: https://gitea.com/actions/go-hashfiles@v0.0.1
|
||||
id: hash-go
|
||||
with:
|
||||
patterns: |
|
||||
go.mod
|
||||
go.sum
|
||||
- name: cache go
|
||||
id: cache-go
|
||||
uses: actions/cache@v3
|
||||
with: # Specify with your cache path
|
||||
path: |
|
||||
/your_cache_path
|
||||
key: go_path-${{ steps.hash-go.outputs.hash }}
|
||||
restore-keys: |
|
||||
go_cache-${{ steps.hash-go.outputs.hash }}
|
||||
Reference in New Issue
Block a user