Skip to content

Commit ccb3372

Browse files
authored
Merge branch 'main' into renovate/mattermost-package-dependencies
2 parents 08dd7db + 05ae7cf commit ccb3372

16 files changed

+57
-50
lines changed

.github/workflows/codeql.yaml

+3-3
Original file line numberDiff line numberDiff line change
@@ -33,13 +33,13 @@ jobs:
3333

3434
# Initializes the CodeQL tools for scanning.
3535
- name: Initialize CodeQL
36-
uses: github/codeql-action/init@23acc5c183826b7a8a97bce3cecc52db901f8251 # v3.25.10
36+
uses: github/codeql-action/init@b611370bb5703a7efb587f9d136a52ea24c5c38c # v3.25.11
3737
with:
3838
languages: ${{ matrix.language }}
3939
- name: Autobuild
40-
uses: github/codeql-action/autobuild@23acc5c183826b7a8a97bce3cecc52db901f8251 # v3.25.10
40+
uses: github/codeql-action/autobuild@b611370bb5703a7efb587f9d136a52ea24c5c38c # v3.25.11
4141

4242
- name: Perform CodeQL Analysis
43-
uses: github/codeql-action/analyze@23acc5c183826b7a8a97bce3cecc52db901f8251 # v3.25.10
43+
uses: github/codeql-action/analyze@b611370bb5703a7efb587f9d136a52ea24c5c38c # v3.25.11
4444
with:
4545
category: "/language:${{matrix.language}}"

.github/workflows/commitlint.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,4 +8,4 @@ on:
88
jobs:
99
validate:
1010
name: Validate
11-
uses: defenseunicorns/uds-common/.github/workflows/commitlint.yaml@61450a210fd16cf14157ee417f9682a4664c05e5 # v0.6.0
11+
uses: defenseunicorns/uds-common/.github/workflows/commitlint.yaml@772b3337950b7c8e0882c527263684306bba7ce4 # v0.7.1

.github/workflows/lint.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ jobs:
2020
fetch-depth: 0
2121

2222
- name: Environment setup
23-
uses: defenseunicorns/uds-common/.github/actions/setup@61450a210fd16cf14157ee417f9682a4664c05e5 # v0.6.0
23+
uses: defenseunicorns/uds-common/.github/actions/setup@772b3337950b7c8e0882c527263684306bba7ce4 # v0.7.1
2424
with:
2525
registry1Username: ${{ secrets.IRON_BANK_ROBOT_USERNAME }}
2626
registry1Password: ${{ secrets.IRON_BANK_ROBOT_PASSWORD }}

.github/workflows/scorecard.yaml

+2-2
Original file line numberDiff line numberDiff line change
@@ -37,14 +37,14 @@ jobs:
3737
# Upload the results as artifacts (optional). Commenting out will disable uploads of run results in SARIF
3838
# format to the repository Actions tab.
3939
- name: "Upload artifact"
40-
uses: actions/upload-artifact@65462800fd760344b1a7b4382951275a0abb4808 # v4.3.3
40+
uses: actions/upload-artifact@0b2256b8c012f0828dc542b3febcab082c67f72b # v4.3.4
4141
with:
4242
name: SARIF file
4343
path: results.sarif
4444
retention-days: 5
4545

4646
# Upload the results to GitHub's code scanning dashboard.
4747
- name: "Upload to code-scanning"
48-
uses: github/codeql-action/upload-sarif@23acc5c183826b7a8a97bce3cecc52db901f8251 # v3.25.10
48+
uses: github/codeql-action/upload-sarif@b611370bb5703a7efb587f9d136a52ea24c5c38c # v3.25.11
4949
with:
5050
sarif_file: results.sarif

.github/workflows/tag-and-release.yaml

+7-7
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ jobs:
2525
publish-package:
2626
needs: tag-new-version
2727
if: ${{ needs.tag-new-version.outputs.release_created == 'true' }}
28-
runs-on: ${{ matrix.architecture == 'arm64' && 'uds-ubuntu-arm64-4-core' || 'ubuntu-latest' }}
28+
runs-on: ${{ matrix.architecture == 'arm64' && 'uds-swf-ubuntu-arm64-4-core' || 'ubuntu-latest' }}
2929
strategy:
3030
matrix:
3131
flavor: [upstream, registry1]
@@ -43,28 +43,28 @@ jobs:
4343
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
4444

