-
Notifications
You must be signed in to change notification settings - Fork 1
/
INSTALL
116 lines (82 loc) · 4.08 KB
/
INSTALL
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
1. Compilation
Reuqired libraries:
- dietlibc
- libowfat
You need a modified version of libowfat which supports
caltime/caldate functions. You can find a patch against
the current(Jul 2010) libowfat in the file:
0001-Add-caldate-and-caltime.patch
Get & patch & compile:
cvs -d :pserver:cvs@cvs.fefe.de:/cvs -z9 co libowfat
cd libowfat
patch -p1 < ../0001-Add-caldate-and-caltime.patch
make && sudo make install
I suggest you link against the vanilla dietlibc but you can
also link against the standard libc. Be aware that libowfat
and this package must be compiled with the same libc.
The makefile assumes that you have the dietlibc and libowfat
installed to /opt
Then type insided the root directory of this package:
make
By default the blog is installed to /var/www/blog you
can change that default by change the variable INSTALL_DIR
in the make file. Then execute
make install
If you want the tinymce editor in order to edit blog entries
cp the tinymce directory the blog installation:
cp -a tinymce /var/www/blog
(You will need to have the webserver configured correctly
in order for tinymce to work. This blog assumes that tinymce
is installed like this http://my.host.com/tinymce/)
2. Web server
CGI must be enabled. Currently the blog system only works when
served in the root path of a domain.
For a minimal lighttpd configuration look at README.lighttpd.
If you use another webserver you should use its mechanism to deny access to .inc
files. In Apache you can use htaccess. If your webserver does not support this
feature, you can recompile the the program, setting CONF_DB,SESSION_DB,
SESSION_DB_TMP to be somewhere on the webserver where they can not be accessed
via the http and put these files there. If you do not deny access to these
files, anyone can modify your blog.
3. Configuration
The blog can be configured using the webinterface at:
https://sub.mydomain.com/admin.cgi?login
You need to enter the default password (blogpass).
On the following site you will find a link called config which will lead
https://sub.mydomain.com/admin.cgi?config
On that page you can change your password, the title and the tagline of the
blog. Additional you can choose to provide a search box.
4. Command line tool
The command line tool allows to change the blog databases without using the
webinterface. It can be used to configure the blog. It is also possible to
add, delete and modify blog entries using the command line tool.
4.1 Command line tool configuration
To set a blog title use:
$ blogcmd -b /var/www/dynamic/blog/conf.inc -a -k title -v "My new Blog"
To set a tagline (additional information concerning your blog) which usually
appears below the blog title on the web page use:
$ blogcmd -b /var/www/dynamic/blog/conf.inc -a -k tagline -v "For comments write to me@me.com"
You can also modify these values later by using -m instead of -a.
4.2 Command line tool blogging
Admin.cgi allows you to add, delete and modify blog posts and the blog configuration.
You might not want to expose that functionality via http for security reasons.
Maybe the fact that admin.cgi enforces ssl connections and only sends session
information over ssl is not good enough for you.
You also might prefer vim over your browser for editing articles.
Here is how you add a new blog entry:
$ cat blogpost | blogcmd -t -a -b db/db.inc
You can also delete and modify if you know the key (timestamp) of your post.
Creating post for specific date is not yet implemented.
4. Blogging
The blog is now accessible via http://sub.mydomain.com. If you want to write a
new blog entry you have to navigate to the admin version of the blog.
Which is here: https://sub.mydomain.com/admin.cgi?login .
Note the "s" in https. This will direct you to the login page. After having
provided the correct password you will be able to add, delete and modify blog
posts.
Security
The uploads scripts contained in the upload directory are not secure.
By installing them on a server everybody might upload files to it which
is very probable to compromise security of the webserver. So
you should delete them or restrict access to them by means of
http basic authentication