wbbaddons / tims-packageserver Goto Github PK
View Code? Open in Web Editor NEWLightweight Package Server for WoltLab Community Framework
Home Page: https://tims.bastelstu.be
License: GNU Affero General Public License v3.0
Lightweight Package Server for WoltLab Community Framework
Home Page: https://tims.bastelstu.be
License: GNU Affero General Public License v3.0
No one sane wants to run this as root.
When using the Docker container, I get the below. Am I doing something wrong here, or is the mentioned module out of date and causing the issue all by itself?
npm info using [email protected]
npm info using [email protected]
npm info lifecycle [email protected]~prestart: [email protected]
npm info lifecycle [email protected]~start: [email protected]
> [email protected] start /usr/src/app
> coffee app.coffee
Error: The module '/usr/src/app/node_modules/node-expat/build/Release/node_expat.node'
was compiled against a different Node.js version using
NODE_MODULE_VERSION 46. This version of Node.js requires
NODE_MODULE_VERSION 51. Please try re-compiling or re-installing
the module (for instance, using `npm rebuild` or`npm install`).
at Object.Module._extensions..node (module.js:600:18)
at Module.load (/usr/src/app/node_modules/coffee-script/lib/coffee-script/register.js:45:36)
at tryModuleLoad (module.js:449:12)
at Function.Module._load (module.js:441:3)
at Module.require (module.js:500:17)
at require (internal/module.js:20:19)
at bindings (/usr/src/app/node_modules/bindings/bindings.js:76:44)
at Object.<anonymous> (/usr/src/app/node_modules/node-expat/lib/node-expat.js:4:32)
at Module._compile (module.js:573:32)
at Object.Module._extensions..js (module.js:582:10)
at Module.load (/usr/src/app/node_modules/coffee-script/lib/coffee-script/register.js:45:36)
at tryModuleLoad (module.js:449:12)
at Function.Module._load (module.js:441:3)
at Module.require (module.js:500:17)
at require (internal/module.js:20:19)
at Object.<anonymous> (/usr/src/app/node_modules/xml-stream/lib/xml-stream.js:2:22)
at Module._compile (module.js:573:32)
at Object.Module._extensions..js (module.js:582:10)
at Module.load (/usr/src/app/node_modules/coffee-script/lib/coffee-script/register.js:45:36)
at tryModuleLoad (module.js:449:12)
at Function.Module._load (module.js:441:3)
at Module.require (module.js:500:17)
at require (internal/module.js:20:19)
at Object.<anonymous> (/usr/src/app/node_modules/xml-stream/index.js:1:80)
at Module._compile (module.js:573:32)
at Object.Module._extensions..js (module.js:582:10)
at Module.load (/usr/src/app/node_modules/coffee-script/lib/coffee-script/register.js:45:36)
at tryModuleLoad (module.js:449:12)
at Function.Module._load (module.js:441:3)
at Module.require (module.js:500:17)
at require (internal/module.js:20:19)
at Object.<anonymous> (/usr/src/app/packageListReader.coffee:25:13)
at Object.<anonymous> (/usr/src/app/packageListReader.coffee:1:1)
at Module._compile (module.js:573:32)
at Object.loadFile (/usr/src/app/node_modules/coffee-script/lib/coffee-script/register.js:16:19)
at Module.load (/usr/src/app/node_modules/coffee-script/lib/coffee-script/register.js:45:36)
at tryModuleLoad (module.js:449:12)
at Function.Module._load (module.js:441:3)
at Module.require (module.js:500:17)
at require (internal/module.js:20:19)
at Object.<anonymous> (/usr/src/app/app.coffee:26:21)
at Object.<anonymous> (/usr/src/app/app.coffee:1:1)
at Module._compile (module.js:573:32)
at Object.exports.run (/usr/src/app/node_modules/coffee-script/lib/coffee-script/coffee-script.js:162:23)
at compileScript (/usr/src/app/node_modules/coffee-script/lib/coffee-script/command.js:224:29)
at compilePath (/usr/src/app/node_modules/coffee-script/lib/coffee-script/command.js:174:14)
at Object.exports.run (/usr/src/app/node_modules/coffee-script/lib/coffee-script/command.js:98:20)
at Object.<anonymous> (/usr/src/app/node_modules/coffee-script/bin/coffee:7:41)
at Module._compile (module.js:573:32)
at Object.Module._extensions..js (module.js:582:10)
at Module.load (module.js:490:32)
at tryModuleLoad (module.js:449:12)
at Function.Module._load (module.js:441:3)
at Module.runMain (module.js:607:10)
at run (bootstrap_node.js:382:7)
at startup (bootstrap_node.js:137:9)
at bootstrap_node.js:497:3
npm info lifecycle [email protected]~start: Failed to exec start script
npm ERR! Linux 4.4.0-45-generic
npm ERR! argv "/usr/local/bin/node" "/usr/local/bin/npm" "start"
npm ERR! node v7.0.0
npm ERR! npm v3.10.8
npm ERR! code ELIFECYCLE
npm ERR! [email protected] start: `coffee app.coffee`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] start script 'coffee app.coffee'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the tims-packageserver package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! coffee app.coffee
npm ERR! You can get information on how to open an issue for this project with:
npm ERR! npm bugs tims-packageserver
npm ERR! Or if that isn't available, you can get their info via:
npm ERR! npm owner ls tims-packageserver
npm ERR! There is likely additional logging output above.
npm ERR! Please include the following file with any support request:
npm ERR! /usr/src/app/npm-debug.log
Yes, the title says everything. In the Browser (behind a reverse proxy) i get the following error: Unsafe attempt to load URL on://package.herrtxbias.net/style/main.xslt from frame with URL https://package.herrtxbias.net/. Domains, protocols and ports must match.
And when i try to load it directly (http://fra1.server.herrtxbias.me:9001/) i'm getting back, that there are no packages, which is wrong, because i've added one project, like in the tutorial. If somebody has any ideas, just let me know!
I just set up the package server but it keeps throwing the error below:
Invalid salt. Salt must be in the form of: $Vers$log2(NumRounds)$saltvalue
I tried with *
and $v > 1.0.0
but the error stays the same.
{
"users": {
"admin": {
"passwd": "asdklawjido",
"groups": [ "Administrator" ],
"packages": {
}
}
},
"groups": {
"Administrator": {
"*": "*"
}
}
}
Hey,
when trying to update a package which has a new requirement, WoltLab throws the error Cannot find package
while the required package is included in the uploaded package in the package server.
Manually uploading the same package file works without an error.
Hey,
I was trying to install the docker image on a new server and was no longer able to get it to work.
curl -I http://localhost:9001
just returns HTTP/1.1 405 Method Not Allowed
and docker logs doesn't show anything, so not sure how to troubleshoot this further without any log results.
Installation process:
git clone https://github.com/wbbaddons/Tims-PackageServer.git
cd Tims-PackageServer/
docker-compose up --build -d
curl -I http://localhost:9001
Tims-PackageServer/docker-compose.yaml
version: "3"
services:
packageserver:
build: .
restart: always
ports:
- "9001:9001"
environment:
DEBUG: "PackageServer:*"
volumes:
- /srv/docker/packageserver/packages:/var/lib/PackageServer/packages
I have tested your package server and found until now no errors except for one little thing.
The information at the end of the output looks like this:
This list was presented by Tims Package Server 1.0.0 <https://github.com/wbbaddons/Tims-PackageServer>
I think that the correct output should be:
This list was presented by Tims Package Server 1.0.0 <https://github.com/wbbaddons/Tims-PackageServer>
Hey,
ich benutze die Docker version von dem Package Server, ich bekomme auch alle Packages angezeigt, jedoch wenn Woltlab versucht, die Pakete zu laden, kommt nur ein Fehler:
Beim letzten Verbindungsversuch trat folgender Fehler auf: Die Paketliste konnte nicht abgerufen werden (0)
Irgendeine Idee?
npm start
[email protected] prestart /XXX/Tims-PackageServer
npm install
npm WARN package.json [email protected] No repository field.
[email protected] start /XXX/Tims-PackageServer
coffee app.coffee
info: Using config '/XXX/Tims-PackageServer/config.js'
info: Starting update
warning: /XXX/Tims-PackageServer/packages/de.stricted.ldap/latest is missing
info: Finished update
notice: Updated auth
watching the path /XXX/Tims-PackageServer/packages/ failed with error { [Error: ENOENT, stat '/XXX/Tims-PackageServer/packages/de.stricted.ldap/latest']
errno: 34,
code: 'ENOENT',
path: '/XXX/Tims-PackageServer/packages/de.stricted.ldap/latest' }
watching the path /XXX/Tims-PackageServer/packages/ failed with error { [Error: ENOENT, stat '/XXX/Tims-PackageServer/packages/de.stricted.ldap/latest']
errno: 34,
code: 'ENOENT',
path: '/XXX/Tims-PackageServer/packages/de.stricted.ldap/latest' }
In the tar reading code the file descriptor seems to be leaked (when the file is no real tar).
Nginx:
server {
listen 80;
listen 443 ssl;
ssl_certificate /etc/letsencrypt/live/update.wsc-connect.com/fullchain.pem;
ssl_certificate_key /etc/letsencrypt/live/update.wsc-connect.com/privkey.pem;
server_name update.wsc-connect.com;
location / {
proxy_pass http://localhost:9001;
proxy_pass_header Server;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection 'upgrade';
proxy_set_header Host $host;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_cache_bypass $http_upgrade;
}
}
npm start --ssl=true
works for the http server, but the https server links the stylesheet to http://update.wsc-connect.com/style/main.xslt, so https://update.wsc-connect.com/ yields an error in the developer console.
How to fix that?
The requiredpackage
entries are getting split on uppercase letters for some reason, causing the updating via the package server to error out with invalid requirements.
The package.xml in the plugin:
<requiredpackages>
<requiredpackage minversion="5.2.0 RC 1">com.woltlab.wcf</requiredpackage>
<requiredpackage minversion="5.2.0 RC 1">com.woltlab.wbb</requiredpackage>
<requiredpackage minversion="5.2.0 RC 1">com.woltlab.wcf.conversation</requiredpackage>
<requiredpackage minversion="5.2.0">com.cls-design.wcf.layoutExpansionKit</requiredpackage>
</requiredpackages>
The resulting output from the Package Server:
<requiredpackages>
<requiredpackage minversion="5.2.0 RC 1">com.woltlab.wcf</requiredpackage>
<requiredpackage minversion="5.2.0 RC 1">com.woltlab.wbb</requiredpackage>
<requiredpackage minversion="5.2.0 RC 1">com.woltlab.wcf.conversation</requiredpackage>
<requiredpackage minversion="5.2.0">com.cls-design.wcf.layout</requiredpackage>
<requiredpackage minversion="5.2.0">ExpansionKit</requiredpackage>
</requiredpackages>
Hey,
it would be great if gzip packages with the endings tar.gz
and .tgz
would be supported.
Obviously, your package server is only evaluting the first package name/description entry in package.xml, which usually is in English.
Helpful would be to consider those with language attribute as well.
You recently deprecated setting the basePath
variable in the config file and recommended to rather configure a reverse proxy to add a proper host header.
This creates problems when not running on the root of your domain, e.g.
http://example.com/package-server/
By only using the host header and ignoring the base path (/package-server/
), the server creates wrong URLs for his own resources and back links, rendering it disfunctional.
?packageName=be.bastelstu.wcf.qr&packageName=be.bastelstu.wcf.signer redirects to /be.bastelstu.wcf.qr,be.bastelstu.wcf.signer
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.