4545
- name: Environment setup
46-
uses: defenseunicorns/uds-common/.github/actions/setup@61450a210fd16cf14157ee417f9682a4664c05e5 # v0.6.0
46+
uses: defenseunicorns/uds-common/.github/actions/setup@772b3337950b7c8e0882c527263684306bba7ce4 # v0.7.1
4747
with:
4848
registry1Username: ${{ secrets.IRON_BANK_ROBOT_USERNAME }}
4949
registry1Password: ${{ secrets.IRON_BANK_ROBOT_PASSWORD }}
5050
ghToken: ${{ secrets.GITHUB_TOKEN }}
5151

5252
- name: Build Package
53-
run: uds run -f tasks/publish.yaml build-package --set FLAVOR=${{ matrix.flavor }}
53+
run: uds run -f tasks/publish.yaml build-package --set FLAVOR=${{ matrix.flavor }} --no-progress
5454

5555
- name: Test Package
5656
if: ${{ runner.arch != 'ARM64' }}
57-
run: uds run -f tasks/publish.yaml test-package --set FLAVOR=${{ matrix.flavor }}
57+
run: uds run -f tasks/publish.yaml test-package --set FLAVOR=${{ matrix.flavor }} --no-progress
5858

5959
- name: Publish Package
60-
run: uds run -f tasks/publish.yaml publish-package --set FLAVOR=${{ matrix.flavor }}
60+
run: uds run -f tasks/publish.yaml publish-package --set FLAVOR=${{ matrix.flavor }} --no-progress
6161

6262
- name: Debug Output
6363
if: ${{ always() }}
64-
uses: defenseunicorns/uds-common/.github/actions/debug-output@61450a210fd16cf14157ee417f9682a4664c05e5 # v0.6.0
64+
uses: defenseunicorns/uds-common/.github/actions/debug-output@772b3337950b7c8e0882c527263684306bba7ce4 # v0.7.1
6565

6666
- name: Save logs
6767
if: always()
68-
uses: defenseunicorns/uds-common/.github/actions/save-logs@61450a210fd16cf14157ee417f9682a4664c05e5 # v0.6.0
68+
uses: defenseunicorns/uds-common/.github/actions/save-logs@772b3337950b7c8e0882c527263684306bba7ce4 # v0.7.1
6969
with:
7070
suffix: ${{ matrix.flavor }}-${{ matrix.architecture }}-${{ github.run_id }}-${{ github.run_attempt }}

.github/workflows/test.yaml

+5-5
Original file line numberDiff line numberDiff line change
@@ -46,29 +46,29 @@ jobs:
4646
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
4747

4848
- name: Environment setup
49-
uses: defenseunicorns/uds-common/.github/actions/setup@61450a210fd16cf14157ee417f9682a4664c05e5 # v0.6.0
49+
uses: defenseunicorns/uds-common/.github/actions/setup@772b3337950b7c8e0882c527263684306bba7ce4 # v0.7.1
5050
with:
5151
registry1Username: ${{ secrets.IRON_BANK_ROBOT_USERNAME }}
5252
registry1Password: ${{ secrets.IRON_BANK_ROBOT_PASSWORD }}
5353
ghToken: ${{ secrets.GITHUB_TOKEN }}
5454

5555
- name: Test
56-
uses: defenseunicorns/uds-common/.github/actions/test@61450a210fd16cf14157ee417f9682a4664c05e5 # v0.6.0
56+
uses: defenseunicorns/uds-common/.github/actions/test@772b3337950b7c8e0882c527263684306bba7ce4 # v0.7.1
5757
with:
5858
flavor: ${{ matrix.flavor }}
5959
type: ${{ matrix.type }}
6060

6161
- name: Debug Output
6262
if: ${{ always() }}
63-
uses: defenseunicorns/uds-common/.github/actions/debug-output@61450a210fd16cf14157ee417f9682a4664c05e5 # v0.6.0
63+
uses: defenseunicorns/uds-common/.github/actions/debug-output@772b3337950b7c8e0882c527263684306bba7ce4 # v0.7.1
6464

