PromucFlow_constructor/deploy/k8s
2021-05-13 14:29:43 +05:30
..
scripts Disable cs url as an environment config (#4465) 2021-05-13 14:29:43 +05:30
templates Adding script for k8s deployment (#1359) 2020-10-30 09:51:05 +05:30
install.k8s.sh Fix password generation and OS case problems in install scripts (#4184) 2021-04-27 20:43:22 +05:30
README.md Adding script for k8s deployment (#1359) 2020-10-30 09:51:05 +05:30

description
Appsmith stands for speed and getting started with Appsmith is just as fast.

Getting started

You can begin using appsmith via our cloud instance or by deploying appsmith yourself

Appsmith Cloud

The fastest way to get started with appsmith is using our cloud-hosted version. It's as easy as

  1. Create an Account
  2. Start Building

Prerequisites

Kubernetes

Appsmith also comes with an installation script that will help you configure Appsmith & deploy your app on Kubernetes cluster.

  1. Fetch the install.k8s.sh script on the system you want to deploy appsmith
# Downloads install.sh
curl -O https://raw.githubusercontent.com/appsmithorg/appsmith/master/deploy/k8s/install.k8s.sh
  1. Make the script executable
chmod +x install.k8s.sh
  1. Run the script.
./install.k8s.sh
  1. Check if all the pods are running correctly.
kubectl get pods

#Output should look like this
NAME                                        READY   STATUS      RESTARTS    AGE
appsmith-editor-cbf5956c4-2zxlz             1/1     Running     0           4m26s
appsmith-internal-server-d5d555dbc-qddmb.   1/1     Running     2           4m22s
imago-1602817200-g28b2                      1/1     Running     0           4m39s
mongo-statefulset-0                         1/1     Running     0           4m13s
redis-statefulset-0                         1/1     Running     0           4m00s
  1. Custom Appsmith's Configuration
  • After you successfully run the script, all the configuration files have been downloaded and & stored into <Installation Path>
  • If you want to update your app settings (ex: database host). Go to the <Installation Path>/config-template, update the corresponding value in the configmap file, then restart the pods.
  • Below steps will help you update database hostname of your application:
    • Open file appsmith-configmap.yaml in <Installation Path>/config-template folder
    • Update the value of variable APPSMITH_MONGODB_URI to your database host name
    • Run commands:
kubectl apply -f appsmith-configmap.yaml
kubectl scale deployment appsmith-internal-server --replicas=0
kubectl scale deployment appsmith-internal-server --replicas=1

{% hint style="success" %}

  • You can access the running application on the Ingress Endpoint if you not chose to provide custom domain for your application .
kubectl get ingress
NAME               CLASS    HOSTS   ADDRESS          PORTS   AGE
appsmith-ingress   <none>   *       XXX.XXX.XX.XXX   80      2m
  • You may need to wait 2-3 minutes before accessing the application to allow application start (depends on your cluster). {% endhint %}

Custom Domains

To host Appsmith on a custom domain, you can contact your domain registrar and update your DNS records. Most domain registrars have documentation on how you can do this yourself.

{% hint style="warning" %}

  • During the setup of Ingress Controller on your cloud. You will need to map your custom domain with the External IP of the controller before running the installation script
  • Below is an example how to achieve the External IP of NGINX Ingress Controller
➜ kubectl get svc -n ingress-nginx
NAME                                 TYPE           CLUSTER-IP    EXTERNAL-IP    PORT(S)                      AGE
ingress-nginx-controller             LoadBalancer   XX.XXX.X.XX   XX.XX.XX.XXX   80:XXXXX/TCP,443:XXXXX/TCP   17h
ingress-nginx-controller-admission   ClusterIP      XX.XXX.X.XX   <none>         443/TCP                      17h

{% endhint %}

Troubleshooting

If at any time you encounter an error during the installation process, reach out to support@appsmith.com or join our Discord Server

If you know the error and would like to reinstall Appsmith, simply delete the installation folder and the templates folder and execute the script again