rejetto forum

Software => HFS ~ HTTP File Server => Topic started by: ledufe on August 13, 2007, 06:01:51 AM

Title: just a idea
Post by: ledufe on August 13, 2007, 06:01:51 AM
let me try to explain what i thinked some days ago, i was using some card-printer, that has a bug, and from time to time i must execute some commands, but i dont need to bo there, or even logon remotly to make it, i create a batch that is executed from times to time

so i thinked this
hfs has a login system, right?
hfs allow upload for certain folders and for the right users(if configured to do it, of course) right?

so if in my vfs i put a upload folder, password protected
i upload a file with some commands on it like admin-cmd.bat
and at my hfs machine there is a app that is monitoring that particular folder, looking for a particular filename, in a timed check(at every minute, or every second...) defined by me(the user)
and the command file(the batch) is executed, and then after finished the execution, it will be deleted, and the app will keep the monitoring drill, until got another upload to execute again

would that be cool?
imagine
since we can upload templates
and we can upload ini files
we gain some new cool ways to interact with the hfs
imagine i upload a hfs.ini file with some "templatename.tpl" defined on it
i upload the second file the template, with the name as it is inside the hfs.ini
and then i upload a batch to call the ini, with the template info on it, and BUM i changed my template remotly....
got it?
there must be some other cool uses to it, but be aware, that if you use this app to monitore and look for a file called some-stupidname.bat and inside it there is a command to kill your pc, it is your fall
since you can protect the folder, with password
and only you will know the name of the file that the monitor is expecting


well
i will try to improve the app, but now i wanna know, if someone here like the idea, im using it, and i will improove it and his usage....

status = working
todo = many things... any suggestions?
Title: Re: just a idea
Post by: ledufe on August 13, 2007, 06:11:46 AM
just another ideas

can we get some new commands "command line Type" ?
like:
add user
delete folder from vfs
add folder to vfs from disk, and at some vfs point
....
many ideas.... i must stop smoking, im getting more ideas that i can write....hauhauahuaha
sorry guys, im just becoming nutz......
 and by the way here some shots of the app of this post
Title: Re: just a idea
Post by: Foggy on August 13, 2007, 11:06:24 AM
I liked that idea so much that I created a batch file that will do the exact same thing as your app. It has lots of room for improvement but it will get the job done. :D

If anyone interested here is the code of the batch file I created
Code: [Select]
@echo off
echo Where is the script?
set /p script=
set tally=0
:1
ping -n 20 127.0.0.1>>"rubbish.txt"
if exist "%script%" (goto 2) else goto 1
:2
Echo %date% %Time% Script Detected
call "%script%"
Echo %date% %Time% Script Executed
Del "%script%"
Echo %Date% %Time% Script Deleted
set /A tally=%tally%+1
Echo %tally% Scripts Have Been Executed
goto 1
Title: Re: just a idea
Post by: ledufe on August 13, 2007, 01:56:06 PM
ok, now it is official, this idea, is useful, and dangerous:

the hfs must have a upload folder
it is imperative to have a password protection to this upload folder

i guess that this would not be a easy solution to most of people, but until we got some web/remote admin/control of the hfs, this would help or even do part of the job....

hey foggy, now, we can start to post some exemples of good use of it here.
 
i will post a few here at night, now i am at work....

and im happy that someone like the idea....
bye for now
Title: Re: just a idea
Post by: radd on August 13, 2007, 04:31:56 PM
i like the idea too but sorry to say i dont think i can contribute anything other than idea because i dont know anything about script, command blabla.. i understand what u guys trying to do, i know the important of it. hopefully i can learn many many things here.

my 1st idea - why dont u try to stop smoke? u know its very bad for health, dont u?  ;D
Title: Re: just a idea
Post by: TCube on August 13, 2007, 06:37:48 PM
Ledufe,

Great enhancements for Hfs Administrators that's for sure !

Would u trust anyone else as "users" handling such fonctions ?  maybe yes and maybe not ... 
In positive rĂ©ponse that's would lead to  "WorkGroups" handling their own business with no interference from the Administrator ...

That's damn interesting my friend  :D

Tcube
Title: Re: just a idea
Post by: Giant Eagle on August 13, 2007, 07:00:30 PM
I was experimenting with this aswell some while ago ^^ and i must say it really is a nice feature.

I was able to remotely create folders, automatically unrar archived files upon upload and also execute .bat files. Just never got the time to finish it.
Title: Re: just a idea
Post by: rejetto on August 13, 2007, 10:44:28 PM
yes, it's a nice idea.
it depends on your needs.
my needs are better suited by VNC.
Title: Re: just a idea
Post by: Unknown8063 on August 16, 2007, 05:08:56 PM
I've had some free time at work and decided to experiment a little about remote HFS administration.  I don't really like the idea of a program scanning for changes on my filesystem and capable of executing arbritrary commands so I decided to try making a php application which runs on a seperate server on the same machine.  Right now it's little more than a proof of concept, a few jumbled php functions but here is a simple web form that can remotely change the template used on the HFS server.

Here is the proof of concept for the PHP Administration: http://bluhelix.homeip.net:88/hfs/

Sorry about the read-only text box, but I decided against allowing people to upload their own templates and limited it to just three.  I don't know why images aren't loading on the HFS site but they work fine if I connect directly via localhost.

Anyway, I wanted to throw this out there to see how many people would be interested in something like this and also any ideas for "must have" features.

Important Note: you may have to refresh the pages or risk being served a cached page.
Title: Re: just a idea
Post by: radd on August 16, 2007, 06:32:40 PM
if we can have admin tools in form like this, should be very good.
but can we have many2 more function like; control user account, managing vfs, upload/archive permission,

