| 61 | == Sample full config file == |
| 62 | |
| 63 | {{{ |
| 64 | |
| 65 | { |
| 66 | // Official SOGo documents: |
| 67 | // - http://www.sogo.nu/english/support/documentation.html |
| 68 | // - http://wiki.sogo.nu |
| 69 | // |
| 70 | // Mailing list: |
| 71 | // - http://www.sogo.nu/english/support/community.html |
| 72 | |
| 73 | // Enable verbose logging. Reference: |
| 74 | // http://www.sogo.nu/nc/support/faq/article/how-to-enable-more-verbose-logging-in-sogo.html |
| 75 | //ImapDebugEnabled = YES; |
| 76 | //LDAPDebugEnabled = YES; |
| 77 | //MySQL4DebugEnabled = YES; |
| 78 | //PGDebugEnabled = YES; |
| 79 | |
| 80 | // Daemon address and port |
| 81 | WOPort = 127.0.0.1:20000; |
| 82 | |
| 83 | // PID file |
| 84 | //WOPidFile = /var/run/sogo/sogo.log; |
| 85 | |
| 86 | // Log file |
| 87 | //WOLogFile = /var/log/sogo/sogo.log; |
| 88 | |
| 89 | // IMAP connection pool. |
| 90 | // Your performance will slightly increase, as you won't open a new |
| 91 | // connection for every access to your IMAP server. |
| 92 | // But you will get a lot of simultaneous open connections to your IMAP |
| 93 | // server, so make sure he can handle them. |
| 94 | // For debugging it is reasonable to turn pooling off. |
| 95 | //NGImap4DisableIMAP4Pooling = NO; |
| 96 | |
| 97 | SOGoProfileURL = "mysql://sogo:password@127.0.0.1:3306/sogo/sogo_user_profile"; |
| 98 | OCSFolderInfoURL = "mysql://sogo:password@127.0.0.1:3306/sogo/sogo_folder_info"; |
| 99 | OCSSessionsFolderURL = "mysql://sogo:password@127.0.0.1:3306/sogo/sogo_sessions_folder"; |
| 100 | OCSEMailAlarmsFolderURL = "mysql://sogo:password@127.0.0.1:3306/sogo/sogo_alarms_folder"; |
| 101 | |
| 102 | // With 3 parameters below, SOGo requires only 9 SQL tables in total |
| 103 | // instead of creating 4 SQL tables for each user. |
| 104 | OCSCacheFolderURL = "mysql://sogo:password@127.0.0.1:3306/sogo/sogo_cache_folder"; |
| 105 | OCSStoreURL = "mysql://sogo:password@127.0.0.1:3306/sogo/sogo_store"; |
| 106 | OCSAclURL = "mysql://sogo:password@127.0.0.1:3306/sogo/sogo_acl"; |
| 107 | |
| 108 | // Default language in the web interface |
| 109 | SOGoLanguage = English; |
| 110 | |
| 111 | // Specify which module to show after login: Calendar, Mail, Contacts. |
| 112 | SOGoLoginModule = Mail; |
| 113 | |
| 114 | // Must login with full email address |
| 115 | SOGoForceExternalLoginWithEmail = YES; |
| 116 | |
| 117 | // Allow user to change full name and email address. |
| 118 | SOGoMailCustomFromEnabled = YES; |
| 119 | |
| 120 | // Enable email-based alarms on events and tasks. |
| 121 | SOGoEnableEMailAlarms = YES; |
| 122 | |
| 123 | // IMAP server |
| 124 | //SOGoIMAPServer = "imaps://127.0.0.1:143/?tls=YES"; |
| 125 | // Local connection is considered as secure by Dovecot. |
| 126 | SOGoIMAPServer = "imap://127.0.0.1:143/"; |
| 127 | |
| 128 | // SMTP server |
| 129 | SOGoMailingMechanism = smtp; |
| 130 | SOGoSMTPServer = 127.0.0.1; |
| 131 | //SOGoSMTPAuthenticationType = PLAIN; |
| 132 | |
| 133 | // Enable managesieve service |
| 134 | // |
| 135 | // WARNING: Sieve scripts generated by SOGo is not compatible with Roundcube |
| 136 | // webmail, don't use sieve service in both webmails, otherwise |
| 137 | // it will be messy. |
| 138 | // |
| 139 | //SOGoSieveServer = sieve://127.0.0.1:4190; |
| 140 | //SOGoSieveScriptsEnabled = YES; |
| 141 | //SOGoVacationEnabled = YES; |
| 142 | //SOGoForwardEnabled = YES; |
| 143 | |
| 144 | // Memcached |
| 145 | SOGoMemcachedHost = 127.0.0.1; |
| 146 | |
| 147 | SOGoTimeZone = "America/New_York"; |
| 148 | |
| 149 | SOGoFirstDayOfWeek = 1; |
| 150 | |
| 151 | SOGoRefreshViewCheck = every_5_minutes; |
| 152 | SOGoMailReplyPlacement = below; |
| 153 | |
| 154 | SOGoAppointmentSendEMailNotifications = YES; |
| 155 | SOGoFoldersSendEMailNotifications = YES; |
| 156 | SOGoACLsSendEMailNotifications = YES; |
| 157 | |
| 158 | // PostgreSQL cannot update view |
| 159 | SOGoPasswordChangeEnabled = YES; |
| 160 | |
| 161 | // Authentication using SQL |
| 162 | SOGoUserSources = ( |
| 163 | { |
| 164 | type = sql; |
| 165 | id = vmail_mailbox; |
| 166 | viewURL = "mysql://sogo:password@127.0.0.1:3306/sogo/users"; |
| 167 | canAuthenticate = YES; |
| 168 | |
| 169 | // Default algorithm used when changing passwords. |
| 170 | userPasswordAlgorithm = ssha; |
| 171 | prependPasswordScheme = YES; |
| 172 | |
| 173 | // Use vmail.mailbox as global address book. |
| 174 | // WARNING: This will search all user accounts, not just accounts |
| 175 | // under same domain as login user. |
| 176 | //isAddressBook = YES; |
| 177 | //displayName = "Global Address Book"; |
| 178 | } |
| 179 | ); |
| 180 | } |
| 181 | |
| 182 | }}} |
| 183 | |
| 184 | == Apache Server Setup == |
| 185 | |
| 186 | {{{ |
| 187 | |
| 188 | Apache web server |
| 189 | |
| 190 | SOGo installs Apache config file /etc/httpd/conf.d/SOGo.conf by default, please open it, comment out 2 ProxyPass directives as shown below: |
| 191 | |
| 192 | #ProxyPass /Microsoft-Server-ActiveSync ... |
| 193 | #ProxyPass /SOGo http://127.0.0.1:20000/SOGo retry=0 |
| 194 | |
| 195 | Add 2 ProxyPass directives in /etc/httpd/conf.d/ssl.conf, so that SOGo is only accessible via https. |
| 196 | |
| 197 | ProxyPass /Microsoft-Server-ActiveSync \ |
| 198 | http://127.0.0.1:20000/SOGo/Microsoft-Server-ActiveSync \ |
| 199 | retry=60 connectiontimeout=5 timeout=360 |
| 200 | |
| 201 | ProxyPass /SOGo http://127.0.0.1:20000/SOGo retry=0 |
| 202 | |
| 203 | Open /etc/httpd/conf.d/SOGo.conf again, find 3 RequestHeader directives like below: |
| 204 | |
| 205 | RequestHeader set "x-webobjects-server-port" ... |
| 206 | RequestHeader set "x-webobjects-server-name" ... |
| 207 | RequestHeader set "x-webobjects-server-url" ... |
| 208 | |
| 209 | Replace them by below settings: |
| 210 | |
| 211 | RequestHeader set "x-webobjects-server-port" "443" |
| 212 | RequestHeader set "x-webobjects-server-name" "%{HTTP_HOST}e" env=HTTP_HOST |
| 213 | RequestHeader set "x-webobjects-server-url" "https://%{HTTP_HOST}e" env=HTTP_HOST |
| 214 | |
| 215 | Append line below in /etc/httpd/conf.d/SOGo.conf, no matter upper or lower case letters of SOGo in the url, Apache will always to https: |
| 216 | |
| 217 | RedirectMatch ^/[Ss][Oo][Gg][Oo](.*) /SOGo$1 |
| 218 | |
| 219 | Restart Apache service. |
| 220 | |
| 221 | |
| 222 | }}} |