Skip to content

Commit

Permalink
fix: chart api 수정
Browse files Browse the repository at this point in the history
  • Loading branch information
wndjs803 committed Jan 30, 2024
1 parent 55a36ba commit a19d702
Show file tree
Hide file tree
Showing 2 changed files with 28 additions and 28 deletions.
4 changes: 2 additions & 2 deletions backend/chart/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,12 +38,12 @@ def get(self, request):
return Response({'error': '유저가 존재하지 않습니다.'}, status=status.HTTP_400_BAD_REQUEST)

# 유저의 각 구독 채널 정보 가져오기
user_subscribes = Summary.objects.filter(user_id=user_id).values('youtube_channel').distinct()
user_subscribes = Summary.objects.filter(user_id=user_id, deleted_at__isnull=True).values('youtube_channel').distinct()

channels = []
for subscribe in user_subscribes:
channel_name = subscribe['youtube_channel']
summary_count = Summary.objects.filter(user_id=user_id, youtube_channel=channel_name).count()
summary_count = Summary.objects.filter(user_id=user_id, youtube_channel=channel_name, deleted_at__isnull=True).count()

channels.append({
'youtube_channel': channel_name,
Expand Down
52 changes: 26 additions & 26 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -62,33 +62,33 @@ services:
environment:
- CELERY_BROKER_URL = 'amqp://admin:mypass@rabbit:5672'

nginx:
image: nginx:1.15-alpine
restart: unless-stopped
volumes:
# - ./data/nginx:/etc/nginx/conf.d
- ./data/certbot/conf:/etc/letsencrypt
- ./data/certbot/www:/var/www/certbot
- ./nginx/nginx.conf:/etc/nginx/nginx.conf
ports:
- "80:80"
- "443:443"
depends_on:
- backend
networks:
- t4y
command: '/bin/sh -c ''while :; do sleep 6h & wait $${!}; nginx -s reload; done & nginx -g "daemon off;"'''
# nginx:
# image: nginx:1.15-alpine
# restart: unless-stopped
# volumes:
# # - ./data/nginx:/etc/nginx/conf.d
# - ./data/certbot/conf:/etc/letsencrypt
# - ./data/certbot/www:/var/www/certbot
# - ./nginx/nginx.conf:/etc/nginx/nginx.conf
# ports:
# - "80:80"
# - "443:443"
# depends_on:
# - backend
# networks:
# - t4y
# command: '/bin/sh -c ''while :; do sleep 6h & wait $${!}; nginx -s reload; done & nginx -g "daemon off;"'''

certbot: #certbot
image: certbot/certbot
restart: unless-stopped
container_name: certbot
volumes:
- ./certbot/conf:/etc/letsencrypt
- ./certbot/www:/var/www/certbot
depends_on:
- nginx
entrypoint: "/bin/sh -c 'trap exit TERM; while :; do certbot renew; sleep 12h & wait $${!}; done;'"
# certbot: #certbot
# image: certbot/certbot
# restart: unless-stopped
# container_name: certbot
# volumes:
# - ./certbot/conf:/etc/letsencrypt
# - ./certbot/www:/var/www/certbot
# depends_on:
# - nginx
# entrypoint: "/bin/sh -c 'trap exit TERM; while :; do certbot renew; sleep 12h & wait $${!}; done;'"

# prometheus:
# image: prom/prometheus
Expand Down

0 comments on commit a19d702

Please sign in to comment.