Massive rename of path and DB entries in tempaltes and scripts (Ajaxplorer -> Pydio)

tags/0.2.0
Daniel Berteaud 11 years ago
parent 2d8966e9e6
commit 034f9fc680
  1. 10
      root/etc/cron.daily/pydio-indexer
  2. 4
      root/etc/e-smith/events/actions/pydio-user-rights
  3. 4
      root/etc/e-smith/templates/etc/pydio/bootstrap_repositories.php/050repo
  4. 16
      root/etc/e-smith/templates/var/lib/pydio/plugins/boot.conf/bootstrap.json/10All
  5. 16
      root/etc/e-smith/templates/var/lib/pydio/plugins/conf.serial/plugins_configs.ser/10All

@ -8,9 +8,9 @@ use File::stat;
my $c = esmith::ConfigDB->open_ro || die "Couldn't open ConfigDB\n"; my $c = esmith::ConfigDB->open_ro || die "Couldn't open ConfigDB\n";
my $a = esmith::AccountsDB->open_ro || die "Couldn't open AccountsDB\n"; my $a = esmith::AccountsDB->open_ro || die "Couldn't open AccountsDB\n";
my $ajaxplorer = $c->get('ajaxplorer') || die "ajaxplorer entry is missing in the configuration database\n"; my $pydio = $c->get('pydio') || die "pydio entry is missing in the configuration database\n";
my $status = $ajaxplorer->prop('status') || 'disabled'; my $status = $pydio->prop('status') || 'disabled';
my $indexer = $ajaxplorer->prop('Indexer') || 'enabled'; my $indexer = $pydio->prop('Indexer') || 'enabled';
exit(0) if ($status ne 'enabled' || $indexer ne 'enabled'); exit(0) if ($status ne 'enabled' || $indexer ne 'enabled');
@ -21,9 +21,9 @@ foreach (0..32){
$id .= $chars[rand @chars]; $id .= $chars[rand @chars];
} }
foreach my $share ($a->get_all_by_prop(type => 'share')){ foreach my $share ($a->get_all_by_prop(type => 'share')){
$ajaxplorer = $share->prop('Ajaxplorer') || 'disabled'; $pydio = $share->prop('Ajaxplorer') || 'disabled';
$indexer = $share->prop('AjaxplorerIndexer') || 'enabled'; $indexer = $share->prop('AjaxplorerIndexer') || 'enabled';
next if ($ajaxplorer ne 'enabled' || $indexer ne 'enabled'); next if ($pydio ne 'enabled' || $indexer ne 'enabled');
my $name = $share->key; my $name = $share->key;
# Check if the lock file is present and if it's too old (last index crashed ?) # Check if the lock file is present and if it's too old (last index crashed ?)
if (-e "/var/cache/pydio/indexes/.ajxp_lock-$name"){ if (-e "/var/cache/pydio/indexes/.ajxp_lock-$name"){

@ -99,8 +99,8 @@ foreach my $user (($a->users),$a->get('admin')){
close WROLE; close WROLE;
} }
my $ajxp = $c->get('ajaxplorer') || die "Couldn't find ajaxplorer entry in ConfigDB\n"; my $pydio = $c->get('pydio') || die "Couldn't find pydio entry in ConfigDB\n";
my $homedir = $ajxp->prop('HomeDir') || 'none'; my $homedir = $pydio->prop('HomeDir') || 'none';
if ($homedir eq 'enabled'){ if ($homedir eq 'enabled'){
foreach ($a->users){ foreach ($a->users){

@ -9,7 +9,7 @@ use esmith::AccountsDB;
my $a = esmith::AccountsDB->open_ro(); my $a = esmith::AccountsDB->open_ro();
my $homedir = $ajaxplorer{'HomeDir'} || 'none'; my $homedir = $pydio{'HomeDir'} || 'none';
if (($homedir eq 'enabled') || ($homedir eq 'users')){ if (($homedir eq 'enabled') || ($homedir eq 'users')){
$OUT .=<<"EOF"; $OUT .=<<"EOF";
@ -80,7 +80,7 @@ EOF
} }
if (($ajaxplorer{'PublicShares'} || 'enabled') eq 'enabled'){ if (($pydio{'PublicShares'} || 'enabled') eq 'enabled'){
$OUT .=<<'EOF'; $OUT .=<<'EOF';
$REPOSITORIES["ajxp_shared"] = array( $REPOSITORIES["ajxp_shared"] = array(

@ -1,10 +1,10 @@
{ {
use JSON; use JSON;
my $dbn = $ajaxplorer{'DbName'} || 'ajaxplorer'; my $dbn = $pydio{'DbName'} || 'pydio';
my $dbu = $ajaxplorer{'DbUser'} || 'ajaxplorer'; my $dbu = $pydio{'DbUser'} || 'pydio';
my $dbp = $ajaxplorer{'DbPassword'} || 'secret'; my $dbp = $pydio{'DbPassword'} || 'secret';
my $url = $ajaxplorer{'LogoutUrl'} || ''; my $url = $pydio{'LogoutUrl'} || '';
my $data = { my $data = {
'core.conf' => { 'core.conf' => {
@ -20,11 +20,11 @@ my $data = {
}, },
'UNIQUE_INSTANCE_CONFIG' => { 'UNIQUE_INSTANCE_CONFIG' => {
'FAST_CHECKS' => JSON::true, 'FAST_CHECKS' => JSON::true,
'ROLES_FILEPATH' => '/var/lib/ajaxplorer/plugins/auth.serial/roles.ser', 'ROLES_FILEPATH' => '/var/lib/pydio/plugins/auth.serial/roles.ser',
'USERS_DIRPATH' => '/var/lib/ajaxplorer/plugins/auth.serial', 'USERS_DIRPATH' => '/var/lib/pydio/plugins/auth.serial',
'instance_name' => 'conf.serial', 'instance_name' => 'conf.serial',
'group_switch_value' => 'conf.serial', 'group_switch_value' => 'conf.serial',
'REPOSITORIES_FILEPATH' => '/var/lib/ajaxplorer/plugins/conf.serial/repo.ser' 'REPOSITORIES_FILEPATH' => '/var/lib/pydio/plugins/conf.serial/repo.ser'
}, },
'USER_CREATE_REPOSITORY' => JSON::false, 'USER_CREATE_REPOSITORY' => JSON::false,
'SAVE_GUEST_PREFERENCES' => JSON::false, 'SAVE_GUEST_PREFERENCES' => JSON::false,
@ -41,7 +41,7 @@ my $data = {
'TRANSMIT_CLEAR_PASS' => JSON::true, 'TRANSMIT_CLEAR_PASS' => JSON::true,
'AUTOCREATE_AJXPUSER' => JSON::false, 'AUTOCREATE_AJXPUSER' => JSON::false,
'group_switch_value' => 'auth.basic_http', 'group_switch_value' => 'auth.basic_http',
'USERS_FILEPATH' => '/var/lib/ajaxplorer/plugins/auth.serial/users.ser' 'USERS_FILEPATH' => '/var/lib/pydio/plugins/auth.serial/users.ser'
}, },
'SLAVE_INSTANCE_CONFIG_group_switch' => '', 'SLAVE_INSTANCE_CONFIG_group_switch' => '',
'SLAVE_INSTANCE_CONFIG' => [], 'SLAVE_INSTANCE_CONFIG' => [],

@ -4,23 +4,23 @@ my $data;
$data->{'core.uploader'}->{'UPLOAD_MAX_SIZE'} = "0"; $data->{'core.uploader'}->{'UPLOAD_MAX_SIZE'} = "0";
$data->{'core.uploader'}->{'UPLOAD_MAX_NUMBER'} = "50"; $data->{'core.uploader'}->{'UPLOAD_MAX_NUMBER'} = "50";
$data->{'gui.ajax'}->{'CUSTOM_WELCOME_MESSAGE'} = $ajaxplorer{'WelcomMessage'} || 'Ajaxplorer'; $data->{'gui.ajax'}->{'CUSTOM_WELCOME_MESSAGE'} = $pydio{'WelcomMessage'} || 'Pydio';
$data->{'core.ajaxplorer'}->{'WEBMASTER_EMAIL'} = 'admin@'.$DomainName; $data->{'core.ajaxplorer'}->{'WEBMASTER_EMAIL'} = 'admin@'.$DomainName;
$data->{'core.ajaxplorer'}->{'AJXP_TMP_DIR'} = '/var/lib/ajaxplorer/tmp'; $data->{'core.ajaxplorer'}->{'AJXP_TMP_DIR'} = '/var/lib/pydio/tmp';
$data->{'core.ajaxplorer'}->{'DEFAULT_LANGUAGE'} = $ajaxplorer{'DefaultLanguage'} || 'en'; $data->{'core.ajaxplorer'}->{'DEFAULT_LANGUAGE'} = $pydio{'DefaultLanguage'} || 'en';
$data->{'core.ajaxplorer'}->{'APPLICATION_TITLE'} = $ajaxplorer{'Title'} || 'Ajaxplorer'; $data->{'core.ajaxplorer'}->{'APPLICATION_TITLE'} = $pydio{'Title'} || 'Pydio';
$data->{'core.ajaxplorer'}->{'CMDLINE_ACTIVE'} = '__true__'; $data->{'core.ajaxplorer'}->{'CMDLINE_ACTIVE'} = '__true__';
$data->{'core.ajaxplorer'}->{'CLI_PHP'} = '/usr/bin/php'; $data->{'core.ajaxplorer'}->{'CLI_PHP'} = '/usr/bin/php';
if (($ajaxplorer{'PublicShares'} || 'enabled') eq 'enabled'){ if (($pydio{'PublicShares'} || 'enabled') eq 'enabled'){
$data->{'core.ajaxplorer'}->{'PUBLIC_DOWNLOAD_FOLDER'} = '/var/lib/ajaxplorer/public'; $data->{'core.ajaxplorer'}->{'PUBLIC_DOWNLOAD_FOLDER'} = '/var/lib/pydio/public';
$data->{'core.ajaxplorer'}->{'PUBLIC_DOWNLOAD_URL'} = $ajaxplorer{'PublicDownloadUrl'} || "http://$SystemName.$DomainName/ajxppub"; $data->{'core.ajaxplorer'}->{'PUBLIC_DOWNLOAD_URL'} = $pydio{'PublicDownloadUrl'} || "http://$SystemName.$DomainName/ajxppub";
} }
$data->{'core.log'} = { $data->{'core.log'} = {
'UNIQUE_PLUGIN_INSTANCE' => { 'UNIQUE_PLUGIN_INSTANCE' => {
'LOG_FILE_NAME' => 'log_date(\'m-d-y\').txt', 'LOG_FILE_NAME' => 'log_date(\'m-d-y\').txt',
'LOG_PATH' => '/var/log/ajaxplorer/', 'LOG_PATH' => '/var/log/pydio/',
'instance_name' => 'log.text', 'instance_name' => 'log.text',
'group_switch_value' => 'log.text', 'group_switch_value' => 'log.text',
'LOG_CHMOD' => 770 'LOG_CHMOD' => 770

Loading…
Cancel
Save