From bb6cf483441e7ddfc70d442bedd9c5a57fe7f28b Mon Sep 17 00:00:00 2001 From: Nick Phura Date: Tue, 19 Mar 2024 15:45:59 -0700 Subject: [PATCH] Remove old n8n and geoserver code --- .docker/nginx/n8n/Dockerfile | 11 - .docker/nginx/n8n/dev.conf | 19 - .gitignore | 5 - Containers/geoserver/README.md | 157 - .../kartoza-geoserver/geoserver.bc.yaml | 129 - .../kartoza-geoserver/geoserver.cm.yaml | 108 - .../kartoza-geoserver/geoserver.dc.yaml | 211 - .../kartoza-geoserver/geoserver.secret.yaml | 9 - Containers/workflow/Dockerfile | 5 - Containers/workflow/README.md | 42 - Containers/workflow/openshift/n8n.bc.yaml | 74 - Containers/workflow/openshift/n8n.dc.yaml | 579 - docker-compose.yml | 17 - env_config/env.docker | 12 - n8n/.docker/n8n/Dockerfile.export | 21 - n8n/.docker/n8n/Dockerfile.setup | 21 - n8n/README.md | 20 - n8n/package-lock.json | 9340 ----------------- n8n/package.json | 33 - 19 files changed, 10813 deletions(-) delete mode 100644 .docker/nginx/n8n/Dockerfile delete mode 100644 .docker/nginx/n8n/dev.conf delete mode 100644 Containers/geoserver/README.md delete mode 100644 Containers/geoserver/kartoza-geoserver/geoserver.bc.yaml delete mode 100644 Containers/geoserver/kartoza-geoserver/geoserver.cm.yaml delete mode 100644 Containers/geoserver/kartoza-geoserver/geoserver.dc.yaml delete mode 100644 Containers/geoserver/kartoza-geoserver/geoserver.secret.yaml delete mode 100644 Containers/workflow/Dockerfile delete mode 100644 Containers/workflow/README.md delete mode 100644 Containers/workflow/openshift/n8n.bc.yaml delete mode 100644 Containers/workflow/openshift/n8n.dc.yaml delete mode 100644 n8n/.docker/n8n/Dockerfile.export delete mode 100644 n8n/.docker/n8n/Dockerfile.setup delete mode 100644 n8n/README.md delete mode 100644 n8n/package-lock.json delete mode 100644 n8n/package.json diff --git a/.docker/nginx/n8n/Dockerfile b/.docker/nginx/n8n/Dockerfile deleted file mode 100644 index b25dfbc54..000000000 --- a/.docker/nginx/n8n/Dockerfile +++ /dev/null @@ -1,11 +0,0 @@ -FROM nginx:stable-alpine - -RUN mkdir -p /usr/app - -WORKDIR /usr/app - -# remove any existing conf file -RUN rm /etc/nginx/conf.d/default.conf - -# copy our nginx conf file -COPY /dev.conf /etc/nginx/conf.d diff --git a/.docker/nginx/n8n/dev.conf b/.docker/nginx/n8n/dev.conf deleted file mode 100644 index 732cb31b9..000000000 --- a/.docker/nginx/n8n/dev.conf +++ /dev/null @@ -1,19 +0,0 @@ -server { - listen 5100; - - location / { - proxy_pass http://n8n:5678; - proxy_redirect default; - proxy_set_header Host $host; - proxy_set_header X-Real-IP $remote_addr; - proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; - proxy_set_header X-Forwarded-Host $server_name; - - if ($request_method = 'OPTIONS') { - add_header "Access-Control-Allow-Origin" "*"; - add_header "Access-Control-Allow-Methods" "GET, POST, OPTIONS, HEAD"; - add_header "Access-Control-Allow-Headers" "Authorization, Origin, X-Requested-With, Content-Type, Accept, sessionid"; - return 204; - } - } -} diff --git a/.gitignore b/.gitignore index 72cc6bde0..f72d5ede9 100644 --- a/.gitignore +++ b/.gitignore @@ -108,8 +108,3 @@ dist # Apple macOS folder attributes file **/.DS_Store - -# n8N - ignore root level temp config folder -.n8n -n8n/.n8n -n8n/.config diff --git a/Containers/geoserver/README.md b/Containers/geoserver/README.md deleted file mode 100644 index 0c1d50135..000000000 --- a/Containers/geoserver/README.md +++ /dev/null @@ -1,157 +0,0 @@ -# GeoServer - -Dockerized GeoServer comes from https://github.com/NickPhura/docker-geoserver which is a modified fork of https://github.com/kartoza/docker-geoserver - -- Modifications were needed to make the original kartoza docker setup compatible with OpenShift, specifically due to how OpenShift controls users/permissions within its pods (containers). - -The GeoServer project, and its documentation, can be found here: https://geoserver.org/ - -Description of the files: - -`./kartoza-geoserver`: contains OpenShift templates for building a GeoServer build config and image stream. -`./kartoza-geoserver/geoserver.cm.yaml`: an OpenShift config map template. -`./kartoza-geoserver/geoserver.bc.yaml`: an OpenShift build config template. -`./kartoza-geoserver/geoserver.dc.yaml`: an OpenShift deployment config template. - -# Installation - -The base geoserver image can be built in OpenShift from the steps below. - -See steps `1` and `2` for initial installation. -See step `3` for updates to an existing installation. - -# 1. Create Base GeoServer Image In OpenShift - -**_Note: All of these steps should be done in the OpenShift Tools Project (ie: `a0ec71-tools`)_** - -## 1. Upload Templates - -### 1.1 Upload ConfigMap (`geoserver.cm.yaml`) Template - -- Ensure the environment values in `geoserver.cm.yaml` specify the correct values. - - These can be easily changed after the template is uploaded, but should be persisted in `geoserver.cm.yaml` for backup. -- Follow the steps in [How to Upload a Template](#how-to-upload-a-template). -- This will automatically create a new ConfigMap (no template processing needed) - -_Note: This config map is simply a placeholder for the env vars. To make them accessible by the build config, you still need to include an entry in the `env` section of `geoserver.bc.yaml` for each variable. Similar to how secrets are added as variables to build/deployment configs._ - -### 1.2. Upload BuildConfig (`geoserver.bc.yaml`) Template - -- Ensure the environment values in `geoserver.bc.yaml` specify the correct values. - - In particular, the variables related to the repo url/ref, context/dockerfile paths, and version. -- Follow the steps in [How to Upload a Template](#how-to-upload-a-template). - -### 1.3. Upload Secret (`geoserver.secret.yaml`) Template - -- Follow the steps in [How to Upload a Template](#how-to-upload-a-template). - -_Note: This template includes no values for the secret keys (as they cannot be saved in the repo). See [Update Secret Values](#update-secret-values) for modifying the secret._ - -## 2. Update Secret Values - -- Under `Workloads -> Secrets -> ` - - Edit the secret, and enter a value for the secrets. - -## 3. Process The BuildConfig Template - -- See [Process A Template](#process-a-template) - -### 4. Run The BuildConfig - -### 4.1 Modify The BuildConfig (If Temporary Changes Are Needed) - -- You can still make modifications to the BuildConfig at this stage. - - Click on your build config (under `Builds -> BuildConfigs`) - - Under the `Actions` drop down, click `Edit BuildConfig`. - - You can edit it via a Form view or YAML view. - -_Note: Any modifications that are not intended to be temporary should be persisted in `geoserver.cm.yaml` for backup._ - -### 4.2. Run The BuildConfig - -- From the build config page, under the `Actions` drop down, click `Start Build`. - - This will generate a new item under `Builds -> Builds`, which will in turn create a new item under the `Builds -> ImageStreams`. - - Keep an eye on the build logs to ensure it builds correctly. This may take several minutes. - - If successful, it will finish with a log message like: `Successfully pushed image-registry.openshift-image-registry ...` - -# 2. Deploy GeoServer Image In OpenShift - -**_Note: All of these steps should be done in the OpenShift Dev/Test/Prod Project (ie: a0ec71-dev)_** - -## 1. Upload DeploymentConfig (`geoserver.dc.yaml`) Template - -- Ensure the environment values in `geoserver.dc.yaml` specify the correct values. -- Follow the steps in [How to Upload a Template](#how-to-upload-a-template). - -## 2. Process The DeploymentConfig Template - -- See [Process A Template](#process-a-template) - -## 3. Run the DeploymentConfig - -- From the build config page, under the `Actions` drop down, click `Start Build`. - - This will generate a new item under `Builds -> Builds`, which will in turn create a new item under the `Builds -> ImageStreams`. - - Keep an eye on the build logs to ensure it builds correctly. This may take several minutes. - - If successful, it will finish with a log message like: `Successfully pushed image-registry.openshift-image-registry ...` - -# 3. Updating The Base Image In OpenShift And Re-Deploying - -If there is a newer version of the geoserver project available, follow the below steps to update the base image and deploy the new version. - -## 1. Generated An Updated Image - -In the OpenShift Tools Project (ie: a0ec71-tools): - -- See [Run the BuildConfig](#42-Run-The-BuildConfig) -- This will generate a new `Build` which if successful will update the `ImageStream` from the latest geoserver project code - -## 2. Re-Tag the ImageStream - -In the OpenShift Dev/Test/Prod Project (ie: a0ec71-dev): - -- In a compatible cli, where you have logged into the OpenShift CLI, execute the following command: - - ``` - oc tag a0ec71-tools/kartoza-geoserver:latest a0ec71-dev/kartoza-geoserver:latest - ``` - -This will update the ImageStream in the `` environment to point to the latest version of the base ImageStream in the `tools` environment. - -- Confirm by checking that the `sha` number matches in both ImageStreams. - -This will also trigger an automatic re-deploy of the geoserver deployment config, which should roll out a new pod using the latest ImageStream tag. - -# How To Upload A Template - -- In the top right corner of the OpenShift UI, there is a circular plus button `(+)`. -- Click it and paste the template into the upload window. -- If there are any glaring errors, it will prompt you to address them. -- Click `Create`. - -# Find An Existing Template - -- Templates can be found via the `Home -> API Explorer` page. -- Filter `All groups` to `template.openshift.io`. -- Click `Template` from the list of results`. -- Click `Instances` from the subsequent page. -- From here you can view, edit, delete the template uploaded in the previous step. - -# Process A Template - -- In a compatible cli, where you have logged into the OpenShift CLI, execute the following command: - - ``` - oc process