summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Dockerfile8
-rw-r--r--config/config.json4
-rw-r--r--config/config_docker.json85
-rwxr-xr-xdocker/docker-entry.sh (renamed from docker-entry.sh)4
-rw-r--r--docker/main.cf (renamed from config/main.cf)13
-rw-r--r--utils/config_test.go4
6 files changed, 96 insertions, 22 deletions
diff --git a/Dockerfile b/Dockerfile
index da57550c0..5c389c056 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -1,3 +1,5 @@
+# Copyright (c) 2015 Spinpunch, Inc. All Rights Reserved.
+# See License.txt for license information.
FROM ubuntu:14.04
# Install Dependancies
@@ -83,15 +85,15 @@ RUN wget http://download.redis.io/redis-stable.tar.gz; \
ADD . /go/src/github.com/mattermost/platform
# Insert postfix config
-ADD ./config/main.cf /etc/postfix/
+ADD ./docker/main.cf /etc/postfix/
RUN go get github.com/tools/godep
RUN cd /go/src/github.com/mattermost/platform; godep restore
RUN go install github.com/mattermost/platform
RUN cd /go/src/github.com/mattermost/platform/web/react; npm install
-RUN chmod +x /go/src/github.com/mattermost/platform/docker-entry.sh
-ENTRYPOINT /go/src/github.com/mattermost/platform/docker-entry.sh
+RUN chmod +x /go/src/github.com/mattermost/platform/docker/docker-entry.sh
+ENTRYPOINT /go/src/github.com/mattermost/platform/docker/docker-entry.sh
# Ports
EXPOSE 80
diff --git a/config/config.json b/config/config.json
index 3d2c26716..1b844c259 100644
--- a/config/config.json
+++ b/config/config.json
@@ -9,7 +9,7 @@
},
"ServiceSettings": {
"SiteName": "Mattermost Preview",
- "Domain": "",
+ "Domain": "xxxxxxmustbefilledin.com",
"Mode" : "dev",
"AllowTesting" : false,
"UseSSL": false,
@@ -56,7 +56,7 @@
"EmailSettings": {
"SMTPUsername": "",
"SMTPPassword": "",
- "SMTPServer": "localhost:25",
+ "SMTPServer": "",
"UseTLS": false,
"FeedbackEmail": "feedback@xxxxxxmustbefilledin.com",
"FeedbackName": "",
diff --git a/config/config_docker.json b/config/config_docker.json
new file mode 100644
index 000000000..f2e56bef8
--- /dev/null
+++ b/config/config_docker.json
@@ -0,0 +1,85 @@
+{
+ "LogSettings": {
+ "ConsoleEnable": false,
+ "ConsoleLevel": "DEBUG",
+ "FileEnable": true,
+ "FileLevel": "INFO",
+ "FileFormat": "",
+ "FileLocation": ""
+ },
+ "ServiceSettings": {
+ "SiteName": "Mattermost Preview",
+ "Domain": "",
+ "Mode" : "prod",
+ "AllowTesting" : false,
+ "UseSSL": false,
+ "Port": "80",
+ "Version": "developer",
+ "Shards": {
+ },
+ "InviteSalt": "gxHVDcKUyP2y1eiyW8S8na1UYQAfq6J6",
+ "PublicLinkSalt": "TO3pTyXIZzwHiwyZgGql7lM7DG3zeId4",
+ "ResetSalt": "IPxFzSfnDFsNsRafZxz8NaYqFKhf9y2t",
+ "AnalyticsUrl": ""
+ },
+ "SqlSettings": {
+ "DriverName": "mysql",
+ "DataSource": "mmuser:mostest@tcp(localhost:3306)/mattermost_test",
+ "DataSourceReplicas": ["mmuser:mostest@tcp(localhost:3306)/mattermost_test"],
+ "MaxIdleConns": 10,
+ "MaxOpenConns": 10,
+ "Trace": false,
+ "AtRestEncryptKey": "Ya0xMrybACJ3sZZVWQC7e31h5nSDWZFS"
+ },
+ "RedisSettings": {
+ "DataSource": "localhost:6379",
+ "MaxOpenConns": 1000
+ },
+ "AWSSettings": {
+ "S3AccessKeyId": "",
+ "S3SecretAccessKey": "",
+ "S3Bucket": "",
+ "S3Region": "",
+ "Route53AccessKeyId": "",
+ "Route53SecretAccessKey": "",
+ "Route53ZoneId": "",
+ "Route53Region": ""
+ },
+ "ImageSettings": {
+ "ThumbnailWidth": 200,
+ "ThumbnailHeight": 0,
+ "PreviewWidth": 1024,
+ "PreviewHeight": 0,
+ "ProfileWidth": 128,
+ "ProfileHeight": 128
+ },
+ "EmailSettings": {
+ "SMTPUsername": "",
+ "SMTPPassword": "",
+ "SMTPServer": "localhost:25",
+ "UseTLS": false,
+ "FeedbackEmail": "feedback@xxxxxxmustbefilledin.com",
+ "FeedbackName": "",
+ "ApplePushServer": "",
+ "ApplePushCertPublic": "",
+ "ApplePushCertPrivate": ""
+ },
+ "PrivacySettings": {
+ "ShowEmailAddress": true,
+ "ShowPhoneNumber": true,
+ "ShowSkypeId": true,
+ "ShowFullName": true
+ },
+ "TeamSettings": {
+ "MaxUsersPerTeam": 150,
+ "AllowPublicLink": true,
+ "AllowValet": false,
+ "TermsLink": "/static/help/configure_links.html",
+ "PrivacyLink": "/static/help/configure_links.html",
+ "AboutLink": "/static/help/configure_links.html",
+ "HelpLink": "/static/help/configure_links.html",
+ "ReportProblemLink": "/static/help/configure_links.html",
+ "TourLink": "/static/help/configure_links.html",
+ "DefaultThemeColor": "#2389D7"
+ }
+}
diff --git a/docker-entry.sh b/docker/docker-entry.sh
index db6ccaa18..cfa589041 100755
--- a/docker-entry.sh
+++ b/docker/docker-entry.sh
@@ -1,4 +1,6 @@
#!/bin/bash
+# Copyright (c) 2015 Spinpunch, Inc. All Rights Reserved.
+# See License.txt for license information.
mkdir -p web/static/js
@@ -114,7 +116,7 @@ echo starting react processor
cd /go/src/github.com/mattermost/platform/web/react && npm start &
echo starting go web server
-cd /go/src/github.com/mattermost/platform/; go run mattermost.go -config=config.json &
+cd /go/src/github.com/mattermost/platform/; go run mattermost.go -config=config_docker.json &
echo starting compass watch
cd /go/src/github.com/mattermost/platform/web/sass-files && compass watch
diff --git a/config/main.cf b/docker/main.cf
index 72eba333f..ed97d37ef 100644
--- a/config/main.cf
+++ b/docker/main.cf
@@ -1,21 +1,11 @@
-# See /usr/share/postfix/main.cf.dist for a commented, more complete version
-
-
-# Debian specific: Specifying a file name will cause the first
-# line of that file to be used as the name. The Debian default
-# is /etc/mailname.
myorigin = mattermost.com
myhostname = mattermost.com
smtpd_banner = $myhostname ESMTP $mail_name (Ubuntu)
biff = no
-# appending .domain is the MUA's job.
append_dot_mydomain = no
-# Uncomment the next line to generate "delayed mail" warnings
-#delay_warning_time = 4h
-
readme_directory = no
# TLS parameters
@@ -26,9 +16,6 @@ smtp_use_tls=no
smtpd_tls_session_cache_database = btree:${data_directory}/smtpd_scache
smtp_tls_session_cache_database = btree:${data_directory}/smtp_scache
-# See /usr/share/doc/postfix/TLS_README.gz in the postfix-doc package for
-# information on enabling SSL in the smtp client.
-
smtpd_relay_restrictions = permit_mynetworks permit_sasl_authenticated defer_unauth_destination
alias_maps = hash:/etc/aliases
alias_database = hash:/etc/aliases
diff --git a/utils/config_test.go b/utils/config_test.go
index f6746f3ac..9067dc647 100644
--- a/utils/config_test.go
+++ b/utils/config_test.go
@@ -4,7 +4,7 @@
package utils
import (
- //"os"
+ "os"
"testing"
)
@@ -12,7 +12,6 @@ func TestConfig(t *testing.T) {
LoadConfig("config.json")
}
-/*
func TestEnvOverride(t *testing.T) {
os.Setenv("MATTERMOST_DOMAIN", "testdomain.com")
@@ -26,4 +25,3 @@ func TestEnvOverride(t *testing.T) {
t.Fail()
}
}
-*/