Deploy Sterling File Gateway
export GIT_ORG=#enter name for GitHub organization
echo $GIT_ORG #To validate that GIT_ORG has the correct value.
oc login --token=#token --server=#server
The IBM Entitlement Key is required to pull IBM Sterling B2B Integrator / IBM Sterling File Gateway from the IBM Entitled Registry. To get an entitlement key,
- Log in to Access your IBM entitlement key with an IBMid and password associated with the entitled software.
- Select the View library option to verify your entitlement(s).
- Select the Get entitlement key to retrieve the key. A Secret containing the entitlement key is created in the tools namespace.
oc new-project tools
oc create secret docker-registry ibm-entitlement-key -n tools \
--docker-username=cp \
--docker-password=<`enter-your-ibm-entitlement-key`> \
--docker-server=cp.icr.io
cd ~
mkdir $GIT_ORG
cd $GIT_ORG
git clone https://github.com/$GIT_ORG/multi-tenancy-gitops.git
git clone https://github.com/$GIT_ORG/multi-tenancy-gitops-infra.git
git clone https://github.com/$GIT_ORG/multi-tenancy-gitops-services.git
git clone https://github.com/$GIT_ORG/multi-tenancy-gitops-apps.git
ls -l
Now that we've had an initial view of the GitOps repository, let's install ArgoCD to make use of it. We will install ArgoCD using the Red Hat OpenShift GitOps operator. For more information about Argo installation argocd
Screenshot of no operator
cd multi-tenancy-gitops
oc apply -f setup/ocp4x
The response confirms that the below resources has been created:
clusterrole.rbac.authorization.k8s.io/custom-argocd-cluster-argocd-application-controller created
clusterrolebinding.rbac.authorization.k8s.io/openshift-gitops-argocd-application-controller created
clusterrolebinding.rbac.authorization.k8s.io/openshift-gitops-cntk-argocd-application-controller created
subscription.operators.coreos.com/openshift-gitops-operator created
Screenshot of operator
Instead of using the default ArgoCD from the Red Hat OpenShift GitOps
operator we want to manage if via GitOps. We will delete it so we can apply our customized ArgoCD.
oc delete gitopsservice cluster -n openshift-gitops || true
oc apply -f setup/ocp4x/argocd-instance/ -n openshift-gitops
the Following command will provide ArgoCD URL
#ARGOCD username: admin
#ARGOCD URL:
oc get route -n openshift-gitops | grep openshift-gitops-cntk-server | awk '{print "https://"$2}'
#ARGOCD_PASSWORD:
oc get secret/openshift-gitops-cntk-cluster -n openshift-gitops -o json | jq -r '.data."admin.password"' | base64 -D
-
Edit the Infrastructure layer
${GITOPS_PROFILE}/1-infra/kustomization.yaml
, un-comment the following lines, commit and push the changes and synchronize theinfra
Application in the ArgoCD console.cd multi-tenancy-gitops/0-bootstrap/single-cluster/1-infra
- argocd/consolenotification.yaml - argocd/namespace-tools.yaml - argocd/namespace-sealed-secrets.yaml - argocd/serviceaccounts-tools.yaml
-
This recipe is can be implemented using a combination of storage classes. Not all combination will work, the following table lists the storage classes that we have tested to work:
Component Access Mode Azure NetApp OCS/ODF SQL RWX standard ocs-storagecluster-cephfs MQ RWX standard ocs-storagecluster-cephfs SFG RWX standard ocs-storagecluster-cephfs -
Edit the Services layer
${GITOPS_PROFILE}/2-services/kustomization.yaml
and install Sealed Secrets by uncommenting the following line, commit and push the changes and refresh theservices
Application in the ArgoCD console.- argocd/operators/ibm-catalogs.yaml - argocd/operators/ibm-foundations.yaml - argocd/instances/sealed-secrets.yaml - argocd/operators/ibm-mq-operator.yaml
💡 NOTE
Commit and Push the changes formulti-tenancy-gitops
& sync ArgoCD.- argocd/instances/ibm-foundational-services-instance.yaml
💡 NOTE
Commit and Push the changes formulti-tenancy-gitops
& sync ArgoCD. -
Clone the services repo for GitOps, open a terminal window and clone the
multi-tenancy-gitops-services
repository under your Git Organization.git clone [email protected]:${GIT_ORG}/multi-tenancy-gitops-services.git
-
Modify the B2BI pre-requisites components which includes the secrets and PVCs required for the B2BI helm chart.
-
Go to the directory:
cd multi-tenancy-gitops-services/instances/ibm-sfg-b2bi-setup
-
Generate the Sealed Secret for the credentials.
B2B_DB_SECRET=dbadmin ./b2b-db-secret-secret.sh
JMS_PASSWORD=passw0rd JMS_KEYSTORE_PASSWORD=passw0rd JMS_TRUSTSTORE_PASSWORD=passw0rd ./b2b-jms-secret.sh
B2B_SYSTEM_PASSPHRASE_SECRET=password ./b2b-system-passphrase-secret.sh
-
Generate Persistent Volume Yamls required by Sterling File Gateway (the default is set in RWX_STORAGECLASS environment variable to
managed-premium
- if you are installing on ODF, setRWX_STORAGECLASS=ocs-storagecluster-cephfs
) if your usingazure-file
, setRWX_STORAGECLASS=azure-file
- add (re-visit)
💡 NOTE
Commit and Push the changes formulti-tenancy-gitops-services
-
-
Enable SQL, MQ and prerequisites in the main
multi-tenancy-gitops
repository-
Edit the Services layer
${GITOPS_PROFILE}/2-services/kustomization.yaml
by uncommenting the following lines to install the pre-requisites for Sterling File Gateway.- argocd/instances/ibm-queuemanager-instance.yaml - argocd/instances/ibm-sfg-b2bi-setup.yaml
💡 NOTE
Push the changes & sync ArgoCD.
-
-
Edit the Services layer
${GITOPS_PROFILE}/2-services/kustomization.yaml
by uncommenting the following line to install Sterling File Gateway, commit and push the changes and synchronize theservices
Application in the ArgoCD console: -
Generate Helm Chart values.yaml for the Sterling File Gateway Helm Chart:
cd multi-tenancy-gitops-services/instances/ibm-sfg-b2bi ./ibm-sfg-b2bi-overrides-values.sh
-
Edit the Services layer
${GITOPS_PROFILE}/2-services/kustomization.yaml
by uncommenting the following line to install Sterling File Gateway, commit and push the changes and synchronize theservices
Application in the ArgoCD console:- argocd/instances/ibm-sfg-b2bi.yaml
💡 NOTE
Push the changes & sync ArgoCD this will take around 1.5 hr. -
Deploying
SFTP
service support blob storage azure click here for business processes.Steps on b2bi side needs to be filled up with David ash.
-
Edit the Services layer
${GITOPS_PROFILE}/2-services/kustomization.yaml
by uncommenting the following line to install Lightwell, commit and push the changes and synchronize theservices
Application in the ArgoCD console:- argocd/instances/lightwell-framework.yaml
Installation of Lightwell
💡 NOTE
Push the changes & sync ArgoCD.
⚠️ Warning:
If you decided to scale the pods or upgrade the verison you should do the following steps:This is to avoid going through the job again
- Step 1:
cd multi-tenancy-gitops-services/instances/ibm-sfg-b2bi
- Step 2:
- Inside
values.yaml
, find & set -
datasetup: enable: false dbCreateSchema: false
- Inside
- USE-CASES
-
Retrieve the Sterling File Gateway console URL.
oc get route -n tools ibm-sfg-b2bi-sfg-asi-internal-route-filegateway -o template --template='https://{{.spec.host}}'
-
Log in with the default credentials: username:
fg_sysadmin
password:password