X-Git-Url: https://git.danix.xyz/?a=blobdiff_plain;f=articles%2Fgit-setup-own-server-part2.md;h=fe0d944686ed5cc925309a54151fc2d4c0009b43;hb=HEAD;hp=de3934dba6735cbd909f9a1a78c3abc9d7662c2a;hpb=47b603254a5f23a03984209df5a290442dcd1ff1;p=danix.xyz.git
diff --git a/articles/git-setup-own-server-part2.md b/articles/git-setup-own-server-part2.md
deleted file mode 100644
index de3934d..0000000
--- a/articles/git-setup-own-server-part2.md
+++ /dev/null
@@ -1,56 +0,0 @@
----
-title: Git â how to setup your own server pt 2
-author: Danilo M.
-type: post
-date: 2018-12-17T07:39:08+00:00
-excerpt: followup on my previous article regarding GIT and how to automatically deploy python flask scripts to serve a web app with apache.
-draft: true
-featured_image: /uploads/2018/07/gitout.jpg
-categories:
- - blogging
- - code
- - diy
- - linux
-tags:
- - automation
- - do it yourself
- - flask
- - git
- - howto
- - python
- - ssh
-
----
-This is a followup on [my previous article about how to setup your server][1] to handle a GIT repository and deploy to a web server like apache.
-
-Since I started experimenting with python and web publishing with it I wanted a way to push all the changes to my codebase directly to a web server, in a similar way as to what I already do with php and apache.
- I want to do it myself, the way I like it..
-
-
# create the virtual environment for python inside- -Now if we put all the py files for our flask web app we can run it inside apache, this is the configuration for the vhost I used: - -
# the folder /usr/local/virtualenvs/my-app:
virtualenv /usr/local/virtualenvs/my-app
# now create the directory inside the apache root
# to store our web app
mkdir /var/www/htdocs/my-app
<VirtualHost *:80>- -With this setting I can now reach my web app and test it after restarting the web server. - - [1]: https://danix.xyz/2018/07/git-setup-own-server/ - [2]: https://en.wikipedia.org/wiki/Web_Server_Gateway_Interface \ No newline at end of fileServerName my-app.mysite.ext
ErrorLog "/var/log/httpd/my-app.error_log"
CustomLog "/var/log/httpd/my-app.access_log" common
WSGIDaemonProcess my-app user=apache group=apache threads=5 python-home=/usr/local/virtualenvs/my-app
WSGIScriptAlias / /var/www/htdocs/my-app/my-app.wsgi
WSGIProcessGroup my-app
Alias "/static/" "/var/www/htdocs/my-app/static/"
<Directory "/var/www/htdocs/my-app/static/">
Order allow,deny
Allow from all
</Directory>
<Directory "/var/www/htdocs/my-app/">
Require all granted
</Directory>
</VirtualHost>