diff --git a/.gitea/workflows/actions.yaml b/.gitea/workflows/actions.yaml new file mode 100644 index 0000000..ab162ef --- /dev/null +++ b/.gitea/workflows/actions.yaml @@ -0,0 +1,45 @@ +name: Prepare Build and Testing executable binary +run-name: ${{ gitea.actor }} +on: [push] + +jobs: + Prepare-Build-Testing-With-Make: + runs-on: alpine-sdk + steps: + - name: prepare-container + run: | + echo "192.168.3.113 gitea.home.com" >> /etc/hosts + - name: Check out repository code + uses: actions/checkout@v3 + - name: Building binary with make + run: make -j$(nproc) + + Prepare-Build-Testing-With-CMake: + runs-on: alpine-sdk + steps: + - name: prepare-container + run: | + echo "192.168.3.113 gitea.home.com" >> /etc/hosts && \ + apk add cmake + - name: Check out repository code + uses: actions/checkout@v3 + - name: Building binary with CMake + run: | + mkdir build && \ + cd build && \ + cmake .. && \ + make -j$(nproc) + + Prepare-Build-Testing-With-Meson: + runs-on: alpine-sdk + steps: + - name: prepare-container + run: | + echo "192.168.3.113 gitea.home.com" >> /etc/hosts && \ + apk add meson ninja cmake + - name: Check out repository code + uses: actions/checkout@v3 + - name: Building binary with meson + run: | + meson setup build && \ + ninja -C build diff --git a/.gitignore b/.gitignore index af6ce43..8f6ff03 100644 --- a/.gitignore +++ b/.gitignore @@ -4,6 +4,6 @@ .idea build builddir -fmongoose +auth_service users.db *.swp diff --git a/CMakeLists.txt b/CMakeLists.txt index e1914cd..115c0f5 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,5 +1,5 @@ cmake_minimum_required (VERSION 3.6) -project(fmongoose LANGUAGES C) +project(auth_service LANGUAGES C) set(CMAKE_C_STANDARD 23) set(CMAKE_EXPORT_COMPILE_COMMANDS ON) @@ -11,8 +11,8 @@ FILE(GLOB_RECURSE SOURCES src/*.c) find_package(SQLite3 REQUIRED) add_executable( - fmongoose + auth_service ${SOURCES} ) -target_link_libraries(fmongoose ssl crypto sqlite3 pthread) +target_link_libraries(auth_service ssl crypto sqlite3 pthread) diff --git a/Makefile b/Makefile index f267588..2f0da38 100644 --- a/Makefile +++ b/Makefile @@ -5,7 +5,7 @@ LIBS = -lpthread -lcrypto -lsqlite3 INCLUDES = -I./src/lib -I./src SRCS = $(wildcard src/*.c src/lib/*.c) OBJS = $(SRCS:.c=.o) -TARGET = fmongoose +TARGET = auth_service BUILD_DIR=./build CROSS_COMPILE = diff --git a/meson.build b/meson.build index 85c3ed0..f111476 100644 --- a/meson.build +++ b/meson.build @@ -1,8 +1,8 @@ -project('fmongoose', 'c', default_options: ['c_std=gnu2x']) +project('auth_service', 'c', default_options: ['c_std=gnu2x']) include_dirs = include_directories('src', 'src/lib') deps = [dependency('openssl'), dependency('sqlite3')] executable( - 'fmongoose', + 'auth_service', 'src/main.c', 'src/user.c', 'src/add_user.c', diff --git a/web/index.html b/web/index.html index 7c1b18f..abd3506 100644 --- a/web/index.html +++ b/web/index.html @@ -3,7 +3,7 @@ - fmongoose + auth_service

it's work

-
+

Login

- + - +