6565
- name: Save logs
6666
if: always()
67-
uses: defenseunicorns/uds-common/.github/actions/save-logs@61450a210fd16cf14157ee417f9682a4664c05e5 # v0.6.0
67+
uses: defenseunicorns/uds-common/.github/actions/save-logs@772b3337950b7c8e0882c527263684306bba7ce4 # v0.7.1
6868
with:
6969
suffix: ${{ matrix.type }}-${{ matrix.flavor }}-${{ github.run_id }}-${{ github.run_attempt }}
7070

71-
- uses: actions/upload-artifact@65462800fd760344b1a7b4382951275a0abb4808 # v4.3.3
71+
- uses: actions/upload-artifact@0b2256b8c012f0828dc542b3febcab082c67f72b # v4.3.4
7272
if: always()
7373
with:
7474
name: playwright-report-${{ matrix.type }}-${{ matrix.flavor }}-${{ github.run_id }}-${{ github.run_attempt }}

.pre-commit-config.yaml

+2-2
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ repos:
3232
hooks:
3333
- id: fix-smartquotes
3434
- repo: https://github.com/python-jsonschema/check-jsonschema
35-
rev: 0.28.5
35+
rev: 0.29.0
3636
hooks:
3737
- id: check-jsonschema
3838
name: "Validate Zarf Configs Against Schema"
@@ -49,6 +49,6 @@ repos:
4949
hooks:
5050
- id: golangci-lint
5151
- repo: https://github.com/renovatebot/pre-commit-hooks
52-
rev: 37.413.3
52+
rev: 37.426.2
5353
hooks:
5454
- id: renovate-config-validator

README.md

