Skip to content

Commit

Permalink
Add localstack as addon package (#257)
Browse files Browse the repository at this point in the history
Signed-off-by: Bradon Kanyid (rattboi) <[email protected]>
  • Loading branch information
rattboi authored May 16, 2024
1 parent 1ed5422 commit 25caace
Show file tree
Hide file tree
Showing 4 changed files with 82 additions and 0 deletions.
17 changes: 17 additions & 0 deletions examples/localstack-integration/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# Localstack Integration

Please use the below command to deploy an IDP reference implementation with an Argo application that adds Localstack, as well as integrating with Crossplane.

```bash
idpbuilder create \
--use-path-routing \
--package-dir examples/ref-implementation \
--package-dir examples/localstack-integration
```

As you see above, this add-on to `idpbuilder` has a dependency on the [reference implementation](../ref-implementation/). This command primarily does the following:

1. Installs `localstack` helmchart as an `argo` application.
2. Adds localstack crossplane ProviderConfig, targetting localstack

Once the custom package is installed, localstack can be used from the backstage template `app-with-aws-resources`, by changing the `providerConfigName` during the bucket configuration page from `default` to `localstack`.
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
apiVersion: argoproj.io/v1alpha1
kind: Application
metadata:
name: crossplane-provider-localstack
namespace: argocd
labels:
example: localstack-integration
spec:
project: default
source:
repoURL: cnoe://crossplane-provider-localstack
targetRevision: HEAD
path: "."
destination:
server: "https://kubernetes.default.svc"
namespace: crossplane-system
syncPolicy:
automated:
prune: true
selfHeal: true
syncOptions:
- CreateNamespace=true
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
apiVersion: aws.crossplane.io/v1beta1
kind: ProviderConfig
metadata:
name: localstack
annotations:
argocd.argoproj.io/sync-wave: "20"
argocd.argoproj.io/sync-options: SkipDryRunOnMissingResource=true
spec:
credentials:
source: Secret
secretRef:
namespace: crossplane-system
name: local-secret
key: creds
endpoint:
hostnameImmutable: true
url:
type: Static
static: http://localstack.localstack.svc.cluster.local:4566
24 changes: 24 additions & 0 deletions examples/localstack-integration/localstack.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
apiVersion: argoproj.io/v1alpha1
kind: Application
metadata:
name: localstack
namespace: argocd
labels:
example: localstack-integration
spec:
project: default
source:
repoURL: https://localstack.github.io/helm-charts
targetRevision: 0.6.12
chart: localstack
helm:
releaseName: localstack
destination:
server: "https://kubernetes.default.svc"
namespace: localstack
syncPolicy:
automated:
prune: true
selfHeal: true
syncOptions:
- CreateNamespace=true

0 comments on commit 25caace

Please sign in to comment.