Anahita Social Networking Platform
Version: 4.3.11 Birth Release
Anahita is a platform and framework for developing open science and knowledge sharing applications on a social networking foundation. Use Anahita to build:
- online learning and knowledge sharing networks
- information access networks about people, places, and things
- open science and open data networks
- online collaboration environments
- cloud back-end for your mobile apps
Anahita provides a genuine nodes and graphs architecture as well as design patterns for building social networking apps.
- actors: people, groups, or build your own custom actor
- media: notes, topics, todos, photos, articles, or build your own custom media
- hashtags: all actors, media, and comments are hashtagable
- locations: all actors and media are geolocatable
- stories: updates created by actors for their followers
- social graph: people and groups can be followed by other people.
- hashtags: for actors, media, and comments
- mentions: tag people in media and comments
- locations: tag locations in media and actors and search nearby nodes
- notifications: a person receives an email notification whenever a comment is posted on an item they are subscribed to.
- votes: people can Like/Unlike media and comments
- story feeds on dashboard and actor profiles
- MVC rapid app development framework specialized for building social apps
- fully customizable theme and user interfaces
- extendable by social apps and components
- RESTful and JSON APIs (ideal to use Anahita as a back-end for mobile apps)
- Built using your favourite technologies such as PHP5, MySql, Bootstrap, JQuery, Grunt, Composer, LessCSS
The code in the master branch is called the Embryo. It is what we use to power our website GetAnahita.com and it is constantly changing and evolving. It may contain bugs that are being fixed. Experimental features may be added and removed. Whenever we reach a specific milestone and the codebase is stable, it is packaged as a Birth relase.
If you are using any previous 4.* versions of Anahita, [here is how to upgrade] (https://www.getanahita.com/articles/158983-updating-from-anahita-4-2-to-4-3)
Before you start please make sure that your server meets the following requirements:
- Linux or unix server
- Nginx or Apache 2.0+
- MySql 5.6+
- php 5.6+ with OPcache and APCU. Use PHP 7.0+ for best results.
- Composer package management. You can download it following the instructions on http://getcomposer.org/ or just run the following command:
curl -s http://getcomposer.org/installer | php
If you have the suhosin patch installed on your server you might get an error. Add this line to your php.ini file to fix it:
suhosin.executor.include.whitelist = tmpl://, file://
Anahita is installed and managed via command line interface, because this is the most reliable approach especially after you accumulate large amounts of data in your database.
Also since MySql 5.7
ONLY_FULL_GROUP_BY is enabled by default and this is causing errors in Anahita. Connect to your MySql database via command line and run the following command to disable
Since version 5.7 MySql is set on strict mode by default. That causes Anahita to throw errors, especially if you are upgrading from older releases. To disable strict mode, you can run the following commands:
SET GLOBAL sql_mode=(SELECT REPLACE(@@sql_mode,'ONLY_FULL_GROUP_BY',''));
SET GLOBAL sql_mode=(SELECT REPLACE(@@sql_mode,'NO_ZERO_DATE',''));
Stable packages are called Birth releases. Use the following command to create an Anahita project called myproject. This command automatically downloads all the required files from the Anahita GitHub repository:
composer create-project anahita/project myproject
Now go to the myproject directory:
Continue with [Initiating Installation] (#initiating-installation) from this point.
The master branch always contains the Embryo release. Using the following command, clone the Anahita repository from the master branch:
git clone firstname.lastname@example.org:anahitasocial/anahita.git myproject
change directory to myproject
Now run the composer command to obtain all the 3rd party libraries that Anahita requires:
Continue with Initiating Installation from this point.
If you type php anahita you get a list of all commands available to manage your Anahita installation. If the command didn't work, perhaps the symlink to the anahita command line tool isn't created. In this case run the following command to create a symlink. Otherwise move to the next step which is initiating the installation process.
ln -s bin/anahita anahita
In order to initiate the installation process run the following command and provide your database information when it is asked from you:
php anahita site:init
The Anahita installation is created in the PATH-TO-YOUR-DIRECTORY/myproject/www directory. You need to configure your server to use this directory as the public directory.
The first account that is created on this installation becomes the Super Administrator account. Go to the http://www.YOUR-DOMAIN-NAME.com/people/signup and create an account.
Congratulations! You have installed Anahita successfully. Now you need to configure your installation and install some apps.
Now you need to make some configurations before you can use your Anahita for development or production server. To access the site settings:
- Login to your Anahita installation as a Super Administrator
- Click on your avatar on the top menubar
- Click on Site Settings. By default you will go to the Site Settings
Here are the options on the Site Settings view:
- About: has basic information about your Anahita installation such as creators and software version.
- System: system settings such as site name, database, and mail configurations happen here.
- Apps: configure Anahita apps for the entire site.
- Assignments: configure which actors (People, Groups, etc.) can use what apps (Topics, Photos, etc.)
- Plugins: configure Anahita plugins for the entire site.
- Templates: configure Anahita templates. That is only if they are configurable.
Anahita emails out a lot of email notifications. In order for the notifications to get sent out, you can setup a cron job on your server to the
yourdomain.com/components/com_notifications/process.php file. Make sure to go to Site Settings > Apps > Notifications and set Use Cron to Yes.
There are many articles on the web to show you how to setup a cron job. Depending on your number of users and activity on your site, anywhere from 15 minute to 1 hour intervals will work. You will find the suitable interval after monitoring your Anahita installation for a while.
Now it is time to extend your Anahita installation with some apps and components. Anahita comes with a list of social apps which you can use as they are or use them as blueprints for developing your own custom apps.
To get a list of available apps simply type the following command:
php anahita package:list
Now in order to install an app, for example the Photos app, type the following command:
php anahita package:install photos
You can even provide a list of apps and components in one line. For example to install the Groups, Topics, and Connect apps use the following command:
php anahita package:install groups topics connect
Go to Site Settings > Assignments to define whether an app should optionally or always be available on actor profiles (people, groups, etc.). If an app is optionally available, then on each actor profile the app can be enabled under the Edit Profile > Apps.
Congratulations! You have just installed some apps and extensions on your Anahita installation.
Nearly in all cases you wouldn't want to store the uploaded files on your own server. They add up very quickly and that makes it very difficult to maintain or migrate your Anahita installation. Anahita provides a plugin which allows all the uploaded files to be stored in the AWS or Amazon S3 cloud.
Go to Site Settings > Plugins and then from the type list select Storage. Edit and disable the Storage - Local plugin by clicking on it's name. Edit the Amazon S3 plugin using the following settings:
- Enabled: set to yes
- The folder to store the data: use assets as the default setting
- Bucket: enter the name of your Amazon S3 bucket
- Access Key: enter your AWS access key
- Secret Key: enter your AWS secret key
Now click Update to store the settings. Try uploading your avatar in the front-end and see if it gets uploaded properly. Check the image src to make sure it is an AWS url.
Anahita has an active and thriving tribe of hackers, entrepreneurs, and hackerpreneurs. They are helpful and friendly. So Join Us
Please Note: we do not answer questions in email. If you have any questions, please join the Anahita tribe and post your questions on the Tribe Support group where others can benefit from the answers too.
There are so many ways that you can report us a bug:
- open an issue here on our repository
- start a topic on Anahita Project group
- send us a friendly email and tell us how to reproduce the bug
Anahita could never be possible without the help of people in our tribe. We need contributors who can help us with testing, finding and fixing bugs, and coding of course. Here is a complete guideline of how you can contribute to Anahita.
Anahita is developed and maintained by rmdStudio Inc. a software development company in Vancouver, Canada. We develop web and mobile apps for scientific, healthcare, and industrial sectors.