Skip to content
This repository has been archived by the owner on Oct 31, 2024. It is now read-only.

Commit

Permalink
setup to build package for 18.04 (bionic)
Browse files Browse the repository at this point in the history
changed password generation from makepasswd to openssl
  • Loading branch information
bobjolliffe committed Aug 15, 2018
1 parent 41ab0b4 commit 2b8b93a
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 9 deletions.
6 changes: 3 additions & 3 deletions src/debian/changelog
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
dhis2-tools (1.4-xenia) xenial; urgency=low
dhis2-tools (1.5-bionic) bionic; urgency=low

* Upstream changes
* Created new package for bionic

-- Bob Jolliffe <[email protected]> Wed, 08 Mar 2017 18:52:29 +0200
-- Bob Jolliffe <[email protected]> Wed, 15 Aug 2018 06:29:07 +0100
4 changes: 2 additions & 2 deletions src/debian/control
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,11 @@ Priority: optional
Maintainer: DHIS2 developers <[email protected]>
Build-Depends: debhelper (>= 8.0.0)
Standards-Version: 3.9.5
Homepage: http://launchpad.net/dhis2
Homepage: https://dhis2.org

Package: dhis2-tools
Architecture: all
Depends: postgresql-client,tomcat7-common (>= 7.0.26-1ubuntu1.1),netcat,libtcnative-1,makepasswd,unzip
Depends: postgresql-client,tomcat8-common,netcat,libtcnative-1,openssl,unzip
Description: Tools for managing dhis2 on ubuntu
This package contains a set of tools to assist with
the installation and maintenance of the dhis2 (http://dhis2.org)
Expand Down
2 changes: 1 addition & 1 deletion src/debian/copyright
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Copyright (c) 2004-2007, University of Oslo
Copyright (c) 2018, University of Oslo
All rights reserved.

Redistribution and use in source and binary forms, with or without
Expand Down
1 change: 0 additions & 1 deletion src/debian/install
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
/pkg/etc/sudoers.d/dhis2 /etc/sudoers.d/
/pkg/var/lib/dhis2 /var/lib/
/pkg/var/log/dhis2 /var/log/
/pkg/usr/share/dhis2-tools /usr/share/
/pkg/usr/share/doc/dhis2-tools /usr/share/doc/
/pkg/usr/share/man/man1/* /usr/share/man/man1/
Expand Down
4 changes: 2 additions & 2 deletions src/pkg/usr/bin/dhis2-instance-create
Original file line number Diff line number Diff line change
Expand Up @@ -125,9 +125,9 @@ echo "Creating system user"
sudo useradd -m -s /bin/bash -b $DHIS2BASEDIR -c "$TARGET dhis2 instance" -g dhis2 -k $DHIS2SKEL $TARGET

if $CREATEDB; then
# create the database user with a strong password. If this hangs: https://goo.gl/gUD3ga
# create the database user with a strong password
echo "Generating password"
PASSWORD=$(makepasswd --chars=10)
PASSWORD=$(openssl rand -base64 12)
echo "Creating database role"
psql postgres -c "CREATE ROLE $TARGET PASSWORD '$PASSWORD' NOSUPERUSER CREATEDB NOCREATEROLE INHERIT LOGIN;"
# Create the database
Expand Down

0 comments on commit 2b8b93a

Please sign in to comment.