Google Cloud Partial Autoscaling - Flaarum Tutorials
Method of Autoscaling
flaarum can be setup to autoscale in this manner: a big server in the day time (from 7:00) and a small server in the night time (from 22:00). This would save the developer some costs for single country deployments.
This method involves two servers: the control server and the data server. The data server would be resized when it is 7:00 or 22:00
Setup Instructions
- sudo snap install flaa103
- Run flaa103 init to create a launch configuration file.
- Edit the file created and make sure no entry is empty.
- Get your service account key file from Google Cloud console. and place in the folder gotten from flaa103 pwd
- To launch run flaa103 las launchfile serviceaccountkeyfile . Only file names, no path
- To get your keystring and ip address log into Google Cloud Console. The data server would be named with flaarum- prefix and the control server would be name with flaa103- prefix.
- After you SSH into your data server. run flaarum.prod r to get your keystring.
Update Instructions
Supposing you want to change your day config to a higher or lower machine.
- SSH into your control server. Control servers's would be prefixed with flaa103-
- Update the config at /var/snap/flaa103/common/input.zconf
- Run flaa103.gcasrn to do a relaunch
- Run sudo snap restart flaa103.gcasr to restart the resizer daemon
Supposed you want to upgrade your disk size. Do that in Google Cloud Storage. Changing the disk size is not managed by the flaa103 resizer.