Skip to content

Commit

Permalink
Merge pull request #244 from team9502/dev
Browse files Browse the repository at this point in the history
배포
  • Loading branch information
daeundada authored Jun 29, 2024
2 parents a8e248e + 38bc821 commit 1be6344
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 3 deletions.
14 changes: 13 additions & 1 deletion .github/workflows/sinChul.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,19 @@ jobs:
target: "/home/ec2-user"
strip_components: 2


- name: Stop existing Green Server
uses: appleboy/[email protected]
with:
host: ${{ secrets.SSH_HOST }}
username: ec2-user
key: ${{ secrets.SSH_KEY }}
port: 22
script_stop: true
script: |
PID=$(lsof -t -i:8081)
if [ -n "$PID" ]; then
sudo kill -9 $PID
fi
- name: Deploy to Green Server
uses: appleboy/[email protected]
with:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ public class RedisSubscriber implements MessageListener {
public void onMessage(Message message, byte[] pattern) {
try {
ChatMessage chatMessage = objectMapper.readValue(message.getBody(), ChatMessage.class);

messagingTemplate.convertAndSend("/topic/chatroom/" +
chatMessage.getChatRoom().getChatRoomId(), chatMessage);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,6 @@ public ChannelTopic topic() {
@Bean
public MessageListenerAdapter messageListener(RedisSubscriber subscriber) {

return new MessageListenerAdapter(subscriber);
return new MessageListenerAdapter(subscriber, "onMessage");
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,8 @@ public SecurityFilterChain securityFilterChain(HttpSecurity http) throws Excepti
"/cpUsers/{cpUserId}/profile",
"/business/status",
"/business/verify",
"/faqs/**"
"/faqs/**",
"/ws"
).permitAll()
.requestMatchers(HttpMethod.GET,
"/cpUsers",
Expand Down

0 comments on commit 1be6344

Please sign in to comment.