Git Product home page Git Product logo

coscup-volunteer's Introduction

COSCUP Volunteer

COSCUP Volunteer 志工服務系統,主要解決招募、人員管理、行政流程建立。 https://volunteer.coscup.org/

License

GNU Affero General Public License version 3 (AGPL-3.0)

For Developer

目前我們使用 docker compose 的方式進行開發,可以使用 docker compose up 來建立與啟動必要的服務。完成後可以連到 http://127.0.0.1:80 看到首頁!

Code Style

已知問題

  • 登入認證目前還不能使用,還在處理開發時的臨時帳號登入方式。開發時會使用 Dockerfile-app-dev 來建立 images。
  • 目前還沒有開發時的測試資料。

目前開發重點

  • 提升 testing cases 的涵蓋率
  • 開發帳號與資料預建立

For Production

Build Image

需要 Docker 來建立 Image。

sh ./build-base.sh && sh ./build-app.sh

Start

啟動服務,使用到 MongoDB、RabbitMQ

sh ./start_mongo.sh && sh ./start_rabbitmq.sh && sh ./start_celery.sh

啟動 web app

sh ./start_app.sh

如果有修正後的重啟,可以直接執行

sh ./restart_app.sh

Local Development

安裝依賴

您可能需要先安裝 libmemcachedpoetry,才能安裝依賴。

brew install libmemcached  # macOS

Poetry 的安裝請使用官方文件建議安裝在全域環境。

curl -sSL https://raw.githubusercontent.com/python-poetry/poetry/master/get-poetry.py | python3 -

設定 VS Code

找到 poetry 建立的 virtual environment:

poetry env list --full-path

然後 Cmd + Shift + P,輸入 Python: Select Interpreter, 選擇 輸入直譯器路徑,填入路徑即可。

Build from Docker Compose

We use the docker compose (not docker-compose) to run the project in containers, please pre-install Docker Engine or Docker Desktop before getting started.

Build the base images first. (Notice: In this way, you no need to sign in to Docker Desktop account.)

docker build -t coscupweb-base:22.06.13 -f ./Dockerfile-base-dev ./

Setup the setting.py

cp setting_sample.py setting.py

Edit the setting.py, make MONGO_MOCK to be False.

Build the rest of app images

docker compose build --no-cache

Or directly execute up to build and run ...

docker compose up --build

Wait an amount until all services are available, open browser and visit to:

http://127.0.0.1:80/

Notice: Because of the cookie with secure attributes (__Host-) at local in 127.0.0.1 is not allowed for Chrome and Safari (1056543, 1263426), the following steps are works only in Firefox.

To create a user for dev

docker compose run --rm cmdapp dev user_add

This command will create an user account and register an session, so you need to feed the cookie for your browser.

http://127.0.0.1/dev/cookie?sid={sid}

Visit the dev page to setup.

http://127.0.0.1:80/dev/

如何貢獻專案 How to contribute?

The more details about how to contribute, please learn more from Volunteer Docs.

Fork me

  1. 使用 github fork 的方式建立一份到自己的帳號底下。(詳細的操作可以參考 Working with forks
  2. 參考 README.mdLocal Development 先建立起本地端開發環境。

Create a Pull Request(PR)

如果你的開發很順利,覺得可以送出一版 PR 讓我們 review,也請透過 Github create a pull request 的方式發給我們!

More Details

  1. 請先閱讀開發文件中的 Introduction,了解平台的架構與服務。
  2. 查看目前已知的問題 Issues
  3. 查看目前的開發 roadmap
  4. 或是到 COSCUP 行政組 - 開發組頻道討論。

更詳細的開發內容可以參考開發文件

Issues

問題回報請使用 Issues、如果遇到安全問題的回報,可以使用 GPG 加密後回報。

coscup-volunteer's People

Contributors

bobchao avatar daluntw avatar pan93412 avatar toomore avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.