GithubHelp home page GithubHelp logo

xoopscube / xupdate Goto Github PK

View Code? Open in Web Editor NEW
13.0 16.0 7.0 3.31 MB

📦 X-Update Manager - GUI control panel to get and deploy modules, preloads and themes.

JavaScript 0.03% CSS 0.32% PHP 92.10% HTML 7.55%
php ftp curl updater manager deployment module theme gui-application dashboard

xupdate's Introduction

X-Updare Store XOOPSCube powered-by-electricity

DEV DESIGN

Project Status: Active – The project has reached a stable, usable state and is being actively developed. License GPL X-Update Manager

///// — X-Update Manager :: Software Update Service

alt text

MODULE X-Update Manager
Description Software Update Service to install new Add-ons, Modules and Themes for XCL Web Application Platform.
Render Engine Smarty v2 and XCube Layout
Version 2.40.0
Author Nobuhiro Yasutomi @nbuy XCL PHP8
Author Nuno Luciano @gigamaster XCL PHP7
Author @nao-pon @naao @kilica @hamaco
Copyright 2005-2024 Authors
License GPL
💻 The Minimum Requirements
      Apache, Nginx, etc.
      PHP 8.x.x with cURL extension
      MySQL 5.7, MariaDB  InnoDB utf8 / utf8mb4
      XCL version 2.4.0

X-Update Manager

X-update Manager is a software update service (SUS) with a user-friendly GUI to quickly extend and update your web app.
With the introduction of X-update, site administrators just need to log-in to the administration Control Panel to install or update modules, themes, libraries and preloads. X-update also provides support for language catalogs (localization) and multiple instances of D3 modules (duplicatable and directory free). In addition, you can manage your FTP/SSH credentials in the module preferences.
This module can download all critical updates and security patches to your server as soon as they become available. The deployment is as fast as possible by downloading archives from repositories such as GitHub or GitLab.

Features

  • Compatible modules and themes can be installed without a FTP client software.
  • The latest versions of supported modules and themes can be downloaded from Git servers.
  • User-friendly unzip, extract, and upload from X-Update Dashboard administration screen
  • Simple installation wizard for modules and themes.
  • Support for extensions and plugins, e.g. preloads.

Requirements

  • Folder used to download and extract archives.
    Specify a directory under (trust_path), without a "/" (slash) at the beginning and end.
    Or use the default "uploads/xupdate" with write permissions such as 707, 777.

📘 Documentation

For more information, see the module's built-in Help documentation.


xupdate's People

Contributors

aotake avatar argon358 avatar gigamaster avatar hamaco avatar kilica avatar mambax7 avatar naao avatar nao-pon avatar nunoluciano avatar orrisroot avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

xupdate's Issues

「使用言語ファイルのみ」 が有効でも language 以下の特定ディレクトリを配置対象する modules.ini 設定 が欲しい

X-update の一般設定に「使用言語ファイルのみ」がありますがこの設定を有効にすると、language ディレクトリは "english" と 使用言語のみ配置されます。

しかし、モジュールによっては、それ以外に特殊なディレクトリを配置したい場合もあると思います。

そこで、modules.ini の設定に "force_languages" を追加しようと思います。

force_languages = 'hoge, fuga'

のようにカンマ区切りで複数指定できます。

こんな感じで OK でしょうか。

Func.class.php :: safe_mode !=1

File
xupdate/class/Func.class.php

Line 135
Curl Followlocation should be "False" not "True"

$setopt4 = curl_setopt($ch, CURLOPT_FOLLOWLOCATION, FALSE);

////////////////////////////////////////

Server PHP Settings

Safe Mode : Off
Max. execution time : 30 sec.
Memory Limit : 128Mb
Display Errors : On
Short Open Tags : On
File Uploads : On ( Upload Max File Size:8M, Post Max Size:8M )
Magic Quotes : On
Register Globals : Off
Output Buffering : On
Open BaseDir : On
Allow url_fopen : On (recommended OFF)
Dom extension : Yes
Exif extension : Yes
Gettext extension : Yes
JSON extension : Yes
XML enabled : Yes
Curl extension : Yes
Zlib enabled : Yes
Soap extension : Yes
Mbstring enabled : Yes
Iconv available : Yes
GD extension : Yes
GD Version: 2.0 or higher
GD extension Image create Truecolor

詳細バージョン情報を、optionに追加

xpWikiなど、XOOPSのバージョン番号では入らない、5.0.13 の3桁目についても管理できるように、iniファイルに「detailed_version」を追加可能とし、 optionフィールドに、読み込み値と、インストールの際のの値を保存し表示する機能を追加する。
これを使って、XPressモジュールでは、wordpress本体のバージョンをこの詳細バージョン情報に付加することもできる。

依存関係にあるモジュールの紐付けインストール

あるモジュールが、別のモジュール等をライブラリとして要求する場合のために、依存関係の紐付け・通知があったほうが良いですね。  まずは紐付け・表示までとし、 一緒にインストールまでする処理もそのうち追加できればベスト。

