- **status**: unread --> closed
- **Comment**:

Migrated to [github](https://github.com/bgpsecurity/rpstir/issues/20).



---

** [tickets:#20] make initialize/upgrade safer, easier, and more powerful**

**Status:** closed
**Created:** Thu Jun 11, 2015 02:56 AM UTC by David Mandelberg
**Last Updated:** Thu Jun 11, 2015 10:58 PM UTC
**Owner:** nobody


Merge `bin/rpki/initialize.in` and `bin/rpki/upgrade.in` into a single script 
with the following behavior (described in pseudo-code). The `forced` variable 
corresponds to a `-f` or `--force` argument passed to the new script. Note that 
some of the below functionality depends on [#17].

    if not able to connect to database as rpstir user:
        if not forced:
            log error and exit
        if not able to connect to database as root user:
            ask for database root password
            if still not able to connect as root:
                log error and exit
        create database user with correct password from rpstir.conf
        if still not able to connect to database as rpstir user:
            log error and exit
    
    if not able to select rpstir database:
        if not forced:
            log error and exit
        if not able to create rpstir database:
            if not able to create rpstir database as root:
                log error and exit
    
    if database is empty and directories are empty:
        initialize database and directories
        exit successfully
    else if database and directories are already initialized:
        if db/dirs are from an old (known) version of rpstir:
            if (forced) or (all upgrades are safe):
                perform all upgrades
                exit successfully
            else:
                log error and exit
        else if db/dirs are from an old (unknown) version of rpstir:
            log error and exit
        else:
            exit successfully
    else:
        log error and exit

Add a separate script to clear an existing database/directories (note that the 
above code doesn't do this).


---

Sent from sourceforge.net because rpstir-devel@lists.sourceforge.net is 
subscribed to https://sourceforge.net/p/rpstir/tickets/

To unsubscribe from further messages, a project admin can change settings at 
https://sourceforge.net/p/rpstir/admin/tickets/options.  Or, if this is a 
mailing list, you can unsubscribe from the mailing list.
------------------------------------------------------------------------------
Go from Idea to Many App Stores Faster with Intel(R) XDK
Give your users amazing mobile app experiences with Intel(R) XDK.
Use one codebase in this all-in-one HTML5 development environment.
Design, debug & build mobile apps & 2D/3D high-impact games for multiple OSs.
http://pubads.g.doubleclick.net/gampad/clk?id=254741551&iu=/4140
_______________________________________________
rpstir-devel mailing list
rpstir-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/rpstir-devel

Reply via email to