registeremail/Makefile

21 lines
797 B
Makefile
Raw Normal View History

2024-03-13 03:48:47 +00:00
.PHONY: install uninstall
createemail: email.c
gcc -o createemail email.c -lcrypt -ljansson
install: createemail
cp createemail /usr/local/bin/createemail
chmod 4755 /usr/local/bin/createemail
chown root:root /usr/local/bin/createemail
dotnet publish -o out --self-contained -c Release -p:PublishReadyToRun=true -p:PublishSingleFile=true -r linux-x64
mkdir /opt/RegisterEmail
2024-03-13 05:18:34 +00:00
cp out/RegsiterEmail /opt/RegisterEmail/RegisterEmail
2024-03-13 03:48:47 +00:00
cp -r www /opt/RegisterEmail/www
cp createemail.service /etc/systemd/system/createemail.service
systemctl enable createemail.service
systemctl start createemail.service
uninstall:
systemctl stop createemail.service
systemctl disable createemail.service
rm /etc/systemd/system/createemail.service
rm -r /opt/RegisterEmail
rm /usr/local/bin/createemail