if possible also, i would be very apreciate if we can have a look at each connection (see ip) to the server as what should be listed in hfs gui, and then we can kick connection... etc. log section i dont think its important to have here.

try to have as many function as hfs provide, but for begining i think vfs and user management should be look into.

i can see this project going to be a great tools, and i will definitely be one of the fan, since i will be going far far away from my beloved pc not long left. really hope i can help something. good luck guys!!
Title: Re: just a idea
Post by: OGWATERMELON on August 17, 2007, 10:50:57 AM
I agree that admin tools are a vital part of taking care of your server.  But I travel at least 6 months out of the year.  I use UltraVNC to check logs and do maintenance on the server.  You can set up a secure connection and access it all around the world.  It is easier in my opinion to do it this way.  Not that your ideas are not good.
Title: Re: just a idea
Post by: radd on August 17, 2007, 12:07:11 PM
sorry if this is dumb question but i really donno abaout vnc. i want to ask, do we need to install vnc in computer that we use to access our computer remotely? if we need to install, it might not be a good choice if we use school/work computer. if not, i will try this soon. its free isn it?
Title: Re: just a idea
Post by: rejetto on August 17, 2007, 12:20:29 PM
No. UltraVNC offers a web based interface, through a java applet.
Title: Re: just a idea
Post by: Foggy on August 17, 2007, 02:10:48 PM
There is many free VNC Clients availiable.

I think that this is a very good idea but it would be better/ easier to use VNC to manage the server from a remote location. But having said that I still think that it can be very useful. I can thtink of a couple ways that I think this method would be better then VNC.

1. If rejetto includes some commands for hfs to add/remove users we could create a user registration system, with a seperate php server like what Unknown8063 has created to upload the user/pass into a batch file.

2. Say we let a friend or someone else we know host some files on our HFS, we arnt going to just let them VNC into our computer are we? They could change the template and other VFS settings using this method.

3. Im quite tired your lucky i could think of two ;)


Title: Re: just a idea
Post by: Unknown8063 on August 17, 2007, 05:02:40 PM
I agree that admin tools are a vital part of taking care of your server.  But I travel at least 6 months out of the year.  I use UltraVNC to check logs and do maintenance on the server.  You can set up a secure connection and access it all around the world.  It is easier in my opinion to do it this way.  Not that your ideas are not good.

Right.  I actually ran my HFS server from home while living on campus at college last year.  I regularly used RealVNC to administer the server and it worked well.  The primary drawback to this method is that it can be unstable on bad network connections - the images update slowly, frequent disconnects, etc.

Anyway, I am mostly experimenting.  I agree with Foggy that perhaps the most useful function would be to allow user registration.
Title: Re: just a idea
Post by: rejetto on August 17, 2007, 05:37:52 PM
do you know user registration alone will not give any right to the user?

you must always give access for folders to the account.
Title: Re: just a idea
Post by: MarkV on August 17, 2007, 11:36:57 PM
Why not let the HFS admin define some 'defaults' any new user gets assigned first, like a user template (a pre-configured user profile with defined permissions)?

Or even better, create a home directory for the user after successful registration.
Title: Re: just a idea
Post by: rejetto on August 18, 2007, 09:19:56 AM
it may be a special account
restrict access -> @new registered
that gives access after registration.
or @every account
to let everyone who has an accont
Title: Re: just a idea
Post by: TCube on August 18, 2007, 05:59:36 PM
Here is the proof of concept for the PHP Administration: http://bluhelix.homeip.net:88/hfs/

Sorry about the read-only text box, but I decided against allowing people to upload their own templates and limited it to just three.  I don't know why images aren't loading on the HFS site but they work fine if I connect directly via localhost.Anyway, I wanted to throw this out there to see how many people would be interested in something like this and also any ideas for "must have" features.

It just hit me with your example : instead of changing form  [template1/template2/ etc.] you could switch to different languages within the same form [Damn Template English / Damn Template Portugese/ Damn Template Italien / ... French... etc.]
Ever thought of this ?

Tcube
Title: Re: just a idea
Post by: MarkV on August 18, 2007, 06:25:46 PM
it may be a special account
restrict access -> @new registered
that gives access after registration.
or @every account
to let everyone who has an accont

I'd like the @New registered better, because you may want to assign totally different permissions later.
Title: Re: just a idea
Post by: Unknown8063 on August 18, 2007, 09:55:07 PM
Here is the proof of concept for the PHP Administration: http://bluhelix.homeip.net:88/hfs/

Sorry about the read-only text box, but I decided against allowing people to upload their own templates and limited it to just three.  I don't know why images aren't loading on the HFS site but they work fine if I connect directly via localhost.Anyway, I wanted to throw this out there to see how many people would be interested in something like this and also any ideas for "must have" features.

It just hit me with your example : instead of changing form  [template1/template2/ etc.] you could switch to different languages within the same form [Damn Template English / Damn Template Portugese/ Damn Template Italien / ... French... etc.]
Ever thought of this ?

Tcube

The trouble is that using the ini route to change templates mean the change is global and experienced by all users.
Title: Re: just a idea
Post by: radd on August 19, 2007, 01:07:30 AM
It just hit me with your example : instead of changing form  [template1/template2/ etc.] you could switch to different languages within the same form [Damn Template English / Damn Template Portugese/ Damn Template Italien / ... French... etc.]
Ever thought of this ?

The trouble is that using the ini route to change templates mean the change is global and experienced by all users.

8063's right. if u want to have language tools, u might want to try yahoo babelfish. i used it in my project site http://www.homehealthcare.co.nr/ but not sure how accurate it translate.