Skip to content

Commit de2ece4

Browse files
authored
updatecli: use shared updatecli policies (#66)
1 parent 6ad32f7 commit de2ece4

File tree

6 files changed

+45
-60
lines changed

6 files changed

+45
-60
lines changed

.github/update-specs.yml

Lines changed: 0 additions & 57 deletions
This file was deleted.
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
spec_path: internal/spec/v1.json
2+
signedcommit: true

.github/updatecli/values.d/scm.yml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
scm:
2+
enabled: true
3+
owner: elastic
4+
repository: ecs-logging-go-zap
5+
branch: main
6+
# begin update-compose policy values
7+
user: obltmachine
8+
9+
# end update-compose policy values
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
spec:
2+
files:
3+
- "update-compose.yaml"

.github/workflows/update-specs.yml

Lines changed: 17 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,15 +11,29 @@ permissions:
1111
contents: read
1212

1313
jobs:
14-
bump:
14+
compose:
1515
runs-on: ubuntu-latest
16+
permissions:
17+
contents: read
18+
packages: read
1619
steps:
17-
1820
- uses: actions/checkout@v4
1921

22+
- uses: docker/login-action@0d4c9c5ea7693da7b068278f7b52bda2a190a446 # v3.2.0
23+
with:
24+
registry: ghcr.io
25+
username: ${{ github.actor }}
26+
password: ${{ secrets.GITHUB_TOKEN }}
27+
28+
- uses: elastic/oblt-actions/updatecli/run@v1
29+
with:
30+
command: --experimental compose diff
31+
env:
32+
GITHUB_TOKEN: ${{ secrets.UPDATECLI_GH_TOKEN }}
33+
2034
- uses: elastic/oblt-actions/updatecli/run@v1
2135
with:
22-
command: "--experimental apply --config .github/update-specs.yml"
36+
command: --experimental compose apply
2337
env:
2438
GITHUB_TOKEN: ${{ secrets.UPDATECLI_GH_TOKEN }}
2539

update-compose.yaml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
# Config file for `updatecli compose ...`.
2+
# https://www.updatecli.io/docs/core/compose/
3+
policies:
4+
- name: Handle ecs-logging specs
5+
policy: ghcr.io/elastic/oblt-updatecli-policies/apm/ecs-logging-specs:0.3.0@sha256:6c765407764d391d6d65b04c54ba409977decc24a000d5b8d7839f58bcd07c5b
6+
values:
7+
- .github/updatecli/values.d/scm.yml
8+
- .github/updatecli/values.d/ecs-logging-specs.yml
9+
10+
- name: Update Updatecli policies
11+
policy: ghcr.io/updatecli/policies/autodiscovery/updatecli:0.4.0@sha256:254367f5b1454fd6032b88b314450cd3b6d5e8d5b6c953eb242a6464105eb869
12+
values:
13+
- .github/updatecli/values.d/scm.yml
14+
- .github/updatecli/values.d/update-compose.yml

0 commit comments

Comments
 (0)