Skip to content

Commit

Permalink
removed email host passwords
Browse files Browse the repository at this point in the history
  • Loading branch information
vahagpetrosyan committed Jun 12, 2024
1 parent 3f421c2 commit 872d3b9
Show file tree
Hide file tree
Showing 4 changed files with 45 additions and 14 deletions.
8 changes: 4 additions & 4 deletions Ethosight/bin/environment_vars.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@ export EthosightBackendURL="http://localhost:80"
export DjangoEthosightAppBaseDir="/home/ubuntu/lxdshared/DeepVision/Ethosight/website/EthosightAppBasedir"
export EthosightYAMLDirectory="/home/ubuntu/lxdshared/DeepVision/Ethosight/configs"
export ETHOSIGHT_APP_BASEDIR="/home/ubuntu/lxdshared/DeepVision/Ethosight/website/EthosightAppBasedir"
export EMAIL_HOST="email-smtp.us-east-1.amazonaws.com"
export EMAIL_PORT="587"
export EMAIL_HOST=""
export EMAIL_PORT="0"
export EMAIL_USE_TLS="True"
export EMAIL_USE_SSL="False"
export EMAIL_HOST_USER="vault_email_host_user"
export EMAIL_HOST_PASSWORD="vault_email_host_password"
export EMAIL_HOST_USER=""
export EMAIL_HOST_PASSWORD=""

23 changes: 23 additions & 0 deletions Ethosight/install/create_conda_env.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
---
- name: Setup Conda environment and install core package
hosts: all
become: no

vars:
playbook_dir: "{{ playbook_dir | default(lookup('env', 'PWD')) }}"
conda_env_path: "{{ playbook_dir }}/environment.yml"
ethosight_path: "{{ playbook_dir }}/.."

tasks:
- name: Create Conda environment from file
shell: conda env create -f "{{ conda_env_path }}"
args:
executable: /bin/bash

- name: Activate environment and install core package
shell: |
source "$(conda info --base)/etc/profile.d/conda.sh"
conda activate $(head -1 "{{ conda_env_path }}" | cut -d' ' -f2)
pip install -e "{{ ethosight_path }}"
args:
executable: /bin/bash
16 changes: 13 additions & 3 deletions Ethosight/install/install_docker.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,17 @@
hosts: all
become: yes # Use sudo to run the commands
tasks:
- name: Remove potentially conflicting Docker packages
apt:
name:
- docker
- docker-engine
- docker.io
- docker-ce
state: absent
force_apt_get: yes
purge: yes

- name: Install required packages
apt:
name:
Expand Down Expand Up @@ -31,13 +42,12 @@

- name: Add user to the Docker group
user:
name: "{{ ansible_user_id }}"
groups: docker
name: "{{ ansible_user_id }}" # this user is your root user as we are using become: yes,
groups: docker # which might be different from your session user, and you will have to add your user to docker group manually
append: yes

- name: Ensure Docker is started and enabled
systemd:
name: docker
enabled: yes
state: started

12 changes: 5 additions & 7 deletions Ethosight/install/uservars.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,10 @@ EthosightYAMLDirectory: "/home/ubuntu/lxdshared/DeepVision/Ethosight/configs"
ETHOSIGHT_APP_BASEDIR: "/home/ubuntu/lxdshared/DeepVision/Ethosight/website/EthosightAppBasedir"

# Email settings for sending access codes
EMAIL_HOST: "email-smtp.us-east-1.amazonaws.com"
EMAIL_PORT: 587
# Use your own settings
EMAIL_HOST: ""
EMAIL_PORT: 0
EMAIL_USE_TLS: true
EMAIL_USE_SSL: false
EMAIL_HOST_USER: "vault_email_host_user"
EMAIL_HOST_PASSWORD: "vault_email_host_password"

#EMAIL_HOST_USER: "{{ vault_email_host_user }}"
#EMAIL_HOST_PASSWORD: "{{ vault_email_host_password }}"
EMAIL_HOST_USER: ""
EMAIL_HOST_PASSWORD: ""

0 comments on commit 872d3b9

Please sign in to comment.