File: docker.yml

package info (click to toggle)
weakforced 3.0.0-4
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 3,196 kB
  • sloc: cpp: 20,397; python: 2,002; sh: 700; makefile: 432
file content (36 lines) | stat: -rw-r--r-- 2,111 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
---
name: 'Build docker image and test'

on:
  push:
  pull_request:

jobs:
  docker_test:
    name: docker_test
    runs-on: ubuntu-22.04
    steps:
      - uses: actions/checkout@v4
        with:
          fetch-depth: 0
          submodules: recursive
      - name: Install dependencies
        run: sudo apt-get update && sudo apt-get -qq -y install asciidoctor gcc g++ cmake libboost-all-dev libcurl4-openssl-dev libgetdns-dev libhiredis-dev libmaxminddb-dev libluajit-5.1-dev libprotobuf-dev libreadline-dev libssl-dev libsodium-dev libsystemd-dev libyaml-cpp-dev libjsoncpp-dev uuid-dev libz-dev libtool pkg-config protobuf-compiler wget autoconf automake
      - name: Download prometheus-cpp
        run: git clone https://github.com/jupp0r/prometheus-cpp.git && cd prometheus-cpp && git checkout tags/v1.0.1 -b v1.0.1
      - name: Build and Install prometheus-cpp
        run: cd prometheus-cpp && mkdir _build && cd _build && cmake .. -DBUILD_SHARED_LIBS=off -DENABLE_PULL=off -DENABLE_PUSH=off -DENABLE_COMPRESSION=off -DENABLE_TESTING=off -DCMAKE_C_COMPILER=gcc -DCMAKE_CXX_COMPILER=g++ -DCMAKE_POSITION_INDEPENDENT_CODE=ON && make && sudo make install
      - name: Download Drogon
        run: git clone https://github.com/drogonframework/drogon.git && cd drogon && git checkout tags/v1.9.1 -b v1.9.1
      - name: Build and Install Drogon
        run: cd drogon && git submodule init && git submodule update && mkdir _build && cd _build && cmake .. -DBUILD_ORM=OFF -DCMAKE_BUILD_TYPE=Release && make && sudo make install
      - run: sudo sysctl -w vm.max_map_count=262144
      - run: autoreconf -i
      - run: ./configure --enable-docker --disable-dns --disable-sodium --disable-geoip
      - run: cd docker/wforce_image && make test_wforce_image
      - run: cd docker/wforce_image && make build_wforce_image
      - run: cd docker && bash docker_push.sh "${{ env.DOCKER_ORGNAME }}/wforce"
        env:
          DOCKER_PASSWORD: ${{ secrets.DOCKERHUB_TOKEN }}
          DOCKER_USERNAME: ${{ secrets.DOCKERHUB_USERNAME }}
          DOCKER_ORGNAME: ${{ secrets.DOCKERHUB_ORGANIZATION_NAME }}