diff --git a/app/mailers/application_mailer.rb b/app/mailers/application_mailer.rb index 1eebfdd..3e05b51 100644 --- a/app/mailers/application_mailer.rb +++ b/app/mailers/application_mailer.rb @@ -40,7 +40,7 @@ def get_options(settings) address: settings.address, port: settings.port, domain: settings.domain, - authentication: 'plain', + authentication: 'login', enable_starttls_auto: true } end diff --git a/app/models/admin_user.rb b/app/models/admin_user.rb new file mode 100644 index 0000000..5ad93f8 --- /dev/null +++ b/app/models/admin_user.rb @@ -0,0 +1,5 @@ +class AdminUser < ApplicationRecord + # Include default devise modules. Others available are: + # :confirmable, :lockable, :timeoutable and :omniauthable + devise :database_authenticatable, :recoverable, :rememberable, :trackable, :validatable +end diff --git a/app/models/mail_setting.rb b/app/models/mail_setting.rb deleted file mode 100644 index dfea94f..0000000 --- a/app/models/mail_setting.rb +++ /dev/null @@ -1,8 +0,0 @@ -class MailSetting < ApplicationRecord - belongs_to :account - - def all_present? - from_email.present? && address.present? && port.present? && - domain.present? && address.present? && user_name.present? - end -end diff --git a/app/views/home/documentation.html.erb b/app/views/home/documentation.html.erb index e69de29..588b2b8 100644 --- a/app/views/home/documentation.html.erb +++ b/app/views/home/documentation.html.erb @@ -0,0 +1,83 @@ +
A simple dockerized rails app to manage your emails and campaigns with taggings.
+ + +Install the most recent version of the Docker Engine for your platform using the official Docker releases, which can also be installed using:
+wget -qO- https://get.docker.com/ | sh
+
+ Install docker compose from the official page.
+curl -L "https://github.com/docker/compose/releases/download/1.11.2/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose
+ chmod +x /usr/local/bin/docker-compose
+
+ You can use sqlite
, postgresql
, mysql
and sql server
.
Create a database.yml and link it in the docker-compose.yml
+mkdir -p /datadrive/csv-files && mkdir -p /datadrive/data/db && mkdir -p /datadrive/data/redis && mkdir -p /datadrive/data/nginx && mkdir -p /datadrive/working-dir
+
+ cd /datadrive && wget https://raw.githubusercontent.com/mojilala/smart-emailing/master/config/database.yml
+
+ cd /datadrive && wget https://raw.githubusercontent.com/mojilala/smart-emailing/master/config/database_mysql.example.yml
+
+ cd /datadrive && wget https://raw.githubusercontent.com/mojilala/smart-emailing/master/config/database_postgresql.example.yml
+
+ cd /datadrive && wget https://raw.githubusercontent.com/mojilala/smart-emailing/master/config/database_azure_sql.example.yml
+
+ cd /datadrive/data/nginx && wget https://raw.githubusercontent.com/mojilala/smart-emailing/master/nginx/my_proxy.conf
+
+ cd /datadrive/working-dir && wget https://raw.githubusercontent.com/mojilala/smart-emailing/master/docker-compose.yml
+
+ sudo docker-compose build
+ sudo docker-compose run web rake db:migrate
+ sudo docker-compose up -d
+
+ We used the tool very day, so we test on production :)
+ There are no tests. any test contrubtions are verywelcome.
git checkout -b my-new-feature
)git commit -am 'Add some feature'
)git push origin my-new-feature
)