Skip to content

Commit

Permalink
feat: cast support (#71)
Browse files Browse the repository at this point in the history
* initial official cast support

* initial official cast support

* fix: remove workflow

* ignore .envrc

* working to support jammy

* working to support jammy

* Update .cast.yml

* Update desktop.sls

* try to fix version error

* test on 3004/3005 only

* update test suite

* more fixes

* fix: set-output

* disable jammy
  • Loading branch information
ekristen authored Jan 25, 2023
1 parent e892f75 commit 203440f
Show file tree
Hide file tree
Showing 9 changed files with 127 additions and 27 deletions.
28 changes: 28 additions & 0 deletions .cast.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
release:
github:
owner: teamdfir
repo: sift-saltstack
manifest:
version: 2
name: sift
base_dir: sift
modes:
- name: server
state: sift.server
default: true
- name: desktop
state: sift.desktop
- name: packages-only
state: sift.server
deprecated: true
replacement: server
- name: complete
state: sift.desktop
deprecated: true
replacement: desktop
supported_os:
- id: ubuntu
release: 20.04
saltstack:
pillars:
sift_user_template: "{{ .User }}"
21 changes: 17 additions & 4 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ jobs:
format: "json"
- id: filter
run: |
echo ::set-output name=filtered_files::"$(jq -rMc '[.[] | select(. | contains(".sls")) | select(. | contains("init") | not) | sub("/"; "."; "g") | sub(".sls"; ""; "g")]' <<< '${{ steps.files.outputs.added_modified }}')"
echo "filtered_files=$(jq -rMc '[.[] | select(. | contains(".sls")) | select(. | contains("init") | not) | sub("/"; "."; "g") | sub(".sls"; ""; "g")]' <<< '${{ steps.files.outputs.added_modified }}')" > $GITHUB_OUTPUT
outputs:
matrix: ${{ steps.filter.outputs.filtered_files }}

Expand All @@ -31,12 +31,25 @@ jobs:

strategy:
matrix:
os: [focal]
salt: [3001, 3002, 3003]
salt: [3004, 3005]
os: [18.04, 20.04]
state: ${{ fromJson(needs.changed_states.outputs.matrix) }}
include:
- os: 18.04
code: bionic
- os: 20.04
code: focal
#Note: disabled until we support jammy
#- os: 22.04
# code: jammy
exclude:
- salt: 3004
os: 22.04
- salt: 3005
os: 18.04

container:
image: docker://teamdfir/sift-saltstack-tester:${{ matrix.os }}-${{ matrix.salt }}
image: docker://ghcr.io/teamdfir/sift-saltstack-tester:${{ matrix.salt }}-${{ matrix.code }}

steps:
- uses: actions/checkout@v2
Expand Down
18 changes: 15 additions & 3 deletions .github/workflows/weekly-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,16 +11,28 @@ jobs:

strategy:
matrix:
os: [focal]
salt: [3004]
salt: [3004, 3005]
os: [18.04, 20.04]
state:
- sift.packages.python2
- sift.packages.python3
- sift.tests.gift
- sift.config.user.pdfs
include:
- os: 18.04
code: bionic
- os: 20.04
code: focal
- os: 22.04
code: jammy
exclude:
- salt: 3004
os: 22.04
- salt: 3005
os: 18.04

container:
image: docker://teamdfir/sift-saltstack-tester:${{ matrix.os }}-${{ matrix.salt }}
image: docker://ghcr.io/teamdfir/sift-saltstack-tester:${{ matrix.salt }}-${{ matrix.code }}

steps:
- uses: actions/checkout@v2
Expand Down
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
*.key
.envrc
dist
19 changes: 0 additions & 19 deletions .travis.yml

This file was deleted.

4 changes: 4 additions & 0 deletions cosign.pub
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
-----BEGIN PUBLIC KEY-----
MFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAE7O5roaWor29sxx9Xn61+yg0C+/7u
qn3t7PG+2q6cnDt/p6ix3HKGqV+PkKXaSfjVkWIfhnGFgrlmNueUOo7kdA==
-----END PUBLIC KEY-----
51 changes: 51 additions & 0 deletions pgp.pub
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
-----BEGIN PGP PUBLIC KEY BLOCK-----

mQINBGHt5lkBEACmv5HsRIqYzOM95m75JD1AF2c44LOjQ8Lvn1CPBB7/a6R0793j
2JbqdJjSHgzY2pViaFYJAQvuyQ4SZ75YR/2xtod2Gd6HMKtTo4Yj6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AIBYhBLFYNf5ituD20taZBYv+Q20wHRgkBQJh7eZZAhsMAAoJEIv+Q20wHRgk
aJYP/17W+T8wN3R9ZFmqqzIwiNYHV5jvT7GCJ7ZvjBv2+oQJKIf4pzwFF2q4FGck
shPwUM0uMaIUGBV4vXKiHPV+ibF+J4XPgL1OE+wxUW35PSCVs4ApKJQh72LmJkNn
oW8GSReipCoxHoFjuPnb13dvwipte/hwzB1Ec89qs3UCNhcPqZ/d4L3toGISCraZ
7xQ1hdsqGV3mLKtnH7EeDBVqzErzxQ+MjcCeB+YM97nVNFFsqwwBtYZU8jQQ7TrW
/VHHe9FrspfZ3/W4oBL3VSnQOqygzNE4qrXJsukXS8qh/KoOifJzgTgxBqcBLhtZ
re25KhHKZevLSmOjqbVLxE5cCKjzpXmRGEH7ymeRvV8ILlydZ4z0P7nzA7E5ayNS
/ji0RgI45cPyMtTT6tcbvpzfMS+xixGqpZuAe40Ek+gEf17yrgRHZtyYtnhfRwJG
FRiHrIDTAl4ZpAhtlbiuBnSWLdzZM4cR6y20mHTBVsCzdrzOt6rZsIxJDCTIoakL
r7d/S28e+N+WP6R/wFKzWsSai1vovN6tgsndTdaFhxXCW5HH5PTRAXkXnOKazoDr
tPHNWvn3AdNZ3hx/Jf0qXeA6XRSiFARoBlPUFw++8LZDicBX7lyALeYS0q+7QViq
qOE00Xtda0Yt0sfgGb1oFu0c3Igow3MLASHks0yTkwy6yhDb
=j3WZ
-----END PGP PUBLIC KEY BLOCK-----
4 changes: 3 additions & 1 deletion sift/desktop.sls
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,9 @@ include:
sift-desktop-version-file:
file.managed:
- name: /etc/sift-version
- source: salt://VERSION
- source:
- salt://sift/VERSION # note: this is here for when sift is a submoduled to salt://sift/
- salt://VERSION
- user: root
- group: root
- require:
Expand Down
6 changes: 6 additions & 0 deletions sift/packages/powershell_jammy.sls
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{%- set base_url = "https://github.com/Powershell/Powershell/releases/download/v" -%}
{%- set version = "6.0.0-alpha.13" -%}
{%- set filename = "powershell_6.0.0-alpha.13-1ubuntu1." ~ grains['osrelease'] ~ ".1_amd64.deb" -%}

sift-powershell:
test.nop

0 comments on commit 203440f

Please sign in to comment.