Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issues while hosting in server using Apache2 #10

Open
sounak98 opened this issue Jul 5, 2017 · 1 comment
Open

Issues while hosting in server using Apache2 #10

sounak98 opened this issue Jul 5, 2017 · 1 comment

Comments

@sounak98
Copy link

sounak98 commented Jul 5, 2017

Set proxy

Add these lines of codes in the wsgi file.

os.environ['http_proxy']='http://proxy.iiit.ac.in:8080'
os.environ['https_proxy']='http://proxy.iiit.ac.in:8080'

Give permissions

WARNING Temporary Solution

Give permissions for the root directory.

chmod -R 777 /

Some files, specifically /proc would fail. This should be fine in general.

Set the HOME env variable

The user configured for the Apache2 server www-data with home folder as /var/www. This is the default configuration. But it has no HOME env variable. Add this line of code to set the HOME env variable in wsgi file.

os.environ['HOME']='/var/www'

Changes in literate-tools

Can use sounak98/literate-tools for now.

Change these lines in elisp/publish.el

(setq load-path
      (append
       (list "~/emacs/lisp/org-8.2.10/lisp"
	     "~/emacs/lisp/org-8.2.10/contrib/lisp")
       load-path))

to

(setq load-path
      (append
       (list (concat (getenv "HOME") "/emacs/lisp/org-8.2.10/lisp")
	     (concat (getenv "HOME") "/emacs/lisp/org-8.2.10/contrib/lisp"))
       load-path))

Please make the changes in literate-tools @travula

@travula
Copy link
Member

travula commented Jul 5, 2017

@sounak98

How about executing commands as root?

ssh -o "StrictHostKeyChecking no" <ip-address> "ls -la"

will list the files on the remote machine with ip equal to <ip-address>

The user root's public key on the remote is copied to the file authorized_keys on the same machine to accomplish this.

This can be applied to all the commands that are executed on the machine hosting resource-generator service.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants