Commit 78d0185a by aagusti

perbaikan README dan sample configuration live.ini

1 parent 0f6b8659
# Basis Aplikasi openSIPKD
========================
Ini adalah basis dari seluruh aplikasi openSIPKD.
Pemasangan
----------
# Pemasangan
Pasang paket Debian yang dibutuhkan::
## Pasang paket Debian yang dibutuhkan::
$ sudo apt-get install libxml2-dev libxslt1-dev libtiff5-dev libjpeg8-dev zlib1g-dev libfreetype6-dev liblcms2-dev libwebp-dev
$ sudo apt install libxml2-dev libxslt1-dev libtiff5-dev libjpeg8-dev zlib1g-dev libfreetype6-dev liblcms2-dev libwebp-dev
Buat Python Virtual Environment, biasanya pada home directory::
## Buat Python Virtual Environment:
Biasanya pada home directory::
$ python3 -m venv ~/env
$ ~/env/bin/pip install --upgrade pip setuptools
$ ~/env/bin/pip install wheel
Install Production
------------------
##Instalasi
###Production:
$ ~/env/bin/pip install git+https://git.opensipkd.com/aa.gusti/base.git@latest
$ cp ~/env/etc/live_opensipkd.tpl ~/env/etc/live_opensipkd.ini
Install Development::
-------------------
###Install Development::
$ source ~/env/bin/activate
$ mkdir apps
$ cd apps
$ git clone https://git.opensipkd.com/bekasi/base.git@ciamis
$ git clone https://git.opensipkd.com/aa.gusti/base.git@latest
$ env/bin/pip install -e base[dev]
$ cp ~/env/etc/test_opensipkd.tpl ~/env/etc/test_opensipkd.ini
Sesuaikan konfigurasi ``test_opensipkd.ini`` atau ``live_opensipkd.ini``
pada baris berikut ini::
##Sesuaikan konfigurasi
Konfigurasi tergantung pada jenis instalasi ``test_opensipkd.ini`` atau
``live_opensipkd.ini``pada baris berikut ini::
###Database Koneksi:
[app:main]
sqlalchemy.url = postgresql://user:password@localhost:5432/db
session.url = postgresql://user:password@localhost:5432/db
[alembic_ziggurat]
sqlalchemy.url = postgresql://user:password@localhost:5432/db
script_location = ziggurat_foundation:migration
......@@ -45,9 +48,24 @@ pada baris berikut ini::
sqlalchemy.url = postgresql://user:password@localhost:5432/db
script_location = opensipkd.base:alembic
Handling Log File:
==================
###Login/Register:
[app:main]
captcha_files=
# static folder untuk image captcha
reg_captcha = 1
# saat registrasi diwajibkan menggunakan captcha
reg_idcard = 1
# saat registrasi diwajibkan mengisi kode/nik pengguna
# akan menampilkan pula upload file id card
reg_verify = 1
# Registrasi memrlukan verifikasi terlebih dahulu sebelum dapat login
reg_form =
# diisi route registrasi default "register" jika dikosongkan
login_tpl =
# diisi nama template login apabila akan menggunakan template yang berbeda
###Handling Log File:
Logging dapat dilakukan console, file atau tabel
......@@ -81,14 +99,30 @@ Logging dapat dilakukan console, file atau tabel
[alembic]
sqlalchemy.url = postgresql://user:password@localhost:5432/db
script_location = alembic
```
###Google Integrated dan Custom Register Form
Aplikasi sudah bisa terintegrsi dengan google oauth2
Konfigurasi merupakan bagian dari "main"
```
[app:main]
allow_register = True
google-signin-client-id = id oauth2 client dari google
```
##Buat tabelnya::
Perintah untuk membuat tabel
Buat tabelnya::
$ ~/env/bin/initialize_opensipkd_db [file_config]
Contoh:
$ ~/env/bin/initialize_opensipkd_db ~/env/etc/test_opensipkd.ini
Jalankan::
##Jalankan::
$ ~/env/bin/pserve --reload test.ini
......@@ -168,25 +202,3 @@ Tambahkan blok berikut ini dibawah ini file
```
## Google Integrated dan Custom Register Form
Aplikasi sudah bisa terintegrsi dengan google oauth2
# Setting Configurasi
```
allow_register = True
google-signin-client-id = id oauth2 client dari google
register_form = # nama form buat registrasi default /register
```
# RML Reporting
Untuk aktivasi harus terdapat konfigurasi berikut ini
# Setting Configurasi
```
report_img = # fisik path default "opensipkd_base:static/img"
```
Install :
```
$pip install z3c.rml
```
......@@ -18,9 +18,11 @@ sqlalchemy.url = postgresql://user:password@server:port/db
pyramid.includes =
pyramid_tm
pyramid_beaker
pyramid_mailer
pyramid_chameleon
pyramid_rpc.jsonrpc
;Session Configuration
session.type = ext:database
session.secret = s0s3cr3t
session.cookie_expires = true
......@@ -30,38 +32,74 @@ session.timeout = 3000
session.lock_dir = %(here)s/tmp
timezone = Asia/Jakarta
# localization = id_ID.UTF-8
#localization = Indonesian_indonesia.1252
localization = English_Australia.1252
localization = id_ID.UTF-8
static_files = %(here)s/../files
captcha_files = %(here)s/tmp/captcha
company = Opensipkd
ibukota = Bekasi
departement = IT
address_1 = Jalan....
address_2 = Bekasi ...
center.phone = 021123456789
center.mobile = 081311045668
center.email = aa.gustiana@gmail.com
center.email_password =
center.smtp_server =
_host =
unoconv_py = C:\Program Files\LibreOffice 5\program\python.exe
unoconv_bin = C:\project\toko\env\Scripts\unoconv
# Static external file uploaded to the system
# Your Organisation Identity
company = Your Company
ibukota = Your City
departement = Your Departemen
address_1 = Your Address
address_2 = Your Address
;center.phone = 021123456789
;center.mobile = 081311045668
# Mail Configuration
mail.sender_name =
mail.username =
mail.host =
mail.port = 25
mail.password None SMTP password
mail.tls = False
mail.ssl=False
mail.keyfile =
#SSL key file
mail.certfile =
# SSL certificate file
mail.queue_path =
# Location of maildir
mail.default_sender =
# Default from address
mail.debug = 0
# SMTP debug level
# mail.sendmail_app = /usr/sbin/sendmail
# Sendmail executable
# mail.sendmail_template =
# {sendmail_app} -t -i -f {sender} Template for sendmail execution
mail.debug_include_bcc = False
# Include Bcc headers when Debugging
# ODT to pdf configuration
unoconv_py =
# openoffice/libreoffice python executable
unoconv_bin =
# Python unoconv script path "/home/[apps]/env/bin/unoconv"
#Modules depreceated
modules =
menus = /log:App-Log
app_name = Base Opensipkd.com
allow_register = False
# Menus to be appear in home page
menus = login:Login
log:App-Log
app_name = Your Aplocation Name
change_unit = False
departemen_chg_id = 3
# Register config parameter
allow_register = False
google-signin-client-id =
captcha_files=/home/aagusti/tmp
reg_captcha = 1
;reg_idcard = 1
reg_verify = 1
reg_form =
login_tpl =
;Digunakan Apabila Applikasi sebagai subdomain
;[app:main] diubah menjadi [app:opensipkd_base]
;[filter:proxy-prefix]
......
......@@ -2,7 +2,7 @@ import os
from setuptools import setup, find_packages
here = os.path.abspath(os.path.dirname(__file__))
with open(os.path.join(here, 'README.rst')) as f:
with open(os.path.join(here, 'README.md')) as f:
README = f.read()
with open(os.path.join(here, 'CHANGES.txt')) as f:
CHANGES = f.read()
......@@ -30,8 +30,11 @@ requires = [
'py3o.template',
'wheezy.captcha',
'icecream',
'google-api-python-client', 'google',
'opensipkd-tools @git+https://git.opensipkd.com/aa.gusti/opensipkd-tools.git'
'google-api-python-client',
'google',
'pyjwt',
'z3c.rml'
'opensipkd-tools @git+https://git.opensipkd.com/aa.gusti/opensipkd-tools.git',
]
dev_requires = [
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!