Skip to content

Commit 3e9133c

Browse files
author
Ware, Joseph (DLSLtd,RAL,LSCI)
committed
Move Helm chart
1 parent f8ac5ef commit 3e9133c

File tree

2 files changed

+33
-18
lines changed

2 files changed

+33
-18
lines changed

.github/workflows/_container.yml

Lines changed: 0 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -58,21 +58,3 @@ jobs:
5858
push: true
5959
tags: ${{ steps.meta.outputs.tags }}
6060
labels: ${{ steps.meta.outputs.labels }}
61-
62-
{% if helm %}
63-
- name: Install Helm
64-
uses: Azure/setup-helm@v4
65-
id: install
66-
67-
- name: Log in to GitHub Container Registry
68-
if: github.ref_type == 'tag'
69-
run: |
70-
echo ${{ secrets.GITHUB_TOKEN }} | helm registry login ghcr.io/${{ github.repository }} --username ${{ github.repository_owner }} --password-stdin
71-
72-
- name: package chart and push it
73-
if: github.ref_type == 'tag'
74-
run: |
75-
helm dependencies update helm/{{ repo_name }}
76-
helm package helm/{{ repo_name }} --version ${{ steps.meta.outputs.version }} --app-version ${{ steps.meta.outputs.version }} -d /tmp/
77-
helm push /tmp/{{ repo_name }}-${{ steps.meta.outputs.version }}.tgz oci://ghcr.io/${{ github.repository_owner }}/charts
78-
{% end if %}
Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
on:
2+
workflow_call:
3+
4+
jobs:
5+
build:
6+
runs-on: ubuntu-latest
7+
8+
steps:
9+
- name: Create tags for publishing image
10+
id: meta
11+
uses: docker/metadata-action@v5
12+
with:
13+
images: ghcr.io/${{ github.repository }}
14+
tags: |
15+
type=semver,pattern={{version}}
16+
type=ref,event=tag
17+
type=raw,value=latest
18+
19+
- name: Install Helm
20+
uses: Azure/setup-helm@v4
21+
id: install
22+
23+
- name: Log in to GitHub Container Registry
24+
if: github.ref_type == 'tag'
25+
run: |
26+
echo ${{ secrets.GITHUB_TOKEN }} | helm registry login ghcr.io/${{ github.repository }} --username ${{ github.repository_owner }} --password-stdin
27+
28+
- name: package chart and push it
29+
if: github.ref_type == 'tag'
30+
run: |
31+
helm dependencies update helm/{{ repo_name }}
32+
helm package helm/{{ repo_name }} {% raw %}--version ${{ steps.meta.outputs.version }} --app-version ${{ steps.meta.outputs.version }}{% endraw %} -d /tmp/
33+
helm push /tmp/{{ repo_name }}-{% raw %}${{ steps.meta.outputs.version }}.tgz oci://ghcr.io/${{ github.repository_owner }}{% endraw %}/charts

0 commit comments

Comments
 (0)