Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/feature/pulumi' into feature/minio
Browse files Browse the repository at this point in the history
  • Loading branch information
LuisDuarte1 committed Jul 25, 2024
2 parents 08575bb + f1aa9f7 commit 171c861
Show file tree
Hide file tree
Showing 47 changed files with 1,710 additions and 756 deletions.
46 changes: 46 additions & 0 deletions .github/actions/prepare-pulumi-project/action.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
name: "Prepare Pulumi project"
description: "Installs dependencies and clones the project"
inputs:
node-version:
description: "Node version"
required: false
default: "22"
crd2pulumi-version:
description: "crd2pulumi version"
required: false
default: "v1.4.0"
yq-version:
description: "yq version"
required: false
default: "v4.40.3"
runs:
using: composite
steps:

- name: Install yq
shell: sh
run: sudo curl -L https://github.com/mikefarah/yq/releases/download/${{ inputs.yq-version }}/yq_linux_amd64 -o /usr/bin/yq && sudo chmod +x /usr/bin/yq

- name: Install crd2pulumi
shell: sh
run: |
mkdir -p ./bin/crd2pulumi
cd ./bin/crd2pulumi
echo "crd2pulumi" > files.txt
curl -L https://github.com/pulumi/crd2pulumi/releases/download/${{ inputs.crd2pulumi-version }}/crd2pulumi-${{ inputs.crd2pulumi-version }}-linux-amd64.tar.gz | tar -T files.txt -xvz
sudo mv crd2pulumi /usr/bin/crd2pulumi
sudo chmod +x /usr/bin/crd2pulumi
- uses: pnpm/action-setup@v4
with:
package_json_file: services/pulumi/package.json

- uses: actions/setup-node@v4
with:
node-version: ${{ inputs.node-version }}
cache: "pnpm"
cache-dependency-path: services/pulumi/pnpm-lock.yaml

- name: Sync CRDs
shell: sh
run: ./services/pulumi/sync-crds.sh
30 changes: 30 additions & 0 deletions .github/workflows/pulumi-linter.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
name: pulumi-lint

on:
pull_request:
branches: [ "main" ]
paths: [ "services/pulumi/**" ]
push:
branches: [ "main" ]
paths: [ "services/pulumi/**" ]

jobs:
format:
name: Prettier
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: ./.github/actions/prepare-pulumi-project
- name: Run prettier
working-directory: services/pulumi/niployments
run: pnpm run prettier

lint:
name: ESLint
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: ./.github/actions/prepare-pulumi-project
- name: Run ESLint
working-directory: services/pulumi/niployments
run: pnpm run lint
5 changes: 0 additions & 5 deletions services/ni/nijobs/00-namespace.yaml

This file was deleted.

68 changes: 0 additions & 68 deletions services/ni/nijobs/01-secrets.yaml

This file was deleted.

90 changes: 0 additions & 90 deletions services/ni/nijobs/02-deployments.yaml

This file was deleted.

36 changes: 0 additions & 36 deletions services/ni/nijobs/03-services.yaml

This file was deleted.

55 changes: 0 additions & 55 deletions services/ni/nijobs/04-ingress-routes.yaml

This file was deleted.

4 changes: 2 additions & 2 deletions services/pulumi/.gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
/bin/
/node_modules/
bin/
node_modules/
/crds/
6 changes: 0 additions & 6 deletions services/pulumi/Pulumi.prod.yaml

This file was deleted.

3 changes: 3 additions & 0 deletions services/pulumi/crds.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ repositories:
# mongodb official charts are not needed while temporary fix is in use
# - name: mongodb
# url: https://mongodb.github.io/helm-charts
- name: mittwald
url: https://helm.mittwald.de
- name: longhorn
url: https://charts.longhorn.io
- name: traefik
Expand Down Expand Up @@ -41,6 +43,7 @@ manifests:
name: cloudnative-pg/cloudnative-pg
url: https://raw.githubusercontent.com/cloudnative-pg/cloudnative-pg/release-1.22/releases/cnpg-1.22.2.yaml
# image-registry (harbor) - no CRDs
# replicator - no CRDs
# storage/longhorn
- type: template
chart: longhorn/longhorn
Expand Down
5 changes: 0 additions & 5 deletions services/pulumi/index.ts

This file was deleted.

7 changes: 7 additions & 0 deletions services/pulumi/niployments/.prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# Pnpm files
/node_modules/
/bin/
package.json

# Assets
/assets/
3 changes: 3 additions & 0 deletions services/pulumi/niployments/.prettierrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"tabWidth": 2
}
6 changes: 6 additions & 0 deletions services/pulumi/niployments/Pulumi.prod.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
encryptionsalt: v1:upriG3hjats=:v1:Mjju6ZYDjjKKyVPn:Bn6nuCMHoUCltZWaXycxDl5bvv7ndA==
config:
niployments:mongodb/admin-password:
secure: v1:GXCb2z0V4Az3053O:y6EgjlKVYr6BWebVazmAmdC/YCI=
niployments:mongodb/nimentas-password:
secure: v1:HxF47P+9RXfi4nfc:47vWUGoYJgjmqxaWwT2M8SSCgI0=
File renamed without changes.
File renamed without changes.
Loading

0 comments on commit 171c861

Please sign in to comment.