erro and fix report from aqueitant

OSCに来場した方からご報告があったのでポストします。

MAMP 環境 xupdate で pico を入れようとしたら下記のようなエラーがでました。

-----ここから

PHP timeout

Download of the archive was started.
The completion of download.
Timeout by running time limit of PHP.
Deployment of the file to retrieve the archive from the [ link here ]
because it is incomplete, please do the proper placement of the FTP
upload files manually.
--------------------
PHP error message:

Fatal error: Call to undefined method
File_Archive_Reader_ChangeName::File_Archive_Reader_ChangeName() in
/Users/aotake/work/xoopsx-mysql/xoops_trust_path/modules/xupdate/PEAR/File/Archive/Reader/ChangeName/AddDirectory.php
on line 50

----- ここまで

PHP 5.3.2 だからかもしれませんが、以下の様にして解決しましたのでご連絡します。
単純に File_Archive_Reader_ChangeName のコンストラクタを付け足しただけです。

----ここから

diff --git a/xoops_trust_path/modules/xupdate/PEAR/File/Archive/Reader/ChangeName.php
b/xoops_trust_path/modules/xupdate/PEAR/File/Archive/Reader/ChangeName.php
index e01f1af..f0583b1 100644
--- a/xoops_trust_path/modules/xupdate/PEAR/File/Archive/Reader/ChangeName.php
+++ b/xoops_trust_path/modules/xupdate/PEAR/File/Archive/Reader/ChangeName.php
@@ -36,6 +36,10 @@ require_once "File/Archive/Reader/Relay.php";
 */
