websites.concatenative: change DB path
parent
ddd589cdee
commit
8f44a059f5
|
@ -1,7 +1,8 @@
|
||||||
! Copyright (C) 2010 Slava Pestov.
|
! Copyright (C) 2010 Slava Pestov.
|
||||||
! See http://factorcode.org/license.txt for BSD license.
|
! See http://factorcode.org/license.txt for BSD license.
|
||||||
USING: accessors calendar db db.sqlite db.tuples db.types kernel
|
USING: accessors calendar db db.sqlite db.tuples db.types kernel
|
||||||
math math.order sequences combinators.short-circuit ;
|
math math.order sequences combinators.short-circuit
|
||||||
|
io.pathnames ;
|
||||||
IN: webapps.mason.backend
|
IN: webapps.mason.backend
|
||||||
|
|
||||||
CONSTANT: +idle+ "idle"
|
CONSTANT: +idle+ "idle"
|
||||||
|
@ -72,7 +73,7 @@ counter "COUNTER" {
|
||||||
: os/cpu ( builder -- string )
|
: os/cpu ( builder -- string )
|
||||||
[ os>> ] [ cpu>> ] bi "/" glue ;
|
[ os>> ] [ cpu>> ] bi "/" glue ;
|
||||||
|
|
||||||
: mason-db ( -- db ) "resource:mason.db" <sqlite-db> ;
|
: mason-db ( -- db ) home "mason.db" append-path <sqlite-db> ;
|
||||||
|
|
||||||
: with-mason-db ( quot -- )
|
: with-mason-db ( quot -- )
|
||||||
mason-db [ with-transaction ] with-db ; inline
|
mason-db [ with-transaction ] with-db ; inline
|
||||||
|
|
|
@ -30,12 +30,12 @@ webapps.mason.backend
|
||||||
websites.factorcode ;
|
websites.factorcode ;
|
||||||
IN: websites.concatenative
|
IN: websites.concatenative
|
||||||
|
|
||||||
: test-db ( -- db ) "resource:test.db" <sqlite-db> ;
|
: website-db ( -- db ) home "website.db" append-path <sqlite-db> ;
|
||||||
|
|
||||||
: init-factor-db ( -- )
|
: init-factor-db ( -- )
|
||||||
mason-db [ init-mason-db ] with-db
|
mason-db [ init-mason-db ] with-db
|
||||||
|
|
||||||
test-db [
|
website-db [
|
||||||
init-furnace-tables
|
init-furnace-tables
|
||||||
|
|
||||||
{
|
{
|
||||||
|
@ -92,7 +92,7 @@ SYMBOLS: key-password key-file dh-file ;
|
||||||
<planet> <login-config> <factor-boilerplate> "planet" add-responder
|
<planet> <login-config> <factor-boilerplate> "planet" add-responder
|
||||||
<mason-app> <login-config> <factor-boilerplate> "mason" add-responder
|
<mason-app> <login-config> <factor-boilerplate> "mason" add-responder
|
||||||
"/tmp/docs/" <help-webapp> "docs" add-responder
|
"/tmp/docs/" <help-webapp> "docs" add-responder
|
||||||
test-db <alloy>
|
website-db <alloy>
|
||||||
main-responder set-global ;
|
main-responder set-global ;
|
||||||
|
|
||||||
: <gitweb> ( path -- responder )
|
: <gitweb> ( path -- responder )
|
||||||
|
@ -106,10 +106,10 @@ SYMBOLS: key-password key-file dh-file ;
|
||||||
<concatenative-website>
|
<concatenative-website>
|
||||||
<wiki> "wiki" add-responder
|
<wiki> "wiki" add-responder
|
||||||
<user-admin> "user-admin" add-responder
|
<user-admin> "user-admin" add-responder
|
||||||
<login-config> <factor-boilerplate> test-db <alloy> "concatenative.org" add-responder
|
<login-config> <factor-boilerplate> website-db <alloy> "concatenative.org" add-responder
|
||||||
<pastebin> <factor-recaptcha> <login-config> <factor-boilerplate> test-db <alloy> "paste.factorcode.org" add-responder
|
<pastebin> <factor-recaptcha> <login-config> <factor-boilerplate> website-db <alloy> "paste.factorcode.org" add-responder
|
||||||
<planet> <login-config> <factor-boilerplate> test-db <alloy> "planet.factorcode.org" add-responder
|
<planet> <login-config> <factor-boilerplate> website-db <alloy> "planet.factorcode.org" add-responder
|
||||||
<mason-app> <login-config> <factor-boilerplate> test-db <alloy> "builds.factorcode.org" add-responder
|
<mason-app> <login-config> <factor-boilerplate> website-db <alloy> "builds.factorcode.org" add-responder
|
||||||
home "docs" append-path <help-webapp> "docs.factorcode.org" add-responder
|
home "docs" append-path <help-webapp> "docs.factorcode.org" add-responder
|
||||||
home "cgi" append-path <gitweb> "gitweb.factorcode.org" add-responder
|
home "cgi" append-path <gitweb> "gitweb.factorcode.org" add-responder
|
||||||
main-responder set-global ;
|
main-responder set-global ;
|
||||||
|
@ -127,7 +127,7 @@ SYMBOLS: key-password key-file dh-file ;
|
||||||
8431 >>secure ;
|
8431 >>secure ;
|
||||||
|
|
||||||
: start-website ( -- server )
|
: start-website ( -- server )
|
||||||
test-db start-expiring
|
website-db start-expiring
|
||||||
test-db start-update-task
|
website-db start-update-task
|
||||||
http-insomniac
|
http-insomniac
|
||||||
<concatenative-website-server> start-server ;
|
<concatenative-website-server> start-server ;
|
||||||
|
|
Loading…
Reference in New Issue