This is a memorandum when Django is installed on Sakura's rental server (standard plan).
The default shell of Sakura's rental server is csh, but it is set to bash.
_Caution (additional note): _ It is possible to install Django itself, but since it is a rental server in the first place, I ranserver with the nohup command etc. and tried to see if it continued to work even after logging out, but the process was dropped because it was immediately regarded as deamon. .. I don't think it's a problem for trial use, but if you want it to stay running after you log out, it's better to use VPS obediently.
Insert pip by referring to here.
On Sakura's rental server, there is a .local directory in $ HOME, and it seems that you can put python related modules in it. (Because it is a rental server, you do not have root privileges.) easy_install is already in .local / bin, so you can install it without DL.
easy_install --prefix=~/.local pip
Add the path to $ HOME / .local / bin to your .bashrc.
export $HOME/.local/bin:/usr/sbin:/sbin:$PATH
Check if the path passes normally.
pip --version
However, note that you must add the --user option when doing [pip install]. ](Http://temprura.jp/memo/Sakura Server /) I didn't notice this and was addicted to it.
It is not essential, but it is better to be able to switch the environment easily, so Install virtualenv, virtualenvwrapper.
** You need to add the --user option to pip install if you are not in a virtual environment, but not in a virtual environment. ** **
pip install Django
With that, I was able to install Django fairly easily.
Recommended Posts