#solaris and perhaps other very weirdass /bin/sh
#SHELL="/bin/ksh"
-DATASOURCE = DBI:Pg:dbname=freeside
-#DATASOURCE=DBI:mysql:freeside
+DB_TYPE = Pg
+#DB_TYPE = mysql
DB_USER = freeside
DB_PASSWORD=
-#TEMPLATE = asp
-TEMPLATE = mason
+DATASOURCE = DBI:${DB_TYPE}:dbname=freeside
-ASP_GLOBAL = /usr/local/etc/freeside/asp-global
-MASON_HANDLER = /usr/local/etc/freeside/handler.pl
-MASONDATA = /usr/local/etc/freeside/masondata
+#changable now (some things which should go to the others still go to CONF)
+FREESIDE_CONF = /usr/local/etc/freeside
+FREESIDE_LOG = /usr/local/etc/freeside
+FREESIDE_LOCK = /usr/local/etc/freeside
+FREESIDE_CACHE = /usr/local/etc/freeside
+FREESIDE_EXPORT = /usr/local/etc/freeside
+
+MASON_HANDLER = ${FREESIDE_CONF}/handler.pl
+MASONDATA = ${FREESIDE_CACHE}/masondata
+
+#where to put the default configuraiton used by freeside-setup to initialize
+#a new database (not used after that). primarily of interest to distro
+#package maintainers
+DIST_CONF = ${FREESIDE_CONF}/default_conf
+
+#mod_perl v1
+#APACHE_VERSION = 1
+#mod_perl v2 prereleases up to and including 1.999_21
+#APACHE_VERSON = 1.99
+#mod_perl v2 proper and prereleases 1.999_22 and after
+APACHE_VERSION = 2
#deb
FREESIDE_DOCUMENT_ROOT = /var/www/freeside
#freebsd
#INIT_FILE = /usr/local/etc/rc.d/011.freeside.sh
+#deb
+INIT_INSTALL = /usr/sbin/update-rc.d freeside defaults 21 20
+#redhat, fedora
+#INIT_INSTALL = /sbin/chkconfig freeside on
+#not necessary (freebsd)
+#INIT_INSTALL = /usr/bin/true
+
#deb, suse
-HTTPD_RESTART = /etc/init.d/apache restart
+#HTTPD_RESTART = /etc/init.d/apache restart
+#deb w/apache2
+HTTPD_RESTART = /etc/init.d/apache2 restart
#redhat, fedora, mandrake
#HTTPD_RESTART = /etc/init.d/httpd restart
#freebsd
-#HTTPD_RESTART = /usr/local/etc/rc.d/apache.sh stop; sleep 1; /usr/local/etc/rc.d/apache.sh start
+#HTTPD_RESTART = /usr/local/etc/rc.d/apache.sh stop || true; sleep 10; /usr/local/etc/rc.d/apache.sh start
#openbsd
-#HTTPD_RESTART = kill -TERM `cat /var/www/logs/httpd.pid`; sleep 1; /usr/sbin/httpd -u -DSSL
+#HTTPD_RESTART = kill -TERM `cat /var/www/logs/httpd.pid`; sleep 10; /usr/sbin/httpd -u -DSSL
#apache
-#HTTPD_RESTART = /usr/local/apache/bin/apachectl stop; sleep 1; /usr/local/apache/bin/apachectl startssl
+#HTTPD_RESTART = /usr/local/apache/bin/apachectl stop; sleep 10; /usr/local/apache/bin/apachectl startssl
+
+#(an include directory, not a file, "Include /etc/apache/conf.d" in httpd.conf)
+#deb (3.1+), apache2
+APACHE_CONF = /etc/apache2/conf.d
FREESIDE_RESTART = ${INIT_FILE} restart
QUEUED_USER=fs_queue
-#eventually this shouldn't be needed
-FREESIDE_PATH = `pwd`
-
SELFSERVICE_USER = fs_selfservice
#never run on the same machine in production!!!
-SELFSERVICE_MACHINES = localhost
+SELFSERVICE_MACHINES =
# SELFSERVICE_MACHINES = www.example.com
# SELFSERVICE_MACHINES = web1.example.com web2.example.com
SELFSERVICE_INSTALL_USERADD = /usr/sbin/useradd
#SELFSERVICE_INSTALL_USERADD = "/usr/sbin/pw useradd"
-RT_ENABLED = 0
-#RT_ENABLED = 1
+#RT_ENABLED = 0
+RT_ENABLED = 1
RT_DOMAIN = example.com
-RT_TIMEZONE = US/Pacific;
-#RT_TIMEZONE = US/Eastern;
+RT_TIMEZONE = US/Pacific
+#RT_TIMEZONE = US/Eastern
+FREESIDE_URL = "http://localhost/freeside/"
+
+#for now, same db as specified in DATASOURCE... eventually, otherwise?
+RT_DB_DATABASE = freeside
+
+# for cvs-upgrade-deploy target, the username who checked out the CVS copy.
+CVS_USER = ivan
+
+# for auto-version updates, so we can "make release" more things automatically
+RPM_SPECFILE = rpm/freeside.spec
#---
-#not changable yet
-FREESIDE_CONF = /usr/local/etc/freeside
#rt/config.layout.in
RT_PATH = /opt/rt3
-VERSION=1.5.0pre5
-TAG=freeside_1_5_0pre5
+#only used for dev kludge now, not a big deal
+FREESIDE_PATH = `pwd`
+PERL_INC_DEV_KLUDGE = /usr/local/share/perl/5.10.0/
-help:
- @echo "supported targets: aspdocs masondocs alldocs docs install-docs"
- @echo " htmlman"
- @echo " perl-modules install-perl-modules"
- @echo " install deploy"
- @echo " create-database"
- @echo " configure-rt create-rt"
- @echo " clean"
+VERSION=1.9.3
+TAG=freeside_1_9_3
-aspdocs: htmlman httemplate/* httemplate/*/* httemplate/*/*/* httemplate/*/*/*/* httemplate/*/*/*/*/*
- rm -rf aspdocs
- cp -pr httemplate aspdocs
- perl -p -i -e "\
- s/%%%VERSION%%%/${VERSION}/g;\
- " aspdocs/index.html
- touch aspdocs
+DEBVERSION = `echo ${VERSION} | perl -pe 's/(\d)([a-z])/\1~\2/'`-1
+TEXMFHOME := "\$$TEXMFHOME"
-masondocs: htmlman httemplate/* httemplate/*/* httemplate/*/*/* httemplate/*/*/*/* httemplate/*/*/*/*/*
+help:
+ @echo "supported targets:"
+ @echo " create-database create-config"
+ @echo " install deploy"
+ @echo " cvs-upgrade-deploy"
+ @echo " configure-rt create-rt"
+ @echo " clean help"
+ @echo
+ @echo " install-docs install-perl-modules"
+ @echo " install-init install-apache"
+ @echo " install-rt install-texmf"
+ @echo " install-selfservice update-selfservice"
+ @echo
+ @echo " dev dev-docs dev-perl-modules"
+ @echo
+ @echo " masondocs alldocs docs"
+ @echo " wikiman"
+ @echo " perl-modules"
+ #@echo
+ #@echo " upload-docs release"
+
+
+masondocs: httemplate/* httemplate/*/* httemplate/*/*/* httemplate/*/*/*/*
rm -rf masondocs
cp -pr httemplate masondocs
- ( cd masondocs; \
- ../bin/masonize; \
- )
- perl -p -i -e "\
- s/%%%VERSION%%%/${VERSION}/g;\
- " masondocs/index.html
touch masondocs
-alldocs: aspdocs masondocs
+alldocs: masondocs
docs:
- make ${TEMPLATE}docs
-
-htmlman:
- [ -e ./httemplate/docs/man ] || mkdir httemplate/docs/man
- [ -e ./httemplate/docs/man/bin ] || mkdir httemplate/docs/man/bin
- [ -e ./httemplate/docs/man/FS ] || mkdir httemplate/docs/man/FS
- [ -e ./httemplate/docs/man/FS/UI ] || mkdir httemplate/docs/man/FS/UI
- [ -e ./httemplate/docs/man/FS/part_export ] || mkdir httemplate/docs/man/FS/part_export
- chmod a+rx bin/pod2x
- [ -e DONT_REBUILD_DOCS ] || bin/pod2x
-
-forcehtmlman:
- [ -e ./httemplate/docs/man ] || mkdir httemplate/docs/man
- [ -e ./httemplate/docs/man/bin ] || mkdir httemplate/docs/man/bin
- [ -e ./httemplate/docs/man/FS ] || mkdir httemplate/docs/man/FS
- [ -e ./httemplate/docs/man/FS/UI ] || mkdir httemplate/docs/man/FS/UI
- [ -e ./httemplate/docs/man/FS/part_export ] || mkdir httemplate/docs/man/FS/part_export
- bin/pod2x
+ make masondocs
+
+wikiman:
+ chmod a+rx ./bin/pod2x
+ ./bin/pod2x
install-docs: docs
[ -e ${FREESIDE_DOCUMENT_ROOT} ] && mv ${FREESIDE_DOCUMENT_ROOT} ${FREESIDE_DOCUMENT_ROOT}.`date +%Y%m%d%H%M%S` || true
- cp -r ${TEMPLATE}docs ${FREESIDE_DOCUMENT_ROOT}
- [ "${TEMPLATE}" = "asp" -a ! -e ${ASP_GLOBAL} ] && mkdir ${ASP_GLOBAL} || true
- [ "${TEMPLATE}" = "asp" ] && chown -R freeside ${ASP_GLOBAL} || true
- [ "${TEMPLATE}" = "asp" ] && cp htetc/global.asa ${ASP_GLOBAL} || true
- [ "${TEMPLATE}" = "asp" ] && \
- perl -p -i -e "\
- s'%%%FREESIDE_DOCUMENT_ROOT%%%'${FREESIDE_DOCUMENT_ROOT}'g; \
- " ${ASP_GLOBAL}/global.asa || true
- [ "${TEMPLATE}" = "mason" ] && cp htetc/handler.pl ${MASON_HANDLER} || true
- [ "${TEMPLATE}" = "mason" ] && \
- perl -p -i -e "\
- s'%%%FREESIDE_DOCUMENT_ROOT%%%'${FREESIDE_DOCUMENT_ROOT}'g; \
- s'%%%RT_ENABLED%%%'${RT_ENABLED}'g; \
- " ${MASON_HANDLER} || true
- [ "${TEMPLATE}" = "mason" -a ! -e ${MASONDATA} ] && mkdir ${MASONDATA} || true
- [ "${TEMPLATE}" = "mason" ] && chown -R freeside ${MASONDATA} || true
+ cp -r masondocs ${FREESIDE_DOCUMENT_ROOT}
+ chown -R freeside:freeside ${FREESIDE_DOCUMENT_ROOT}
+ cp htetc/handler.pl ${MASON_HANDLER}
+ [ ! -e ${MASONDATA} ] && mkdir ${MASONDATA} || true
+ chown -R freeside ${MASONDATA}
+
+dev-docs:
+ [ -e ${FREESIDE_DOCUMENT_ROOT} ] && mv ${FREESIDE_DOCUMENT_ROOT} ${FREESIDE_DOCUMENT_ROOT}.`date +%Y%m%d%H%M%S` || true
+ ln -s ${FREESIDE_PATH}/httemplate ${FREESIDE_DOCUMENT_ROOT}
+ cp htetc/handler.pl ${MASON_HANDLER}
+ perl -p -i -e "\
+ s'###use Module::Refresh;###'use Module::Refresh;'; \
+ s'###Module::Refresh->refresh;###'Module::Refresh->refresh;'; \
+ " ${MASON_HANDLER} || true
perl-modules:
cd FS; \
[ -e Makefile ] || perl Makefile.PL; \
- make
+ make; \
+ perl -p -i -e "\
+ s/%%%VERSION%%%/${VERSION}/g;\
+ " blib/lib/FS.pm;\
+ perl -p -i -e "\
+ s|%%%FREESIDE_CONF%%%|${FREESIDE_CONF}|g;\
+ s|%%%FREESIDE_CACHE%%%|${FREESIDE_CACHE}|g;\
+ s'%%%FREESIDE_DOCUMENT_ROOT%%%'${FREESIDE_DOCUMENT_ROOT}'g; \
+ s'%%%RT_ENABLED%%%'${RT_ENABLED}'g; \
+ s'%%%MASONDATA%%%'${MASONDATA}'g;\
+ " blib/lib/FS/*.pm;\
+ perl -p -i -e "\
+ s/%%%SELFSERVICE_USER%%%/${SELFSERVICE_USER}/g;\
+ s/%%%SELFSERVICE_MACHINES%%%/${SELFSERVICE_MACHINES}/g;\
+ s|%%%FREESIDE_EXPORT%%%|${FREESIDE_EXPORT}|g;\
+ " blib/lib/FS/Cron/*.pm;\
+ perl -p -i -e "\
+ s|%%%FREESIDE_CONF%%%|${FREESIDE_CONF}|g;\
+ s|%%%FREESIDE_EXPORT%%%|${FREESIDE_EXPORT}|g;\
+ s|%%%FREESIDE_LOG%%%|${FREESIDE_LOG}|g;\
+ " blib/lib/FS/part_export/*.pm;\
+ perl -p -i -e "\
+ s|%%%FREESIDE_CACHE%%%|${FREESIDE_CACHE}|g;\
+ " blib/lib/FS/cust_main/*.pm;\
+ perl -p -i -e "\
+ s|%%%FREESIDE_CONF%%%|${FREESIDE_CONF}|g;\
+ s|%%%FREESIDE_LOG%%%|${FREESIDE_LOG}|g;\
+ s|%%%FREESIDE_LOCK%%%|${FREESIDE_LOCK}|g;\
+ s|%%%FREESIDE_CACHE%%%|${FREESIDE_CACHE}|g;\
+ s|%%%FREESIDE_EXPORT%%%|${FREESIDE_EXPORT}|g;\
+ s|%%%DIST_CONF%%%|${DIST_CONF}|g;\
+ " blib/script/*
install-perl-modules: perl-modules
+ [ -L ${PERL_INC_DEV_KLUDGE}/FS ] \
+ && rm ${PERL_INC_DEV_KLUDGE}/FS \
+ && mv ${PERL_INC_DEV_KLUDGE}/FS.old ${PERL_INC_DEV_KLUDGE}/FS \
+ || true
cd FS; \
make install UNINST=1
+ #install this for freeside-setup
+ install -d $(DIST_CONF)
+ #install conf/[a-z]* $(DEFAULT_CONF)
+ #CVS is not [a-z]
+ install `ls -d conf/[a-z]* | grep -v CVS | grep -v '^conf/registries'` $(DIST_CONF)
+
+dev-perl-modules: perl-modules
+ [ -d ${PERL_INC_DEV_KLUDGE}/FS -a ! -L ${PERL_INC_DEV_KLUDGE}/FS ] \
+ && mv ${PERL_INC_DEV_KLUDGE}/FS ${PERL_INC_DEV_KLUDGE}/FS.old \
+ || true
+
+ rm -rf ${PERL_INC_DEV_KLUDGE}/FS
+ ln -sf ${FREESIDE_PATH}/FS/blib/lib/FS ${PERL_INC_DEV_KLUDGE}/FS
+
+install-texmf:
+ install -D -o freeside -m 444 etc/fslongtable.sty \
+ `kpsewhich -expand-var \\\$$TEXMFLOCAL`/tex/generic/fslongtable.sty
+ texhash `kpsewhich -expand-var \\\$$TEXMFLOCAL`
install-init:
#[ -e ${INIT_FILE} ] || install -o root -g ${INSTALLGROUP} -m 711 init.d/freeside-init ${INIT_FILE}
install -o root -g ${INSTALLGROUP} -m 711 init.d/freeside-init ${INIT_FILE}
perl -p -i -e "\
s/%%%QUEUED_USER%%%/${QUEUED_USER}/g;\
- s'%%%FREESIDE_PATH%%%'${FREESIDE_PATH}'g;\
s/%%%SELFSERVICE_USER%%%/${SELFSERVICE_USER}/g;\
s/%%%SELFSERVICE_MACHINES%%%/${SELFSERVICE_MACHINES}/g;\
" ${INIT_FILE}
+ ${INIT_INSTALL}
+
+install-apache:
+ [ -e ${APACHE_CONF}/freeside-base.conf ] && rm ${APACHE_CONF}/freeside-base.conf || true
+ [ -d ${APACHE_CONF} ] && \
+ ( install -o root -m 755 htetc/freeside-base${APACHE_VERSION}.conf ${APACHE_CONF} && \
+ ( [ ${RT_ENABLED} -eq 1 ] && install -o root -m 755 htetc/freeside-rt.conf ${APACHE_CONF} || true ) && \
+ perl -p -i -e "\
+ s'%%%FREESIDE_DOCUMENT_ROOT%%%'${FREESIDE_DOCUMENT_ROOT}'g; \
+ s'%%%FREESIDE_CONF%%%'${FREESIDE_CONF}'g; \
+ s'%%%MASON_HANDLER%%%'${MASON_HANDLER}'g; \
+ " ${APACHE_CONF}/freeside-*.conf \
+ ) || true
install-selfservice:
- [ -e ~freeside/.ssh/id_dsa.pub ] || su -c 'ssh-keygen -t dsa' - freeside
+ [ -e ~freeside ] || cp -pr /etc/skel ~freeside && chown -R freeside ~freeside
+ [ -e ~freeside/.ssh/id_dsa.pub ] || [ -e ~freeside/.ssh/id_rsa.pub ] || su - freeside -c 'ssh-keygen -t dsa'
for MACHINE in ${SELFSERVICE_MACHINES}; do \
scp -r fs_selfservice/FS-SelfService ${SELFSERVICE_INSTALL_USER}@$$MACHINE:. ;\
ssh ${SELFSERVICE_INSTALL_USER}@$$MACHINE "cd FS-SelfService; perl Makefile.PL && make" ;\
ssh ${SELFSERVICE_INSTALL_USER}@$$MACHINE "cd FS-SelfService; sudo make install" ;\
scp ~freeside/.ssh/id_dsa.pub ${SELFSERVICE_INSTALL_USER}@$$MACHINE:. ;\
- ssh ${SELFSERVICE_INSTALL_USER}@$$MACHINE "sudo ${SELFSERVICE_INSTALL_USERADD} freeside; sudo install -D -o freeside -m 600 ./id_dsa.pub ~freeside/.ssh/authorized_keys" ;\
+ ssh ${SELFSERVICE_INSTALL_USER}@$$MACHINE "sudo ${SELFSERVICE_INSTALL_USERADD} freeside; sudo install -d -o freeside -m 600 ~freeside/.ssh/; sudo install -o freeside -m 600 ./id_dsa.pub ~freeside/.ssh/authorized_keys" ;\
ssh ${SELFSERVICE_INSTALL_USER}@$$MACHINE "sudo install -o freeside -d /usr/local/freeside" ;\
done
update-selfservice:
for MACHINE in ${SELFSERVICE_MACHINES}; do \
RSYNC_RSH=ssh rsync -rlptz fs_selfservice/FS-SelfService/ ${SELFSERVICE_INSTALL_USER}@$$MACHINE:FS-SelfService ;\
- ssh ${SELFSERVICE_INSTALL_USER}@$$MACHINE "cd FS-SelfService; perl Makefile.PL && make" ;\
+ ssh ${SELFSERVICE_INSTALL_USER}@$$MACHINE "cd FS-SelfService; make clean; perl Makefile.PL && make" ;\
ssh ${SELFSERVICE_INSTALL_USER}@$$MACHINE "cd FS-SelfService; sudo make install" ;\
done
-install: install-perl-modules install-docs install-init install-rt
+install: install-perl-modules install-docs install-init install-apache install-rt install-texmf
deploy: install
${HTTPD_RESTART}
${FREESIDE_RESTART}
+cvs-upgrade-deploy:
+ su ${CVS_USER} -c 'cvs update -d -P'
+ make install-perl-modules
+ su freeside -c "freeside-upgrade ${CVS_USER}" #not really the same user
+ make deploy
+
+dev: dev-perl-modules dev-docs
+
create-database:
perl -e 'use DBIx::DataSource qw( create_database ); create_database( "${DATASOURCE}", "${DB_USER}", "${DB_PASSWORD}" ) or die $$DBIx::DataSource::errstr;'
chmod 600 ${FREESIDE_CONF}/secrets
chown freeside ${FREESIDE_CONF}/secrets
- mkdir "${FREESIDE_CONF}/conf.${DATASOURCE}"
- rm -rf conf/registries #old dirs just won't go away
- #cp conf/[a-z]* "${FREESIDE_CONF}/conf.${DATASOURCE}"
- cp `ls -d conf/[a-z]* | grep -v CVS` "${FREESIDE_CONF}/conf.${DATASOURCE}"
- chown -R freeside "${FREESIDE_CONF}/conf.${DATASOURCE}"
+ mkdir "${FREESIDE_CACHE}/counters.${DATASOURCE}"
+ chown freeside "${FREESIDE_CACHE}/counters.${DATASOURCE}"
- mkdir "${FREESIDE_CONF}/counters.${DATASOURCE}"
- chown freeside "${FREESIDE_CONF}/counters.${DATASOURCE}"
+ mkdir "${FREESIDE_CACHE}/cache.${DATASOURCE}"
+ chown freeside "${FREESIDE_CACHE}/cache.${DATASOURCE}"
- mkdir "${FREESIDE_CONF}/cache.${DATASOURCE}"
- chown freeside "${FREESIDE_CONF}/cache.${DATASOURCE}"
+ mkdir "${FREESIDE_EXPORT}/export.${DATASOURCE}"
+ chown freeside "${FREESIDE_EXPORT}/export.${DATASOURCE}"
+
+ #install this for freeside-setup
+ install -d $(DIST_CONF)
+ #install conf/[a-z]* $(DEFAULT_CONF)
+ #CVS is not [a-z]
+ install `ls -d conf/[a-z]* | grep -v CVS | grep -v '^conf/registries'` $(DIST_CONF)
- mkdir "${FREESIDE_CONF}/export.${DATASOURCE}"
- chown freeside "${FREESIDE_CONF}/export.${DATASOURCE}"
configure-rt:
cd rt; \
s'%%%MASONDATA%%%'${MASONDATA}'g;\
" config.layout; \
./configure --enable-layout=Freeside\
- --with-db-type=Pg \
+ --with-db-type=${DB_TYPE} \
--with-db-dba=${DB_USER} \
- --with-db-database=freeside \
+ --with-db-database=${RT_DB_DATABASE} \
--with-db-rt-user=${DB_USER} \
--with-db-rt-pass=${DB_PASSWORD} \
--with-web-user=freeside \
--with-rt-group=freeside
create-rt: configure-rt
+ [ -d /opt ] || mkdir /opt #doh
+ [ -d /opt/rt3 ] || mkdir /opt/rt3 #
+ [ -d /opt/rt3/share ] || mkdir /opt/rt3/share #
cd rt; make install
- echo -e "${DB_PASSWORD}\n\\d sessions"\
- | psql -U ${DB_USER} -W freeside 2>&1\
- | grep '^Did not find'\
- && rt/sbin/rt-setup-database --dba '${DB_USER}' \
- --dba-password '${DB_PASSWORD}' \
- --action schema \
+ rt/sbin/rt-setup-database --dba '${DB_USER}' \
+ -dba-password '${DB_PASSWORD}' \
+ -action schema \
|| true
rt/sbin/rt-setup-database --action insert_initial \
&& rt/sbin/rt-setup-database --action insert --datafile ${RT_PATH}/etc/initialdata \
|| true
- perl -p -i -e "\
- s'%%%RT_DOMAIN%%%'${RT_DOMAIN}'g;\
- s'%%%RT_TIMEZONE%%%'${RT_TIMEZONE}'g;\
- " ${RT_PATH}/etc/RT_SiteConfig.pm
install-rt:
- [ ${RT_ENABLED} -eq 1 ] && ( cd rt; make install ) || true
+ if [ ${RT_ENABLED} -eq 1 ]; then ( cd rt; make install ); fi
+ if [ ${RT_ENABLED} -eq 1 ]; then perl -p -i -e "\
+ s'%%%RT_DOMAIN%%%'${RT_DOMAIN}'g;\
+ s'%%%RT_TIMEZONE%%%'${RT_TIMEZONE}'g;\
+ s'%%%FREESIDE_URL%%%'${FREESIDE_URL}'g;\
+ " ${RT_PATH}/etc/RT_SiteConfig.pm; fi
clean:
- rm -rf aspdocs masondocs
- cd FS; \
+ rm -rf masondocs
+ rm -rf httemplate/docs/man
+ rm -rf pod2htmi.tmp
+ rm -rf pod2htmd.tmp
+ -cd FS; \
+ make clean
+ -cd fs_selfservice/FS-SelfService; \
make clean
#these are probably only useful if you're me...
-upload-docs: forcehtmlman
- ssh pouncequick.420.am rm -rf /var/www/www.sisd.com/freeside/devdocs
- scp -pr httemplate/docs pouncequick.420.am:/var/www/www.sisd.com/freeside/devdocs
+#release: upload-docs
+.PHONY: release
+release:
+ # Update the changelog
+ ./bin/cvs2cl
+ cvs commit -m "Updated for ${VERSION}" ChangeLog
+
+ # Update the RPM specfile
+ cvs edit ${RPM_SPECFILE}
+ perl -p -i -e "s/\d+[^\}]+/${VERSION}/ if /%define\s+version\s+(\d+[^\}]+)\}/;" ${RPM_SPECFILE}
+ perl -p -i -e "s/\d+[^\}]+/1/ if /%define\s+release\s+(\d+[^\}]+)\}/;" ${RPM_SPECFILE}
+ cvs commit -m "Updated for ${VERSION}" ${RPM_SPECFILE}
-release: upload-docs
- cd /home/ivan/freeside
+ # Update the Debian changelog
+ cvs edit debian/changelog
+ dch -v ${DEBVERSION} -p "New upstream release"
+ cvs commit -m "Updated for ${VERSION}" debian/changelog
+
+ # Make sure other people's changes are pulled in!
+ cvs update -d -P
+
+ # Tag the release
#cvs tag ${TAG}
cvs tag -F ${TAG}
cvs export -r ${TAG} -d freeside-${VERSION} freeside
tar czvf freeside-${VERSION}.tar.gz freeside-${VERSION}
- scp freeside-${VERSION}.tar.gz ivan@pouncequick.420.am:/var/www/sisd.420.am/freeside/
+ scp freeside-${VERSION}.tar.gz ivan@420.am:/var/www/www.sisd.com/freeside/
mv freeside-${VERSION} freeside-${VERSION}.tar.gz ..
-update-webdemo:
- ssh ivan@pouncequick.420.am '( cd freeside; cvs update -d -P )'
- #ssh root@pouncequick.420.am '( cd /home/ivan/freeside; make clean; make deploy )'
- ssh root@pouncequick.420.am '( cd /home/ivan/freeside; make deploy )'
+ #these things failing should not make release target fail, so: "|| true"
+
+ #kick off vmware update
+ #./BUILD_VMWARE_APPLIANCE ${$TAG} || true
+
+ #kick off deb package update
+
+ #kick off rpm package update too?
+
+ #update web demo?
+
+ #update web demo self-service?