Created
September 19, 2018 04:32
-
-
Save holishing/389d496b0fcda814f8899eb7eb065dad to your computer and use it in GitHub Desktop.
pttbbs for WSL batch file
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env bash | |
| sudo groupadd --gid 99 bbs \ | |
| && useradd -g bbs -s /bin/bash --uid 9999 bbs \ | |
| && mkdir /home/bbs \ | |
| && chown -R bbs:bbs /home/bbs | |
| sudo apt update \ | |
| && apt upgrade -y \ | |
| && apt-get install -y --no-install-recommends \ | |
| bmake \ | |
| ccache \ | |
| clang \ | |
| curl \ | |
| ca-certificates \ | |
| libevent-dev \ | |
| pkg-config \ | |
| python | |
| sudo -u bbs sh -c '\ | |
| && cd /home/bbs \ | |
| && sh -c "curl -L https://github.com/ptt/pttbbs/archive/ae32c2897c33e3a62f8fc58ced187337cd4c6fd4.tar.gz | tar -zxv" \ | |
| && mv pttbbs-ae32c2897c33e3a62f8fc58ced187337cd4c6fd4 pttbbs \ | |
| && cd /home/bbs/pttbbs \ | |
| && echo "#define TIMET64" >> /home/bbs/pttbbs/pttbbs.conf \ | |
| && echo "#define SHMALIGNEDSIZE (1048576*4)" >> /home/bbs/pttbbs/pttbbs.conf \ | |
| && cd /home/bbs/pttbbs && bmake all install clean \ | |
| && cd /home/bbs/pttbbs/sample \ | |
| && bmake install \ | |
| && /home/bbs/bin/initbbs -DoIt' | |
| sudo -u bbs sh -c '/home/bbs/bin/shmctl init' | |
| sudo /home/bbs/bin/mbbsd -d -p 23 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| bash.exe -c "./installptt.sh" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment