deployment: Generate deb and rpm packages (#1458)

This commit is contained in:
Travis Groth 2020-09-28 13:33:35 -04:00 committed by GitHub
parent 1a9ac2fef5
commit cef1449458
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
6 changed files with 130 additions and 0 deletions

22
ospkg/conf/config.yaml Normal file
View file

@ -0,0 +1,22 @@
# Required settings below. See complete documentation at https://www.pomerium.com/reference/
# To run on :443 set AmbientCapabilities=CAP_NET_BIND_SERVICE
# in a systemd override
address: :8443
authenticate_service_url: https://authenticate.localhost.pomerium.io
certificates:
- cert: /etc/pomerium/cert.pem
key: /etc/pomerium/key.pem
shared_secret: XXXXXX
cookie_secret: YYYYY
idp_provider: "google"
idp_client_id: XXXX
idp_client_secret: YYYY
idp_service_account: XXXXXX
policy:
- from: https://yoursite.localhost.pomerium.io
to: https://yoursite.local
allowed_users:
- user@domain.com

11
ospkg/pomerium.service Normal file
View file

@ -0,0 +1,11 @@
[Unit]
Description=Pomerium
[Service]
ExecStart=/usr/sbin/pomerium -config /etc/pomerium/config.yaml
User=pomerium
Group=pomerium
Environment=AUTOCERT_DIR=/etc/pomerium/
[Install]
WantedBy=multi-user.target

4
ospkg/postinstall.sh Normal file
View file

@ -0,0 +1,4 @@
#!/bin/bash
chown pomerium:pomerium -R /etc/pomerium
chmod 750 /etc/pomerium

5
ospkg/preinstall.sh Executable file
View file

@ -0,0 +1,5 @@
#!/bin/bash
if ! getent passwd pomerium >/dev/null; then
useradd --system -d / -s /sbin/nologin pomerium
fi