Hi guys, Thank you so much. But I think I wasn't clear enough.
Imagine I already have two environments, both operational and identical at time zero: one for testing and one for production. Every time a request for change OTRS configuration arrives (some new configuration, a new dynamic field, a new ACL, new process, everything about configuration etc), I need to implement it, test it and then deploy it to production, like any other application. In other words, I need to export/import all configuration data on a regular basis, but should leave the other production data intact (history of tickets, articles etc...). So drop the database is not an option. Any idea? Thanks -----Original Message----- From: [email protected] [mailto:[email protected]] On Behalf Of [email protected] Sent: Wednesday, August 12, 2015 5:37 PM To: [email protected] Subject: otrs Digest, Vol 83, Issue 3 Send otrs mailing list submissions to [email protected] To subscribe or unsubscribe via the World Wide Web, visit http://lists.otrs.org/cgi-bin/listinfo/otrs or, via email, send a message with subject or body 'help' to [email protected] You can reach the person managing the list at [email protected] When replying, please edit your Subject line so it is more specific than "Re: Contents of otrs digest..." Today's Topics: 1. Deploy OTRS configuration from test environment to production environment (Samuel Diniz Casimiro) 2. Re: Deploy OTRS configuration from test environment to production environment (Leonardo Certuche) 3. Re: Deploy OTRS configuration from test environment to production environment (Jay) 4. Re: Deploy OTRS configuration from test environment to production environment (Jay) ---------------------------------------------------------------------- Message: 1 Date: Wed, 12 Aug 2015 19:53:36 +0000 From: Samuel Diniz Casimiro <[email protected]> Subject: [otrs] Deploy OTRS configuration from test environment to production environment To: "[email protected]" <[email protected]> Message-ID: <[email protected]> Content-Type: text/plain; charset="us-ascii" Hi everyone! I'm using OTRS 4.0.11. Because of some company policies, I need to set up to environments, one for testing and another for production (operational). The problem is: How to export the required configuration data from test env. and deploy it into production env? I know I could copy and paste the ZZZAuto.pm file, but is that enough? Is there any database configuration data I should also take care? If so, how? I know I could use the provided backup.pl script, but I don't want to backup/restore all the data, only the configuration data. Is there any way to do so? Thanks in advance, Samuel -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.otrs.org/pipermail/otrs/attachments/20150812/498c0b35/attachment-0001.html> ------------------------------ Message: 2 Date: Wed, 12 Aug 2015 15:00:19 -0500 From: Leonardo Certuche <[email protected]> Subject: Re: [otrs] Deploy OTRS configuration from test environment to production environment To: "User questions and discussions about OTRS." <[email protected]> Message-ID: <cag67u_syorvtcbhfa9qgdxw6teeqdlwftphn4wafkic0vee...@mail.gmail.com> Content-Type: text/plain; charset="utf-8" Hello, The way we have done that before is: on app: tar --exclude=var/article --exclude=var/tmp -cvpzf ../otrs_app.tar.gz * on db: mysqldump -u root -p otrs > otrs_db.sql And then restore both on your new environment, previous installation of the product so all software requirements are already met. On 12 August 2015 at 14:53, Samuel Diniz Casimiro < [email protected]> wrote: > Hi everyone! > > > > I?m using OTRS 4.0.11. > > > > Because of some company policies, I need to set up to environments, > one for testing and another for production (operational). > > > > The problem is: How to export the required configuration data from > test env. and deploy it into production env? > > > > I know I could copy and paste the ZZZAuto.pm file, but is that enough? > Is there any database configuration data I should also take care? If so, how? > > > > I know I could use the provided backup.pl script, but I don?t want to > backup/restore all the data, only the configuration data. Is there any > way to do so? > > > > Thanks in advance, > > > > Samuel > > --------------------------------------------------------------------- > OTRS mailing list: otrs - Webpage: http://otrs.org/ > Archive: http://lists.otrs.org/pipermail/otrs > To unsubscribe: http://lists.otrs.org/cgi-bin/listinfo/otrs > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.otrs.org/pipermail/otrs/attachments/20150812/44745a45/attachment-0001.html> ------------------------------ Message: 3 Date: Wed, 12 Aug 2015 13:23:09 -0700 From: Jay <[email protected]> Subject: Re: [otrs] Deploy OTRS configuration from test environment to production environment To: "User questions and discussions about OTRS." <[email protected]> Message-ID: <CABOM=r6_qkd0ghjgzwprmgdujhwu-yec5lmorpj1xutcvcv...@mail.gmail.com> Content-Type: text/plain; charset="utf-8" Have you checked out the /opt/otrs/scripts/backup.pl and /opt/otrs/scripts/ restore.pl scripts? These are both described at https://otrs.github.io/doc/manual/admin/stable/en/html/backup-and-restore.html . When performing restore from the generated backup files, I usually find that it's necessary to drop/create the mysql otrs database. Otherwise, the restore will complain that the database already exists. On the production environment, generate a backup: sudo /opt/otrs/scripts/backup.pl -d /path/to/backup/folder On the test environment: 1. Copy the backup from the production system. 2. Drop/create the otrs database. WARNING: make sure you're on the dev environment. mysql -e "drop database otrs;" mysql -e "create database otrs;" 3. Restore the backup. /opt/otrs/scripts/restore.pl -b /path/to/backup/folder/YYY-MM-DD_hh-mm/ -d /opt/otrs/ 4. Verify the DB. su - otrs -c '$HOME/bin/otrs.CheckDB.pl' 5. Re-configure the otrs cron jobs. /opt/otrs/bin/Cron.sh restart otrs 6. To disable otrs user cron jobs, for testing or to avoid colliding with an existing production instance, disable the otrs crontab with '/opt/otrs/bin/Cron.sh stop otrs'. 7. Start the Scheduler. su - otrs -c '$HOME/bin/otrs.Scheduler.pl -a start' Hope this helps. Jay On Wed, Aug 12, 2015 at 1:00 PM, Leonardo Certuche < [email protected]> wrote: > Hello, > > The way we have done that before is: > > on app: > tar --exclude=var/article --exclude=var/tmp -cvpzf ../otrs_app.tar.gz > * > > on db: > mysqldump -u root -p otrs > otrs_db.sql > > And then restore both on your new environment, previous installation > of the product so all software requirements are already met. > > On 12 August 2015 at 14:53, Samuel Diniz Casimiro < > [email protected]> wrote: > >> Hi everyone! >> >> >> >> I?m using OTRS 4.0.11. >> >> >> >> Because of some company policies, I need to set up to environments, >> one for testing and another for production (operational). >> >> >> >> The problem is: How to export the required configuration data from >> test env. and deploy it into production env? >> >> >> >> I know I could copy and paste the ZZZAuto.pm file, but is that >> enough? Is there any database configuration data I should also take care? If >> so, how? >> >> >> >> I know I could use the provided backup.pl script, but I don?t want to >> backup/restore all the data, only the configuration data. Is there >> any way to do so? >> >> >> >> Thanks in advance, >> >> >> >> Samuel >> >> --------------------------------------------------------------------- >> OTRS mailing list: otrs - Webpage: http://otrs.org/ >> Archive: http://lists.otrs.org/pipermail/otrs >> To unsubscribe: http://lists.otrs.org/cgi-bin/listinfo/otrs >> > > > --------------------------------------------------------------------- > OTRS mailing list: otrs - Webpage: http://otrs.org/ > Archive: http://lists.otrs.org/pipermail/otrs > To unsubscribe: http://lists.otrs.org/cgi-bin/listinfo/otrs > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.otrs.org/pipermail/otrs/attachments/20150812/2cb9b5bd/attachment-0001.html> ------------------------------ Message: 4 Date: Wed, 12 Aug 2015 13:32:17 -0700 From: Jay <[email protected]> Subject: Re: [otrs] Deploy OTRS configuration from test environment to production environment To: "User questions and discussions about OTRS." <[email protected]> Message-ID: <CABOM=r52ge_kbufn3r+yt9yhy59srmted-q6xlm4zgwwb1_...@mail.gmail.com> Content-Type: text/plain; charset="utf-8" oops.. i missed the last part of your question. sorry. can u just export/import the configuration directly from the UI? Jay On Wed, Aug 12, 2015 at 1:23 PM, Jay <[email protected]> wrote: > Have you checked out the /opt/otrs/scripts/backup.pl and > /opt/otrs/scripts/restore.pl scripts? These are both described at > https://otrs.github.io/doc/manual/admin/stable/en/html/backup-and-rest > ore.html > . > > When performing restore from the generated backup files, I usually > find that it's necessary to drop/create the mysql otrs database. > Otherwise, the restore will complain that the database already exists. > > On the production environment, generate a backup: > sudo /opt/otrs/scripts/backup.pl -d /path/to/backup/folder > > On the test environment: > 1. Copy the backup from the production system. > 2. Drop/create the otrs database. WARNING: make sure you're on the dev > environment. > mysql -e "drop database otrs;" > mysql -e "create database otrs;" > 3. Restore the backup. > /opt/otrs/scripts/restore.pl -b > /path/to/backup/folder/YYY-MM-DD_hh-mm/ > -d /opt/otrs/ > 4. Verify the DB. > su - otrs -c '$HOME/bin/otrs.CheckDB.pl' > 5. Re-configure the otrs cron jobs. > /opt/otrs/bin/Cron.sh restart otrs > 6. To disable otrs user cron jobs, for testing or to avoid colliding > with an existing production instance, disable the otrs crontab with > '/opt/otrs/bin/Cron.sh stop otrs'. > 7. Start the Scheduler. > su - otrs -c '$HOME/bin/otrs.Scheduler.pl -a start' > > Hope this helps. > > > > Jay > > On Wed, Aug 12, 2015 at 1:00 PM, Leonardo Certuche < > [email protected]> wrote: > >> Hello, >> >> The way we have done that before is: >> >> on app: >> tar --exclude=var/article --exclude=var/tmp -cvpzf ../otrs_app.tar.gz >> * >> >> on db: >> mysqldump -u root -p otrs > otrs_db.sql >> >> And then restore both on your new environment, previous installation >> of the product so all software requirements are already met. >> >> On 12 August 2015 at 14:53, Samuel Diniz Casimiro < >> [email protected]> wrote: >> >>> Hi everyone! >>> >>> >>> >>> I?m using OTRS 4.0.11. >>> >>> >>> >>> Because of some company policies, I need to set up to environments, >>> one for testing and another for production (operational). >>> >>> >>> >>> The problem is: How to export the required configuration data from >>> test env. and deploy it into production env? >>> >>> >>> >>> I know I could copy and paste the ZZZAuto.pm file, but is that enough? >>> Is there any database configuration data I should also take care? If >>> so, how? >>> >>> >>> >>> I know I could use the provided backup.pl script, but I don?t want >>> to backup/restore all the data, only the configuration data. Is >>> there any way to do so? >>> >>> >>> >>> Thanks in advance, >>> >>> >>> >>> Samuel >>> >>> -------------------------------------------------------------------- >>> - OTRS mailing list: otrs - Webpage: http://otrs.org/ >>> Archive: http://lists.otrs.org/pipermail/otrs >>> To unsubscribe: http://lists.otrs.org/cgi-bin/listinfo/otrs >>> >> >> >> --------------------------------------------------------------------- >> OTRS mailing list: otrs - Webpage: http://otrs.org/ >> Archive: http://lists.otrs.org/pipermail/otrs >> To unsubscribe: http://lists.otrs.org/cgi-bin/listinfo/otrs >> > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.otrs.org/pipermail/otrs/attachments/20150812/dfd8de4c/attachment.html> ------------------------------ --------------------------------------------------------------------- OTRS mailing list: otrs - Webpage: http://otrs.org/ Archive: http://lists.otrs.org/pipermail/otrs To unsubscribe: http://lists.otrs.org/cgi-bin/listinfo/otrs End of otrs Digest, Vol 83, Issue 3 *********************************** --------------------------------------------------------------------- OTRS mailing list: otrs - Webpage: http://otrs.org/ Archive: http://lists.otrs.org/pipermail/otrs To unsubscribe: http://lists.otrs.org/cgi-bin/listinfo/otrs
