This commit is contained in:
parent
06c399c472
commit
1e67b110fe
@ -23,7 +23,7 @@ jobs:
|
||||
ssh-keyscan -t ed25519 -p 22022 frp-by1.wwvvww.cn >> ~/.ssh/known_hosts
|
||||
- name: Clone repository
|
||||
run: |
|
||||
echo "git clone --depth 1 --branch=${GITHUB_REF##*/} ssh://git@frp-by1.wwvvww.cn:22022/${{ gitea.repository }}.git"
|
||||
echo "git clone --depth 10 --branch=${GITHUB_REF##*/} ssh://git@frp-by1.wwvvww.cn:22022/${{ gitea.repository }}.git"
|
||||
git clone --depth 1 --branch=${GITHUB_REF##*/} ssh://git@frp-by1.wwvvww.cn:22022/${{ gitea.repository }}.git .
|
||||
git checkout ${GITHUB_SHA}
|
||||
- name: Notify-Start
|
||||
|
@ -70,8 +70,8 @@ int main(int argc, char const *argv[]) {
|
||||
BOOST_ASSERT_MSG(!application->getServer().empty(), "server.empty() == true");
|
||||
|
||||
auto address = boost::asio::ip::make_address(application->getServer());
|
||||
auto listener = std::make_shared<Listener>(application->ioContext(),
|
||||
boost::asio::ip::tcp::endpoint{address, application->getPort()});
|
||||
auto listener =
|
||||
std::make_shared<Listener>(application->ioContext(), boost::asio::ip::tcp::endpoint{address, application->getPort()});
|
||||
listener->startAccept();
|
||||
|
||||
auto wechatContext = Singleton<WeChatContext>::instance<Construct>(application->ioContext());
|
||||
@ -101,7 +101,7 @@ int main(int argc, char const *argv[]) {
|
||||
|
||||
auto udpServer = std::make_shared<UdpServer>(application->ioContext());
|
||||
auto mediaServer = std::make_shared<MediaServer>(554, false);
|
||||
auto webApp = Singleton<WebApplication>::instance<Construct>(application->getWtPort());
|
||||
auto webApp = Singleton<WebApplication>::instance<Construct>(application->getWtPort(), application->getDocumentRoot());
|
||||
|
||||
using namespace boost::asio::ip;
|
||||
auto proxyAddress = make_address(application->getServer());
|
||||
|
@ -14,11 +14,11 @@
|
||||
#include <Wt/WServer.h>
|
||||
#include <format>
|
||||
|
||||
WebApplication::WebApplication(uint16_t port) {
|
||||
WebApplication::WebApplication(uint16_t port, const std::string &documentRoot) {
|
||||
try {
|
||||
std::vector<std::string> args;
|
||||
args.push_back("--approot=./build");
|
||||
args.push_back("--docroot=./build");
|
||||
args.push_back(std::format("--docroot={}", documentRoot));
|
||||
args.push_back("--config=resources/wt_config.xml");
|
||||
args.push_back(std::format("--http-listen=127.0.0.1:{}", port));
|
||||
// --docroot=. --no-compression --http-listen 127.0.0.1:8855
|
||||
|
@ -31,7 +31,7 @@ public:
|
||||
const Wt::Auth::PasswordService &passwordService();
|
||||
|
||||
protected:
|
||||
WebApplication(uint16_t port);
|
||||
WebApplication(uint16_t port, const std::string &documentRoot);
|
||||
static std::unique_ptr<Wt::Dbo::SqlConnectionPool> createConnectionPool(const std::string &sqlite3);
|
||||
std::unique_ptr<Wt::WApplication> createApplication(const Wt::WEnvironment &env, bool embedded);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user