mirror of
https://github.com/jcwimer/wrestlingApp
synced 2026-04-12 16:25:41 +00:00
Added email address variable
This commit is contained in:
@@ -46,7 +46,8 @@ The production version of this is currently deployed in Kubernetes. See [Deployi
|
|||||||
* `WRESTLINGDEV_DB_PORT=databaseport`
|
* `WRESTLINGDEV_DB_PORT=databaseport`
|
||||||
* `WRESTLINGDEV_DEVISE_SECRET_KEY=devise_key` can be generated with `rake secret`
|
* `WRESTLINGDEV_DEVISE_SECRET_KEY=devise_key` can be generated with `rake secret`
|
||||||
* `WRESTLINGDEV_SECRET_KEY_BASE=secret_key` can be generated with `rake secret`
|
* `WRESTLINGDEV_SECRET_KEY_BASE=secret_key` can be generated with `rake secret`
|
||||||
* `WRESTLINGDEV_EMAIL_PWD=emailpwd`
|
* `WRESTLINGDEV_EMAIL_PWD=emailpwd` Email has to be a gmail account for now.
|
||||||
|
* `WRESTLINGDEV_EMAIL=email address`
|
||||||
|
|
||||||
**Optional environment variables**
|
**Optional environment variables**
|
||||||
* `MEMCACHIER_PASSWORD=memcachier_password` needed for caching password
|
* `MEMCACHIER_PASSWORD=memcachier_password` needed for caching password
|
||||||
|
|||||||
@@ -104,7 +104,7 @@ Wrestling::Application.configure do
|
|||||||
:address => "smtp.gmail.com",
|
:address => "smtp.gmail.com",
|
||||||
:port => 587,
|
:port => 587,
|
||||||
:domain => "gmail.com",
|
:domain => "gmail.com",
|
||||||
:user_name => "jacob.wimer@gmail.com",
|
:user_name => ENV["WRESTLINGDEV_EMAIL"],
|
||||||
:password => ENV["WRESTLINGDEV_EMAIL_PWD"],
|
:password => ENV["WRESTLINGDEV_EMAIL_PWD"],
|
||||||
:authentication => :plain,
|
:authentication => :plain,
|
||||||
:enable_starttls_auto => true
|
:enable_starttls_auto => true
|
||||||
|
|||||||
@@ -28,5 +28,7 @@ Each push to master updates the docker `prod` tag and also pushes a tag with the
|
|||||||
Right now, mariadb's root password comes from the secrets.yaml and wrestlingdev uses the root password to run. Ideally, you'd create another secret for mariadb's root password and you'd create a user specifically for wrestlingdev.
|
Right now, mariadb's root password comes from the secrets.yaml and wrestlingdev uses the root password to run. Ideally, you'd create another secret for mariadb's root password and you'd create a user specifically for wrestlingdev.
|
||||||
From a mysql shell> `CREATE USER ${username} IDENTIFIED BY '${password}'; GRANT ALL PRIVILEGES ON ${database}.* TO ${username}; FLUSH PRIVILEGES;` $database would be wrestlingdev. I'll do this automatically later.
|
From a mysql shell> `CREATE USER ${username} IDENTIFIED BY '${password}'; GRANT ALL PRIVILEGES ON ${database}.* TO ${username}; FLUSH PRIVILEGES;` $database would be wrestlingdev. I'll do this automatically later.
|
||||||
|
|
||||||
|
Right now, we're also only using gmail for email.
|
||||||
|
|
||||||
## Recommended cloud machines
|
## Recommended cloud machines
|
||||||
In production, this runs on GKE. I have two node pools. The first is 2 x `n2-high-cpu-2` ($12.63/month preemptible). That pool can run 1 "copy" of the application. That means 2 x app pods, 1 x worker, 1 x memcached, and 1 x mariadb. The second node pool is an autoscale from 0-10 and is of the machine type `n1-standard-1` ($7.30/ month preemptible). This pool is scritly for scaling the app pods and the worker pods.
|
In production, this runs on GKE. I have two node pools. The first is 2 x `n2-high-cpu-2` ($12.63/month preemptible). That pool can run 1 "copy" of the application. That means 2 x app pods, 1 x worker, 1 x memcached, and 1 x mariadb. The second node pool is an autoscale from 0-10 and is of the machine type `n1-standard-1` ($7.30/ month preemptible). This pool is scritly for scaling the app pods and the worker pods.
|
||||||
@@ -68,6 +68,16 @@ spec:
|
|||||||
secretKeyRef:
|
secretKeyRef:
|
||||||
name: wrestlingdev-secrets
|
name: wrestlingdev-secrets
|
||||||
key: railssecretkey
|
key: railssecretkey
|
||||||
|
- name: WRESTLINGDEV_EMAIL_PWD
|
||||||
|
valueFrom:
|
||||||
|
secretKeyRef:
|
||||||
|
name: wrestlingdev-secrets
|
||||||
|
key: gmailpassword
|
||||||
|
- name: WRESTLINGDEV_EMAIL
|
||||||
|
valueFrom:
|
||||||
|
secretKeyRef:
|
||||||
|
name: wrestlingdev-secrets
|
||||||
|
key: gmailemail
|
||||||
resources:
|
resources:
|
||||||
limits:
|
limits:
|
||||||
cpu: "0.5"
|
cpu: "0.5"
|
||||||
|
|||||||
@@ -8,4 +8,6 @@ stringData:
|
|||||||
dbusername: root
|
dbusername: root
|
||||||
dbpassword: PUT_SECRET_HERE
|
dbpassword: PUT_SECRET_HERE
|
||||||
devisesecretkey: PUT_SECRET_HERE get from running rails secret
|
devisesecretkey: PUT_SECRET_HERE get from running rails secret
|
||||||
railssecretkey: PUT_SECRET_HERE get from running rails secret
|
railssecretkey: PUT_SECRET_HERE get from running rails secret
|
||||||
|
emailpassword: PUT_EMAIL_PASSWORD_HERE
|
||||||
|
gmailemail: PUT EMAIL ADDRESS HERE
|
||||||
Reference in New Issue
Block a user