mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-27 12:11:13 +00:00
16 lines
297 B
Bash
Executable file
16 lines
297 B
Bash
Executable file
#! /bin/sh
|
|
|
|
BASE_DIR=$(dirname $0)
|
|
|
|
OUTDIR=""
|
|
if [ $# -eq 1 ]; then
|
|
OUTDIR=$1/
|
|
fi
|
|
|
|
output=$(openssl req -x509 -newkey rsa:4096 -keyout ${OUTDIR}key.pem -out ${OUTDIR}cert.pem -days 365 -nodes -subj "/CN=example.com" 2>&1)
|
|
|
|
ret=$?
|
|
if [ ! $ret -eq 0 ]; then
|
|
echo "${output}" 1>&2
|
|
exit $ret
|
|
fi
|