WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: How to manage config files?  (Read 3167 times)

Offline Marco Trapanese

  • Newbie
  • *
  • Posts: 28
How to manage config files?
« on: August 23, 2010, 05:01:09 AM »
Hello,

first I would apologize if my English is not so good. It's not my primary language.

I'm wondering how to manage the extensions' config files.
For example, let's talk about OpenSSH. It requires the ssh_config and sshd_config files to run. By default it will look for them into /usr/local/etc/ssh/

What's the best way to make them persistent?

1. save the files into tce dir and copy to the destination folder at reboot
2. add those files to .filetool.lst
3. something other...

By the way, the wiki page about bootlocal.sh and shutdown.sh is down (403 + 404).

Thanks in advance
Marco

Offline Juanito

  • Administrator
  • Hero Member
  • *****
  • Posts: 14851
Re: How to manage config files?
« Reply #1 on: August 23, 2010, 05:09:40 AM »
When extensions copy config files to /usr/local/etc, they should check for the existence of a config file and only copy the config file if one does not exist.

If extensions follow the above rule, then you can add your customised config file to .filetool.lst

Offline Marco Trapanese

  • Newbie
  • *
  • Posts: 28
Re: How to manage config files?
« Reply #2 on: August 23, 2010, 05:29:05 AM »
Ok, I got it.

Just another example.
I'm compiling Qt Embedded right now.

It will copy all files to /usr/local/Trolltech

How to manage this? Of course I need this folder persistent. But is very large (hundreds of MB), what should I do in this case?

Thanks again
Marco

Offline Juanito

  • Administrator
  • Hero Member
  • *****
  • Posts: 14851
Re: How to manage config files?
« Reply #3 on: August 23, 2010, 05:38:47 AM »
It sounds like the best solution would be to make a tinycore extension out of it - you can find the instructions to do this in the wiki

Offline Marco Trapanese

  • Newbie
  • *
  • Posts: 28
Re: How to manage config files?
« Reply #4 on: August 23, 2010, 06:22:56 AM »
Quite hard for a newbie. It seems strange but there is no Qt Embedded extension yet.
Anyway I will try do to that.

But one should create an extension for every application downloaded and compiled?

Offline Juanito

  • Administrator
  • Hero Member
  • *****
  • Posts: 14851
Re: How to manage config files?
« Reply #5 on: August 23, 2010, 07:11:32 AM »
But one should create an extension for every application downloaded and compiled?

Up to you of course, but if you intend to reuse a compiled application, making an extension out of it is probably the easiest way to go.

Offline Marco Trapanese

  • Newbie
  • *
  • Posts: 28
Re: How to manage config files?
« Reply #6 on: August 23, 2010, 07:15:05 AM »
No, I intend only to retrieve the compiled application after reboot!  :D