Steps to store the environment variables in .bash_profile file
-
Create (if not exists) a .profile file in ~ or $HOME directory to contain the user-specific variables. Follow the below steps:
-
In the ~ directory, run echo $PATH. Copy the output.
-
Create a new .profile file using touch .bash_profile.
-
Open it up for editing using any editor. Add the copied $PATH variable value, for example:
export PATH=$PATH:/usr/local/mysql/bin/
-
Add the value for other variables specific for you:
export POSTGRESS_USERNAME=myusername; export POSTGRES_PASSWORD=mypassword; export POSTGRES_DATABASE=postgres; export POSTGRES_HOST=udagramdemo.abc4def.us-east-2.rds.amazonaws.com; export AWS_REGION=us-east-2; export AWS_PROFILE=default; export AWS_MEDIA_BUCKET=udagramdemo; export JWT_SECRET=helloworld;
Change the values of the above mentioned variables as applicable for you.
Before we get started, confirm that you have installed NodeJs, npm and Ionic Framework by checking the versions:
node --version
npm --version
ionic --version.
If you get a not found message, install the required item:
Ionic CLI if you don't already have it installed Nodejs and npm
cd docker/
docker-compose -f docker-compose-build.yaml build --parallel
docker-compose up