Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
path: root/archinstall/default_profiles/servers/postgresql.py
blob: dba722cef60297821f0b0b969d15375482063ad2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
from typing import List, TYPE_CHECKING

from archinstall.default_profiles.profile import Profile, ProfileType

if TYPE_CHECKING:
	from archinstall.lib.installer import Installer


class PostgresqlProfile(Profile):
	def __init__(self):
		super().__init__(
			'Postgresql',
			ProfileType.ServerType,
			''
		)

	@property
	def packages(self) -> List[str]:
		return ['postgresql']

	@property
	def services(self) -> List[str]:
		return ['postgresql']

	def post_install(self, install_session: 'Installer'):
		install_session.arch_chroot("initdb -D /var/lib/postgres/data", run_as='postgres')