-
Notifications
You must be signed in to change notification settings - Fork 0
25 lines (25 loc) · 817 Bytes
/
demo.yml
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
name: Web server demo with podman and systemd
on:
push:
branch:
- main
jobs:
systemd_podman_web_server_demo:
runs-on: ubuntu-20.04
steps:
- name: Run actions/checkout for this repo
uses: actions/checkout@v2
with:
path: checkout_testing
persist-credentials: false
- name: Run a web server with podman in a user systemd service
run: |
loginctl enable-linger runner
sleep 1
ls /run/user/$UID
podman pull docker.io/library/nginx:latest
mkdir -p $HOME/.config/systemd/user
cp checkout_testing/webserver.service $HOME/.config/systemd/user
XDG_RUNTIME_DIR=/run/user/$UID systemctl --user enable --now webserver.service
sleep 1
curl http://localhost:8080