Commit b5bde748 authored by BO ZHANG's avatar BO ZHANG 🏀
Browse files

add original celery docker-compose.yaml

parent d6618e91
Loading
Loading
Loading
Loading

docker-celery/.env

0 → 100644
+10 −0
Original line number Diff line number Diff line
#AIRFLOW_IMAGE_NAME=apache/airflow:3.0.4
AIRFLOW_IMAGE_NAME=csst-airflow
AIRFLOW_UID=1000
AIRFLOW_PROJ_DIR=.
_AIRFLOW_WWW_USER_USERNAME=airflow
_AIRFLOW_WWW_USER_PASSWORD=airflow

JWT_SECRET=eyJhbGciOiJIUzUxMiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiJhaXJmbG93IiwiaWF0IjoxNzU1NDQ3NjMxLCJleHAiOjE3ODY5ODM2MzF9.CbxQayEt370iHhvYXhHMESsk1IWmi8QLMOcctIlbicXhybNtBbfboDUdUDMClwvkSuTjC0AOeSHL23pGyy0plQ
CSST_DFS_GATEWAY=10.80.1.22:28000
CSST_DFS_TOKEN=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjQ4ODU0NTA2NjQsInN1YiI6InN5c3RlbSJ9.POsuUABytu8-WMtZiYehiYEa5BnlgqNTXT6X3OTyix0
+10 −0
Original line number Diff line number Diff line
FROM apache/airflow:3.0.4

COPY requirements.txt .

RUN pip install --upgrade pip
# switch to tsinghua pip/conda source
RUN pip config set global.index-url https://pypi.tuna.tsinghua.edu.cn/simple/ \
    && pip config set global.extra-index-url "https://mirrors.bfsu.edu.cn/pypi/web/simple"
# install requirements
RUN pip install --no-cache-dir -r requirements.txt

docker-celery/Makefile

0 → 100644
+37 −0
Original line number Diff line number Diff line

all: down pull build init up

pull:
	git pull

mkdir:
	mkdir -p ./dags ./logs ./plugins ./config ./pg_data
	#echo -e "AIRFLOW_UID=$(id -u)" > .env

rmdir:
	rm -rf ./logs ./plugins ./config ./pg_data

build:
	docker build -t csst-airflow . --no-cache

init:
	docker compose up airflow-init

up:
	docker compose up -d

down:
	docker compose down

migrate:
	docker compose run --rm airflow-init airflow db upgrade

clean:
	# 停止服务并清理旧数据
	docker compose rm -sf

ps:
	docker compose ps

restart:
	docker compose restart
+6 −0
Original line number Diff line number Diff line
astropy
numpy
toml
pyyaml
git+https://csst-tb.bao.ac.cn/code/csst-cicd/csst-dag.git
git+https://csst-tb.bao.ac.cn/code/csst-dfs/csst-dfs-client.git
 No newline at end of file