+5
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,11 @@ To use IRSA make sure to NOT set the two key variables and add the appropriate r
6464
value: "arn:aws:iam::123456789:role/mattermost-role"
6565
```
6666
67+
### Monitoring
68+
69+
> [!IMPORTANT]
70+
> Mattermost supports emitting metrics to feed into Prometheus, but _only_ if you have a license. This package configures the necessary service monitor to enable metrics, but only when a license has been provided via the `MM_LICENSE` var. By default (no license), it does not provision the Service Monitor as it will show unhealthy because metrics is not enabled via the license.
71+
6772
## Flavors
6873
6974
| Flavor | Description | Example Creation |

bundle/uds-bundle.yaml

+15-4
Original file line numberDiff line numberDiff line change
@@ -21,10 +21,21 @@ packages:
2121
overrides:
2222
postgres-operator:
2323
uds-postgres-config:
24-
variables:
25-
- name: POSTGRESQL
26-
description: "Configure postgres using CRs via the uds-postgres-config chart"
27-
path: postgresql
24+
values:
25+
- path: postgresql
26+
value:
27+
enabled: true # Set to false to not create the PostgreSQL resource
28+
teamId: "uds"
29+
volume:
30+
size: "10Gi"
31+
numberOfInstances: 2
32+
users:
33+
mattermost.mattermost: [] # database owner
34+
databases:
35+
mattermost: mattermost.mattermost
36+
version: "14"
37+
ingress:
38+
- remoteNamespace: mattermost
2839

2940
- name: dev-secrets
3041
path: ../

bundle/uds-config.yaml

-14
Original file line numberDiff line numberDiff line change
@@ -2,17 +2,3 @@ variables:
22
dev-minio:
33
buckets: |
44
- name: uds-mattermost-dev
5-
postgres-operator:
6-
postgresql:
7-
enabled: true # Set to false to not create the PostgreSQL resource
8-
teamId: "uds"
9-
volume:
10-
size: "10Gi"
11-
numberOfInstances: 2
12-
users:
13-
mattermost.mattermost: [] # database owner
14-
databases:
15-
mattermost: mattermost.mattermost
16-
version: "13"
17-
ingress:
18-
remoteGenerated: Anywhere

chart/templates/uds-package.yaml

+2-1
Original file line numberDiff line numberDiff line change
@@ -45,12 +45,13 @@ spec:
4545
MM_EMAILSETTINGS_ENABLESIGNINWITHUSERNAME: "{{ .Values.sso.enable_sign_in_with_username | toString }}"
4646
{{- end }}
4747
monitor:
48+
{{- if ne .Values.mattermostLicense "" }}
4849
- selector:
4950
app.kubernetes.io/name: mattermost-enterprise-edition
5051
targetPort: 8067
5152
portName: mattermost-app-metrics
5253
description: Metrics
53-
54+
{{- end }}
5455
network:
5556
expose:
5657
- service: mattermost-enterprise-edition

chart/values.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ postgres:
2626
cluster-name: pg-cluster
2727
namespace: postgres
2828
port: 5432
29-
29+
mattermostLicense: ""
3030
sso:
3131
enabled: true
3232
# Options: "gitlab", "openid_connect"

tasks.yaml

+5-5
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,11 @@ includes:
22
- cleanup: ./tasks/cleanup.yaml
33
- dependencies: ./tasks/dependencies.yaml
44
- test: ./tasks/test.yaml
5-
- create: https://raw.githubusercontent.com/defenseunicorns/uds-common/v0.6.0/tasks/create.yaml
6-
- lint: https://raw.githubusercontent.com/defenseunicorns/uds-common/v0.6.0/tasks/lint.yaml
7-
- pull: https://raw.githubusercontent.com/defenseunicorns/uds-common/v0.6.0/tasks/pull.yaml
8-
- deploy: https://raw.githubusercontent.com/defenseunicorns/uds-common/v0.6.0/tasks/deploy.yaml
9-
- setup: https://raw.githubusercontent.com/defenseunicorns/uds-common/v0.6.0/tasks/setup.yaml
5+
- create: https://raw.githubusercontent.com/defenseunicorns/uds-common/v0.7.1/tasks/create.yaml
6+
- lint: https://raw.githubusercontent.com/defenseunicorns/uds-common/v0.7.1/tasks/lint.yaml
7+
- pull: https://raw.githubusercontent.com/defenseunicorns/uds-common/v0.7.1/tasks/pull.yaml
8+
- deploy: https://raw.githubusercontent.com/defenseunicorns/uds-common/v0.7.1/tasks/deploy.yaml
9+
- setup: https://raw.githubusercontent.com/defenseunicorns/uds-common/v0.7.1/tasks/setup.yaml
1010

1111
tasks:
1212
- name: default

tasks/publish.yaml

+4-4
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
includes:
22
- dependencies: ./dependencies.yaml
33
- test: ./test.yaml
4-
- create: https://raw.githubusercontent.com/defenseunicorns/uds-common/v0.6.0/tasks/create.yaml
5-
- deploy: https://raw.githubusercontent.com/defenseunicorns/uds-common/v0.6.0/tasks/deploy.yaml
6-
- publish: https://raw.githubusercontent.com/defenseunicorns/uds-common/v0.6.0/tasks/publish.yaml
7-
- setup: https://raw.githubusercontent.com/defenseunicorns/uds-common/v0.6.0/tasks/setup.yaml
4+
- create: https://raw.githubusercontent.com/defenseunicorns/uds-common/v0.7.1/tasks/create.yaml
5+
- deploy: https://raw.githubusercontent.com/defenseunicorns/uds-common/v0.7.1/tasks/deploy.yaml
6+
- publish: https://raw.githubusercontent.com/defenseunicorns/uds-common/v0.7.1/tasks/publish.yaml
7+
- setup: https://raw.githubusercontent.com/defenseunicorns/uds-common/v0.7.1/tasks/setup.yaml
88

99
tasks:
1010
- name: build-package

values/config-values.yaml

+1
Original file line numberDiff line numberDiff line change
@@ -6,3 +6,4 @@ postgres:
66
password: "###ZARF_VAR_DB_PASSWORD###"
77

88
subdomain: "###ZARF_VAR_SUBDOMAIN###"
9+
mattermostLicense: "###ZARF_VAR_MM_LICENSE###"

zarf.yaml

+3
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,9 @@ variables:
1919
description: "Secret Key for S3 compatible storage"
2020
- name: DB_PASSWORD
2121
description: "Database Password for Mattermost"
22+
- name: MM_LICENSE
23+
description: "License for Mattermost"
24+
default: ""
2225

2326
components:
2427
- name: mattermost

0 commit comments

Comments
 (0)