Developer's Introduction SelfStorageSMS
SelfStorageSMS (SSSMS) as a system automates the sending of “rent due” and collections notices via SMS (text message), automated phone calls and emails to tenants of self-storage facilities using specific management software titles, currently SiteLink and QuikStor. It does this by interfacing with databases containing facilities’ tenant and unit data and checking the status of each unit. If the unit’s information matches certain criteria, a notification is queued for the tenant and is then sent at a predetermined time in the facility’s time zone.
The system tracks messages sent and received and bills each facility based on a monthly flat-rate amount plus per-notification charges by sending transactions through an online credit card payment gateway. Using a Customer Portal, facilities have the ability to change their account and billing information, as well as customize the content of text notifications and the criteria for which each notification is sent. Reporting is provided automatically when each facility is billed; as well, facilities may use the Customer Portal to access reports at any time. Administrators have the ability to do these tasks as well as additional tasks related to servicing facility accounts, via an Admin Portal.
MessageReminders (MR) is a web application that allows individuals and businesses to send immediate and scheduled text message notices and reminders, and provides two-way text communications. MR supports both SMS and MMS messages. For the purpose of this document, the term “text message” will refer to either, except where specifically noted. Each client is provided with one or more secure logins that display various forms relevant for the way the client uses text messaging. Clients are also able to download activity reports in comma-separated (CSV) format. Reports can also be set up to be automatically emailed to customers on a weekly and/or monthly basis. Although most billing is set up as flat-rate recurring billing in the payment gateway, the ability to bill based on per-text activity exists.
1. Skills Required
The following skills and skill levels are required for satisfactory development of the SSSMS and MR systems:
|Skill||Required Proficiency||Preferred Proficiency|
|PHP General / Procedural||Moderate-High||Expert|
|Linux Admin / Shell Scripting||Basic||Moderate|
|TCP/IP Concepts / Configuration||Moderate||Moderate|
|HTML5 and CSS3||Moderate||Moderate-High|
|Database Schema Design||Moderate||Moderate|
|WHM and cPanel||Familiar||Familiar|
|Graphics Design / Manipulation||Basic||Basic|
|Computer Problem Solving||Moderate-High||Expert|
|Subversion||Heard of it||Familiar|
|WebSockets||Heard of it||Familiar|
2. Vendors and Third-Parties
SSSMS interfaces with a variety of third-party systems for input, output and monitoring. Facility data is obtained from SiteLink, Storage Commander, SWAMP and QuikStor. As well, notes are output to records when notifications are sent or messages received. The system uses Twilio as a telecommunications gateway for sending and receiving messages, placing automated phone calls and for billing usage reports. The credit card payment gateway is Payeezy, provided by First Data. Time zone data is retrieved from Timezonedb.com. MapQuest is used for geolocation. Infusionsoft is used for marketing and customer nurture campaigns.
MR interfaces with Twilio as its SMS gateway. Code has been written to also interface with Plivo as an SMS gateway although MR currently does not utilizes this code. The USAePay payment gateway is used for transaction processing.
Monitoring and alerts are provided by Uptime Robot and Pingdom. Other vendors include InMotion Hosting for hardware and network infrastructure, DNS Made Easy for DNS services and failover, SSLs.com for SSL certificates and LastPass to manage login credentials.
3. Hardware & Network Infrastructure
InMotion Hosting (IMH) provides server hardware and the network connectivity for them. There are two VPS accounts for SSSMS, one located in IMH’s east coast data center and the other in their west coast data center. The west coast (secondary) server hosts mail and development sites as well as replicated production sites. The east coast server (primary) contains live data and performs all production processing barring outage.
4. Replication & Failover
The systems are configured to replicate their production environments across two servers, both in WHM account set-up, programming code for each domain and instant data replication. Daily data
backups are made on each server for recovery, with each server's backup copied to the other. System monitoring with DNS failover allows the secondary server to go live hosting production activity in the event of outage on the primary server. DNS failover is on a per-domain basis, allowing domains not experiencing outage to continue running on the primary server while the secondary takes over for non- functional domains.
All development and testing takes place using development copies of production sites, hosted on the secondary server. There are three applications for which there is a Subversion software repository in use for version control; per policy, Subversion must be used with these three applications.
Following approval, new development is implemented on the primary server. Production changes made on the primary server are automatically replicated to redundant accounts on the secondary server.
6. WHM & cPanel
Administrative functions for the servers can be most easily performed using WHM (Web Hosting Manager) and cPanel (Control Panel). WHM is used to configure server-wide services and settings, and to create accounts for individual sites. The site control panels, cPanel, are used to configure and manage individual site accounts. URLs and login credentials for the WHMs and cPanels can be found in LastPass. Access to site cPanels can also be gained through WHMs “List Accounts” screen.
7. Secure Shell (SSH)
Both the primary and secondary servers run CentOS on Linux. Advanced administrative tasks, troubleshooting using server logs and scripts as well as functions not found in WHM may need to be performed using the Linux shell. The VPS utilizes SSL encryption in providing shell tasks. Additionally, an “allow” rule for the IP address of the individual desiring to access the shell must be added to the firewall.
All email is routed through the secondary server, including outbound mail generated by the Live server. Inbound email for SSSMS is stored in email accounts stored in the “selfstoragesms.com” WHM account on the secondary server, likewise for MR, “messagereminders.com”. Those mailboxes may be accessed, as well as new email addresses created, through the corresponding cPanel.
9. Domain Name System (DNS)
Correct domain name to IP address translation is essential to the proper operation of the system. DNS is provided by DNS Made Easy.
Cron is a service that runs automated tasks according to a predetermined schedule. All automation for both systems is performed via cron. These tasks include deleting old files, fetching data from SiteLink, sending notifications through Twilio, generating reports, processing billing, checking the status of free trial customers and new customer notifications. The proper configuration of these tasks is necessary for maintenance, timely functioning of the system and in order for processing to take place in the correct
sequence. Cron can be accessed through the secure shell (SSH) or via the “Cron Jobs” icon in the cPanel “Advanced” icon group.
Database administration can most easily be performed using phpMyAdmin, a web-based tool accessed through the servers’ cPanels. PhpMyAdmin can be used to modify the structure of the database and tables, edit data and tune basic MySQL parameters. Advanced configuration, such as for replication, requires or is more easily performed using the Secure Shell (SSH). Additional administrative tools may be used on direction or by approval.
The following APIs are used by the SSSMS system:
- Twilio: Communications Gateway (Calls, SMS/MMS)
- QuikStor: Self-Storage Management Software
- SiteLink: Self-Storage Management Software
- Storage Commander: Self-Storage Management Software
- FirstData Payeezy: Payment Card Transactions
- Infusionsoft: Marketing Campaigns
- Bitly: URL Shortening
- TimezoneDB: Time Zone Lookups & Geolocation
- MapQuest: Geolocation
- SSSMS: Internal API used by standalone Self-Storage Management Software (i.e. SWAMP) The following APIs are used by the MR system:
- Twilio and Plivo: SMS/MMS Gateways
- USAePay: Payment Card Transactions
- Bitly: URL Shortening Additionally, SSSMS has its own API for incoming connections from self-storage management software clients which do not have systems capable of accepting inbound connections.
The majority of PHP development uses a top-down procedural approach as opposed to an object- oriented approach. Interacting with self-storage management software and with SMS gateways is done through object-oriented classes. There is a selfstor class which acts as a wrapper for specific types of self-storage management software, such as SiteLink, Storage Commander, SWAMP or QuikStor. Thus, when selfstor is instantiated, it instantiates into itself either sitelink, stgcmndr, swamp or quikstor, depending on the software used by a particular facility, and passes many method calls to these classes. This allows scripts to access self-storage data abstractly, without necessarily caring which underlying class' methods are actually being used. Access to telecommunications gateway-specific code, such as for Twilio, uses the same approach.
Object-oriented code is often used when interfacing with a third-party library or vendor-supplied code that uses it.
MR uses an object-oriented MVC architecture.
Each client's login displays a variety of forms relevant to its use of MR. These different forms are accessible via Tabs shown at the top of the screen. The screen page represents an MVC View and each form is loaded into the view.
cascading style-sheets (CSS) loaded and a Controller called via Ajax, which handles data submitted by the form.
The Instant Messaging form connects with a WebSockets server for functionality rather than utilizing periodic Ajax calls.
In addition to the pages containing forms for clients' use, MR also has an administrative dashboard. Dashboard pages and forms use the same architecture as client pages.
Models provide classes for accessing, manipulating and/or sending data. There is a Model for working with text messages, a model for working with users, a model for database access, and so on. Third- party libraries, such as for Twilio, Plivo and PHPMailer, are also accessed through models' methods.
The .htaccess file uses the URI to determine which PHP script to call with which parameters in order to display the appropriate requested page. Configuration settings used throughout the system are found in a plain text .ini file.
Upgrade Your Instant Ramen
Instant ramen noodles—the quintessential, iconic budget food. While the pre-packaged variety is mostly associated with college dorms, the homemade or restaurant versions are celebrated for their decadent earthy flavors and soul-warming broth.
While I may not be able to make instant ramen any healthier (the noodles are deep fried, and therefore contain much more fat, not to mention the sodium), I have certainly cracked the code on getting a much more traditional and homemade flavor out of your 20 cent noodle soup.
Upgraded Instant Ramen
- mortar and pestle
- 1 pkg instant ramen noodle soup, chicken
- 3/4 cup water
- 1 tsp soy sauce
- 1 Tbsp red miso paste
- 1 Tbsp furikake (rice seasoning) or dried nori
- 1 Tbsp katsuobushi or bonito flakes
- ½ tsp fish sauce
- 1 tsp chili oil
- In a mortar and pestle or spice grinder, combine furikake and bonito flakes then grind to a fine powder to create instant dashi powder.
- In a serving bowl, add soy sauce, miso paste, and dashi powder and mix thoroughly to combine.
- Bring enough water to cover noodles to a boil on high heat. Cook instant ramen noodles for 3 minutes, or according to package directions. Reserve seasoning packet.
- Drain noodles and add to serving bowl along with water and half of ramen seasoning packet.
- Top with chili oil and your favorite ramen additions such as cilantro, green onion, nori, marinated soft boiled egg, etc...