class File_Archive_Reader_ChangeName extends File_Archive_Reader_Relay
{
+    function File_Archive_Reader_ChangeName(&$source)
+    {
+        parent::File_Archive_Reader_Relay($source);
+    }
    /**
     * Modify the name
     *

-----ここまで

ストア設定iniファイルのキャッシュ化/並行ダウンロード

ストア設定iniファイルをGitHubに置くようにしたら、設定ファイル読み込みだけでかなり時間がかかる。
一度ダウンロードしたファイルはキャッシュしておき、更新はなんらかのトリガで行うように変更したい。
https://www.facebook.com/groups/313506525343887/permalink/467878456573359/

(nao-ponさんより)キャッシュは実装したほうがいいと思いますが、取得時のパフォーマンスアップとしては curl_multi_exec が使えるなら、HTTP fetch を並列処理することができます。
私のサイトの価格比較のあれで使ってます。私は http://hiyuzawa.jpn.org/blog/2007/02/php_curl_mycurlrequest.html このあたりを使わせてもらってますが、今はもっと新しいライブラリがあるかも。

Failed to extract the files

Might be useful to provide information to stores managers how to make 'universal archives'
... or maybe it's just a request with invalid archive urls !?

////////////////////////////////////////

Store with invalid zip archive (or links):

naao - GitHub
nao-pon - GitHub
Xoops X (Ten) - GitHub
xoops123 - GitHub

////////////////////////////////////////

Store with valid zip archive and successful installations :

xodomifara.lolipop.jp test

  • chalog (requires d3forum)
  • myckeditor (ok)
  • xugjmcdel (ok)

cmsthemefinder.com

  • load page, select theme and install (ok)

////////////////////////////////////////

Server PHP Settings
Safe Mode : Off
Max. execution time : 30 sec.
Memory Limit : 128Mb
Display Errors : On
Short Open Tags : On
File Uploads : On ( Upload Max File Size:8M, Post Max Size:8M )
Magic Quotes : On
Register Globals : Off
Output Buffering : On
Open BaseDir : On
Allow url_fopen : On (recommended OFF)
Dom extension : Yes
Exif extension : Yes
Gettext extension : Yes
JSON extension : Yes
XML enabled : Yes
Curl extension : Yes
Zlib enabled : Yes
Soap extension : Yes
Mbstring enabled : Yes
Iconv available : Yes
GD extension : Yes
GD Version: 2.0 or higher
GD extension Image create Truecolor

Notification

Request : Define how many times xupdate will show the 'Notification' on admin session.

Request : Block for new Admin Theme XCL 2.3

D3など複製可能モジュールをアンインストールした場合の挙動がおかしい

ref. https://www.facebook.com/groups/XoopsX/permalink/582141008480436/

予め名前を変えてD3モジュールをインストールしていて、
その後にX-updateを入れて管理し始めたのですが、
そのD3モジュールをアンインストールし、public及び
trustのフォルダも削除したところ、ストア一覧から消えずに
変更後のモジュール名が表示され、該当モジュールが
バージョンアップすると更新通知が来てしまいます。

_AD_XUPDATE_LANG_STORE が english/admin.php で定義されていない

_AD_XUPDATE_LANG_STORE が english/admin.php で定義されていないようです。

Add-on Store »» Module で以下のように出てしまいます。

required TrustModule _AD_XUPDATE_LANG_STORE:Xoops X (Ten) - GitHub
Protector is a module to defend your CMS origined from XOOPS2 from various and malicious attacks

name case mismatch

Fatal error: Call to a member function getConfigs() on a non-object in \trust_path\modules\xupdate\include\FtpModuleInstall.class.php on line 144

The $chandler in

$chandler = xoops_getHandler('config'); 

should be:

$cHandler```

Show the download link for manual. (for safemode user)

xupdate mkdir stop issue on CORESERVER

This hosting server's php.ini is "safe-mode ON".
Then we try a CGI-mode, but it doesn't show the view on x-update ctrl panel.

I found stop below.
$this->Ftp->localMkdir($dir);
$this->Ftp->localChmod($dir, 0707);

We can't do nothing more...
But, maybe we should add a link URL for who get a zip file manually.

install_only オプションの整理

"install_only "オプションで、 末尾にアスタリスク "*" を付加すると、インストール後のアップデート時にフォルダ内に当該ファイルが無くても配置しない、という仕様について、 分かり辛いので、 単独で使用可能なオプションを増やしたいです。 例えば、"no_complement" とか。

また、"install_only "オプションそのものも動作仕様が直観的でないので、 ソース内で変換しているように、 "no_overwrite" に変更したいです。

但し、いきなりiniファイルまで変更すると古いX-updateのユーザーがトラブルに陥るため、 まずはX-update本体のみに、 "no_overwrite" と "no_complement" オプション処理を追加しておき、 例えば半年後にX-updateのアップデートがいきわたった頃を見計らって、 iniファイルの更新を行う、という手順が良いと思います。
その後も、"install_only "オプションはレガシーオプションとして、deplicatedながら残すってことで。

https://www.facebook.com/pages/%E6%9D%B1%E4%BA%AC%E9%83%BD/110556885632390?ref=stream

upload_retry時に既に解凍済みのファイルを再利用する

とある鯖でlegacyのアップデートだけ何度やっても500エラーで落ちるので調べてみたところ、解凍処理で何かがオーバーフローしてるようだったので少し弄ってみました。
@912234972654ede340cfb6416affcd601f625d06

これで、upload_retryを2,3回繰り返すと何とか最後までたどり着くようになりました。

500エラーで落ちた場合にリトライするには、続けて実行した際に確認画面で(条件を満たせば)リトライ用のチェックボックスを付ける等しないといけませんね。

いささか無理やりな修正のような気もするのでそこまで仕上げてないし、プルリクもしていません。一応ライブラリの中を掘ってオーバーヘッドができるだけ小さくなるようにはしてます。

本当は、もっと小さな単位で個別にアップデートできるようになっていればいいようには思いますが、アーカイブを分けて用意するのは大変でしょうしね。

管理画面にアップデート情報を表示

(松本さん)

X-updateを表示しなくても、Wordpressのように管理画面のトップページに「○○の新しいバージョンがリリースされています。アップグレードする場合はここをクリック」」みたいな表示がでると、利用者に優しいかもしれませんね。

(酒井さん)

preloadで管理画面にnoticeする仕組みを作ればいいかもしれません。今のmailfile.phpが書き込み可能な場合の警告表示を利用してpreloadでそこの変数へセットする。というった感じです。

(沖野)

最新情報を取得するには、各ストアサーバーのiniファイルを取ってこないといけないので、他の画面表示の際にそれをやるとその画面表示が無意味に重くなってしまいます。
ダウンロードした設定ファイルで表示するしかないですけど、仕事をするのはwordpressと違ってコアではなくモジュールだからプリロードにする必要があり、色々考えるとドンピシャに旨くいく方法は難しい気がするんですよね。

Filtering by Category

action=ModuleStore の画面で、 xupdate_master で設定したカテゴリを使ってモジュールをフィルタできるようにしたい

xupdate のモジュール名編集で複製時にFatal

xupdate のモジュール名編集で xelFinder を複製してみたのですが、 xupdate をアンインストール&インストールしたら ModulesIniDadaSet.class.php の373行目あたりで Fatal error になりました。
複製した xelFinder を非アクティブにし、非アクティブの状態でもう一度 xupdate で複製したら直りました。原因はまだ探ってはいません。
(澤田さんより)

SSH-FTPで、鍵認証の実装

レンタルサーバーではなくて、VPSや専用サーバーなどroot権限をもったサーバー上にインストールする場合など、FTPやSSHのパスワード認証を設定せずに運用したい場合、SSH鍵認証でもxupdateを使えるようにしておきたい。
最終形は、 鍵をサーバーに保存せず使用時にクライアントPCの鍵情報を使用する、などがベスト。
暫定的には、鍵をサーバーに保存して使用後に削除する、ということで運用。

http://www.facebook.com/groups/313506525343887/permalink/457073684320503/

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.