postinst 730 B

12345678910111213141516171819202122
  1. #!/bin/sh
  2. # Copyright Materialize, Inc. and contributors. All rights reserved.
  3. #
  4. # Use of this software is governed by the Business Source License
  5. # included in the LICENSE file at the root of this repository.
  6. #
  7. # As of the Change Date specified in that file, in accordance with
  8. # the Business Source License, use of this software will be governed
  9. # by the Apache License, Version 2.0.
  10. set -e
  11. # The weird username is intended to be unlikely
  12. # to conflict with real local users.
  13. adduser --system --group --force-badname --no-create-home --quiet _Materialize
  14. mkdir -p /var/lib/materialize/
  15. chown _Materialize:_Materialize /var/lib/materialize/
  16. if [ -x /bin/systemctl ]; then
  17. systemctl daemon-reload >/dev/null 2>&1 || true
  18. fi