Skip to content

Commit 101416a

Browse files
jitendra42Tyler Titsworth
and
Tyler Titsworth
authored
Add Github workflow to update DockerHub repo description (#308)
* Added Github Action to update dockerhub repo description * Update .github/workflows/dockerhub-description.yml Co-authored-by: Tyler Titsworth <tyler.titsworth@intel.com> * Update .github/workflows/dockerhub-description.yml Co-authored-by: Tyler Titsworth <tyler.titsworth@intel.com> * Update .github/workflows/dockerhub-readmes.json Co-authored-by: Tyler Titsworth <tyler.titsworth@intel.com> * Update .github/workflows/dockerhub-readmes.json Co-authored-by: Tyler Titsworth <tyler.titsworth@intel.com> * pre-commit changes * moved config file to .github dir --------- Co-authored-by: Tyler Titsworth <tyler.titsworth@intel.com>
1 parent cb5bd9d commit 101416a

File tree

2 files changed

+79
-0
lines changed

2 files changed

+79
-0
lines changed

.github/dockerhub-readmes.json

+36
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
{
2+
"readmes": [
3+
{
4+
"fname": "./classical-ml/README.md",
5+
"repo-name": "intel/intel-optimized-ml"
6+
},
7+
{
8+
"fname": "./python/README.md",
9+
"repo-name": "intel/python"
10+
},
11+
{
12+
"fname": "./pytorch/README.md",
13+
"repo-name": "intel/intel-extension-for-pytorch"
14+
},
15+
{
16+
"fname": "./tensorflow/README.md",
17+
"repo-name": "intel/intel-extension-for-tensorflow"
18+
},
19+
{
20+
"fname": "./preset/README.md",
21+
"repo-name": "intel/data-analytics"
22+
},
23+
{
24+
"fname": "./preset/README.md",
25+
"repo-name": "intel/classical-ml"
26+
},
27+
{
28+
"fname": "./preset/README.md",
29+
"repo-name": "intel/deep-learning"
30+
},
31+
{
32+
"fname": "./preset/README.md",
33+
"repo-name": "intel/inference-optimization"
34+
}
35+
]
36+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
# Copyright (c) 2024 Intel Corporation
2+
#
3+
# Licensed under the Apache License, Version 2.0 (the "License");
4+
# you may not use this file except in compliance with the License.
5+
# You may obtain a copy of the License at
6+
#
7+
# http://www.apache.org/licenses/LICENSE-2.0
8+
#
9+
# Unless required by applicable law or agreed to in writing, software
10+
# distributed under the License is distributed on an "AS IS" BASIS,
11+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
# See the License for the specific language governing permissions and
13+
# limitations under the License.
14+
15+
name: Docker Description Publish
16+
on:
17+
push:
18+
branches: [ "main" ]
19+
permissions: read-all
20+
jobs:
21+
setup-matrix:
22+
runs-on: ubuntu-latest
23+
outputs:
24+
matrix: ${{ steps.set-matrix.outputs.matrix }}
25+
steps:
26+
- uses: actions/checkout@v4
27+
- name: Set matrix data
28+
id: set-matrix
29+
run: echo "matrix=$(jq -c . < .github/dockerhub-readmes.json)" >> $GITHUB_OUTPUT
30+
publish-dockerhub-description:
31+
runs-on: ubuntu-latest
32+
needs: setup-matrix
33+
strategy:
34+
matrix: ${{ fromJson(needs.setup-matrix.outputs.matrix) }}
35+
fail-fast: false
36+
steps:
37+
- uses: actions/checkout@v4
38+
- uses: peter-evans/dockerhub-description@v4
39+
with:
40+
username: ${{ secrets.DOCKERHUB_USERNAME }}
41+
password: ${{ secrets.DOCKERHUB_PASSWORD }}
42+
repository: ${{ matrix.readmes.repo-name }}
43+
readme-filepath: ${{ matrix.readmes.fname }}

0 commit comments

Comments
 (0)