Skip to content

Commit

Permalink
refactor
Browse files Browse the repository at this point in the history
  • Loading branch information
ranchodeluxe committed Jun 15, 2024
1 parent b4763ae commit fdc6439
Show file tree
Hide file tree
Showing 17 changed files with 47 additions and 18,535 deletions.
15 changes: 6 additions & 9 deletions .github/workflows/helm-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -124,8 +124,7 @@ jobs:
echo "The previous step failed or timed out. Running cleanup logic..."
helm uninstall $RELEASE_NAME
# need to ticket in crunchy b/c depedencies are not uninstalling via above uninstall
kubectl delete cm,secrets,statefulset,replicaset,deploy,pods,services,endpoints,sa,deployments --all --namespace=$RELEASE_NAME
kubectl delete ns/RELEASE_NAME
# force GH action to show failed result
exit 128
Expand Down Expand Up @@ -159,18 +158,17 @@ jobs:
head -n 5 .github/workflows/tests/test_stac.py
pytest .github/workflows/tests/test_stac.py
sed -i "s|raster_endpoint\=.*$|raster_endpoint\='$PUBLICIP/raster$RELEASE_NAME'|g" .github/workflows/tests/test_raster.py
head -n 5 .github/workflows/tests/test_raster.py
pytest .github/workflows/tests/test_raster.py
#sed -i "s|raster_endpoint\=.*$|raster_endpoint\='$PUBLICIP/raster$RELEASE_NAME'|g" .github/workflows/tests/test_raster.py
#head -n 5 .github/workflows/tests/test_raster.py
#pytest .github/workflows/tests/test_raster.py
- name: cleanup if tests faile
if: steps.testrunner.outcome == 'failure'
run: |
echo "The previous step failed or timed out. Running cleanup logic..."
helm uninstall $RELEASE_NAME
# need to ticket in crunchy b/c depedencies are not uninstalling via above uninstall
kubectl delete cm,secrets,statefulset,replicaset,deploy,pods,services,endpoints,sa,deployments --all --namespace=$RELEASE_NAME
kubectl delete ns/RELEASE_NAME
# force GH action to show failed result
exit 128
Expand All @@ -179,5 +177,4 @@ jobs:
run: |
helm uninstall $RELEASE_NAME
# need to ticket in crunchy b/c depedencies are not uninstalling via above uninstall
kubectl delete cm,secrets,statefulset,replicaset,deploy,pods,services,endpoints,sa,deployments --all --namespace=$RELEASE_NAME
kubectl delete ns/RELEASE_NAME
61 changes: 37 additions & 24 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,37 +37,50 @@ If you don't have a k8s cluster set up on AWS or GCP then follow an IaC guide be

<a name="helminstall"/>

## Helm Installation
## Helm Installation

Once you have a k8s cluster set up you can `helm install` eoAPI as follows:
Once you have a k8s cluster set up you can `helm install` eoAPI with the following steps:

1. `helm install` from https://devseed.com/eoapi-k8s/:
0. `eoapi-k8s` depends on the [Crunchydata Postgresql Operator](https://access.crunchydata.com/documentation/postgres-operator/latest/installation/helm). Install that first:

```python
$ helm install --set disable_check_for_upgrades=true pgo oci://registry.developers.crunchydata.com/crunchydata/pgo
```


1. Add the eoapi repo from https://devseed.com/eoapi-k8s/:

```python
# add the eoapi helm repo locally
$ helm repo add eoapi https://devseed.com/eoapi-k8s/

# list out the eoapi chart versions
$ helm search repo eoapi --versions
NAME CHART VERSION APP VERSION DESCRIPTION
eoapi/eoapi 0.1.1 0.1.0 Create a full Earth Observation API with Metada...
eoapi/eoapi 0.1.2 0.1.0 Create a full Earth Observation API with Metada...

# optionally override keys/values in the default `values.yaml` with a custom `config.yaml` like below:
$ cat config.yaml
vector:
enable: false
pgstacBootstrap:
settings:
envVars:
LOAD_FIXTURES: "0"
RUN_FOREVER: "1"

# then run `helm install` with those overrides
$ helm install -n eoapi --create-namespace eoapi eoapi/eoapi --version 0.1.2 -f config.yaml
```

2. or `helm install` from this repo's `helm-chart/` folder:
2. List out the eoapi chart versions

```python
$ helm search repo eoapi --versions
NAME CHART VERSION APP VERSION DESCRIPTION
eoapi/eoapi 0.2.14 0.3.1 Create a full Earth Observation API with Metada...
eoapi/eoapi 0.1.13 0.2.11 Create a full Earth Observation API with Metada...
```
3. Optionally override keys/values in the default `values.yaml` with a custom `config.yaml` like below:

```python
$ cat config.yaml
vector:
enable: false
pgstacBootstrap:
settings:
envVars:
LOAD_FIXTURES: "0"
RUN_FOREVER: "1"
```
4. Then `helm install` with those `config.yaml` values:

```python
$ helm install -n eoapi --create-namespace eoapi eoapi/eoapi --version 0.1.2 -f config.yaml
```

5. or check out this repo and `helm install` from this repo's `helm-chart/` folder:

```python
######################################################
Expand Down
3 changes: 0 additions & 3 deletions helm-chart/eoapi/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,6 @@ version: "0.3.0"
appVersion: "0.3.2"

dependencies:
- name: pgo
version: 5.5.2
respository: "file://charts/pgo"
- name: postgrescluster
version: 5.5.2
respository: "file://charts/postgrescluster"
3 changes: 0 additions & 3 deletions helm-chart/eoapi/charts/pgo/.gitattributes

This file was deleted.

1 change: 0 additions & 1 deletion helm-chart/eoapi/charts/pgo/.helmignore

This file was deleted.

8 changes: 0 additions & 8 deletions helm-chart/eoapi/charts/pgo/Chart.yaml

This file was deleted.

Loading

0 comments on commit fdc6439

Please sign in to comment.