This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudo lsof -i tcp:5000 | |
ps aux | grep 5000 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
rake test TEST=test/controllers/api/respond/v1/leads_controller_test.rb TESTOPTS="--name='/test_title/'" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
heroku pg:backups restore $(heroku pg:backups public-url -a doris-staging) DATABASE_URL -a doris-qa |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1. Log into AWS TPHub Dev via move.okta.com. | |
2. Go to EC2 Container Service and find the realsuite-widgets-respond app - click on it. | |
3. Click on "Tasks" tab. | |
4. Click on the Task Definition. | |
5. Get the Docker Image Definition and copy it to the clipboard. | |
6. In your local terminal: | |
$ docker-machine stop | |
$ docker-machine start default | |
$ eval $(docker-machine env default) | |
$ docker run -p 80:8000 -e NODE_ENV='development' -e ENV_PROFILE='development' -e REALSUITE_URL='http://controllo.local' docker.moveaws.com:443/prosoft/prosoft-realsuite-widget:2.0.0.4340.71b6b8f |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ssh your_user_name_on_the_server@your_server_ip_address | |
Once you are logged in, you can write: | |
1 sudo apt-get install ruby | |
2 sudo gem install rmate | |
If the above commands were successful, you are again on your local machine. You will need to redo the next step every time you want to connect to your server, and locally edit a file. Now, we need to create a connection between our local machine and the server. If you are on Linux or OSX write: | |
ssh -i "<your pem file> -R 52698:localhost:52698 your_user_name_on_the_server_@your_server_ip_address |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Get a deserialized object from a delayed job: | |
1. Get the delayed_job record using the id: dj = DelayedJob.find(<id>) | |
2. Get the handler field from dj: dj.handler | |
3. Convert it from YAML: YAML.parse(dj.handler) | |
4. You can get the ruby objects that the delayed job was built with by converting that to_ruby and calling the object: | |
YAML.parse(dj.handler).to_ruby.user | |
YAML.parse(dj.handler).to_ruby.prospect | |
YAML.parse(dj.handler).to_ruby.agent | |
etc. |