diff --git a/Dockerfile b/Dockerfile index b399e6e8..df479209 100644 --- a/Dockerfile +++ b/Dockerfile @@ -9,7 +9,7 @@ RUN apt-get update && apt-get upgrade -y \ && update-alternatives --install /usr/bin/pip pip /usr/bin/pip3 1 FROM baseline as tool_builder -ARG kubectl_version=1.28.7 +ARG kubectl_version=1.29.7 WORKDIR /build diff --git a/docs/CONFIG-VARS.md b/docs/CONFIG-VARS.md index 32374f66..59ea5a2d 100644 --- a/docs/CONFIG-VARS.md +++ b/docs/CONFIG-VARS.md @@ -248,6 +248,12 @@ V4_CFG_POSTGRES_SERVERS: ``` Several SAS Viya platform offerings require a second internal Postgres instance referred to as SAS Common Data Store or CDS PostgreSQL. See details [here](https://documentation.sas.com/?cdcId=itopscdc&cdcVersion=default&docsetId=dplyml0phy0dkr&docsetTarget=n08u2yg8tdkb4jn18u8zsi6yfv3d.htm#p0wkxxi9s38zbzn19ukjjaxsc0kl). The list of software offerings that include CDS PostgreSQL is located at [SAS Common Data Store Requirements (for SAS Planning and Retail Offerings)](https://documentation.sas.com/?cdcId=sasadmincdc&cdcVersion=default&docsetId=itopssr&docsetTarget=p05lfgkwib3zxbn1t6nyihexp12n.htm#n03wzanutmc6gon1val5fykas9aa) in System Requirements for the SAS Viya platform. To deploy and configure a CDS PostgreSQL instance in addition to the default internal platform Postgres instance, specify "cds-postgres" for your second Postgres instance as shown in the example below: +**Note**: Starting with 2024.06, the SharedServices database is not created automatically during the initial deployment of the SAS Viya platform. Instead, you must manually create it before you start the SAS Viya platform deployment. +Please refer to [this section](https://github.com/sassoftware/viya4-deployment/blob/main/docs/user/PostgreSQL.md##202406-sharedservices-database-updated-behavior +) in the PostgreSQL.md documentation + + + ```bash V4_CFG_POSTGRES_SERVERS: default: @@ -413,7 +419,7 @@ The EBS CSI driver is currently only used for kubernetes v1.23 or later AWS EKS | INGRESS_NGINX_NAMESPACE | NGINX Ingress Helm installation namespace | string | ingress-nginx | false | | baseline | | INGRESS_NGINX_CHART_URL | NGINX Ingress Helm chart URL | string | See [this document](https://kubernetes.github.io/ingress-nginx) for more information. | false | | baseline | | INGRESS_NGINX_CHART_NAME | NGINX Ingress Helm chart name | string | ingress-nginx | false | | baseline | -| INGRESS_NGINX_CHART_VERSION | NGINX Ingress Helm chart version | string | "" | false | If left as "" (empty string), version `4.9.1` is used for Kubernetes clusters whose version is >= 1.25.X, and for Kubernetes clusters whose version is <= 1.24.X please set this variable to avoid errors. See [Supported Versions table](https://github.com/kubernetes/ingress-nginx/?tab=readme-ov-file#supported-versions-table) for the supported versions list. | baseline | +| INGRESS_NGINX_CHART_VERSION | NGINX Ingress Helm chart version | string | "" | false | If left as "" (empty string), version `4.11.1` is used for Kubernetes clusters whose version is >= 1.26.X, and for Kubernetes clusters whose version is <= 1.25.X please set this variable to avoid errors. See [Supported Versions table](https://github.com/kubernetes/ingress-nginx/?tab=readme-ov-file#supported-versions-table) for the supported versions list. | baseline | | INGRESS_NGINX_CONFIG | NGINX Ingress Helm values | string | See [this file](../roles/baseline/defaults/main.yml) for more information. Altering this value will affect the cluster. | false | | baseline | ### Metrics Server diff --git a/docs/Troubleshooting.md b/docs/Troubleshooting.md index e03995cf..49584062 100644 --- a/docs/Troubleshooting.md +++ b/docs/Troubleshooting.md @@ -12,6 +12,7 @@ - [Deploying with the SAS Orchestration Tool using a Provider Based Kubernetes Configuration File](#deploying-with-the-sas-orchestration-tool-using-a-provider-based-kubernetes-configuration-file) - [Applying a New License for your SAS Viya Platform Deployment](#applying-a-new-license-for-your-sas-viya-platform-deployment) - [Tagging the AWS EC2 Load Balancers](#tagging-the-aws-ec2-load-balancers) + - [Deploying with cadence versions > 2024.06 without creating the external PostgreSQL SharedServices database](#deploying-with-cadence-versions--202406-without-creating-the-external-postgresql-sharedservices-database) ## Debug Mode Debug mode can be enabled by adding "-vvv" to the end of the docker or ansible commands @@ -400,3 +401,51 @@ Based on this [Network Load Balancing documentation](https://docs.aws.amazon.com terminationGracePeriodSeconds: 600 ``` 3. When the `baseline,install` ansible tasks are run and `ingress-nginx` is installed, the EC2 Load Balancer that gets provisioned by AWS will have those tags you specified. + + +## Deploying with cadence versions > 2024.06 without creating the external PostgreSQL SharedServices database + +### Symptom + +While deploying with a cadence version >= 2024.06 AND: + +* you are targeting an IaC-provisioned cluster with an External PostgreSQL Database Server +* you didn't create the SharedServices database prior to running viya4-deployment + +most pods will fail to initialize. The following error message can be found in the sas-data-server-operator pod: + +```bash +$ kubectl logs deployment/sas-data-server-operator +{ + "level":"error", + "source":"sas-data-server-operator-65c874585-xwzgr", + "messageParameters":{ + "p1":"failed to connect to `host=example-default-flexpsql.postgres.database.azure.com user=pgadmin database=SharedServices`: server error (FATAL: database \"SharedServices\" does not exist (SQLSTATE 3D000))" + }, + "messageKey":"failed to initialize database, got error %v", + "message":"failed to initialize database, got error %v" +} +{ + "level":"error", + "source":"sas-data-server-operator-65c874585-xwzgr", + "messageKey":"Reconciler error", + "properties":{ + "error":"database server is external and cannot connect to the SAS database", + "caller":"logr/logr.go:49" + }, + "attributes":{ + "DataServer":{ + "name":"sas-platform-postgres", + "namespace":"deploy" + }, + }, + "message":"Reconciler error" +} + +``` + +### Solution + +Due to changes in the sas-data-server-operator, the SharedServices database is not created automatically during the initial deployment of the SAS Viya platform. Instead, you must manually create it before you start the SAS Viya platform deployment + +For more information, please refer to the [External Postgres Requirements](https://documentation.sas.com/?cdcId=itopscdc&cdcVersion=default&docsetId=itopssr&docsetTarget=p05lfgkwib3zxbn1t6nyihexp12n.htm#p1wq8ouke3c6ixn1la636df9oa1u) documentation. diff --git a/docs/user/Dependencies.md b/docs/user/Dependencies.md index 211ef930..0ca950b8 100644 --- a/docs/user/Dependencies.md +++ b/docs/user/Dependencies.md @@ -13,7 +13,7 @@ The following list details our dependencies and versions (~ indicates multiple p | ~ | docker | >=25.0.3 | | ~ | git | any | | ~ | rsync | any | -| ~ | kubectl | 1.26 - 1.28 | +| ~ | kubectl | 1.28 - 1.30 | | ~ | Helm | 3.14.2 | | pip3 | ansible | 9.2.0 | | pip3 | openshift | 0.13.2 | @@ -49,7 +49,7 @@ As described in the [Docker Installation](./DockerUsage.md) section add addition ```bash # Override kubectl version docker build \ - --build-arg kubectl_version=1.28.7 \ + --build-arg kubectl_version=1.29.7 \ -t viya4-deployment . ``` diff --git a/docs/user/PostgreSQL.md b/docs/user/PostgreSQL.md index 9c2f1279..f91f6ce5 100644 --- a/docs/user/PostgreSQL.md +++ b/docs/user/PostgreSQL.md @@ -5,6 +5,7 @@ * [Post Data Transfer Steps for viya4-deployment](#post-data-transfer-steps-for-viya4-deployment) * [Crunchy Data 5](#crunchy-data-5) * [Crunchy Data 4](#crunchy-data-4) + * [2024.06 SharedServices Database Updated Behavior](#202406-sharedservices-database-updated-behavior) ## Use IAC To Create an External PostgreSQL Database Cluster @@ -55,3 +56,11 @@ The final step in the [PostgreSQL Data Transfer Guide](https://documentation.sas 4. Going back to the [PostgreSQL Data Transfer Guide](https://documentation.sas.com/?cdcId=itopscdc&cdcVersion=default&docsetId=pgdatamig&docsetTarget=titlepage.htm) under "Post-transfer Steps for Crunchy Data 4" perform Step 8 and start the operator if your deployment is managed by the SAS Deployment Operator (if `V4_DEPLOYMENT_OPERATOR_ENABLED` was set to true in your `ansible-vars.yaml` file). Otherwise, skip this step. 5. Run the ansible-playbook again with the `viya,install` tags. This updates the `kustomization.yaml` by removing entries related to Crunchy Data 4 and adding entries for your external PostgreSQL cluster. The manifest will be rebuilt and reapplied to the cluster. This replaces step 9 from the "Post-transfer Steps for Crunchy Data 4" documentation. 6. Return to the [PostgreSQL Data Transfer Guide](https://documentation.sas.com/?cdcId=itopscdc&cdcVersion=default&docsetId=pgdatamig&docsetTarget=titlepage.htm) under "Post-transfer Steps for Crunchy Data 4". Perform Steps 10 and the remainder of the steps to complete the data transfer. + + +## 2024.06 SharedServices Database Updated Behavior +Due to changes in the sas-data-server-operator, the SharedServices database is not created automatically during the initial deployment of the SAS Viya platform. Instead, you must manually create it before you start the SAS Viya platform deployment + +Deployments performed on cadence versions before 2024.06 will not be impacted. + +For more information, please refer to the [External Postgres Requirements](https://documentation.sas.com/?cdcId=itopscdc&cdcVersion=default&docsetId=itopssr&docsetTarget=p05lfgkwib3zxbn1t6nyihexp12n.htm#p1wq8ouke3c6ixn1la636df9oa1u) documentation. \ No newline at end of file diff --git a/roles/baseline/defaults/main.yml b/roles/baseline/defaults/main.yml index 36feddf0..02f5d6ac 100644 --- a/roles/baseline/defaults/main.yml +++ b/roles/baseline/defaults/main.yml @@ -33,9 +33,9 @@ METRICS_SERVER_CONFIG: ## Ingress-nginx - Defaults ingressVersions: k8sMinorVersion: - value: 25 + value: 26 api: - chartVersion: 4.9.1 + chartVersion: 4.11.1 ## Ingress-nginx - Ingress ## diff --git a/roles/vdm/templates/transformers/dataserver-transformer.yaml b/roles/vdm/templates/transformers/dataserver-transformer.yaml index b34def34..f1cd6df6 100644 --- a/roles/vdm/templates/transformers/dataserver-transformer.yaml +++ b/roles/vdm/templates/transformers/dataserver-transformer.yaml @@ -5,6 +5,10 @@ kind: PatchTransformer metadata: name: {{ dataserver_name }}-dataserver-transformer patch: |- + - op: add + path: "/metadata/annotations/sas.com~1database-server-location" + value: external # Identifies that database server is external + - op: replace path: /spec/databases/0/name value: {{ db }}