diff --git a/.github/workflows/cd.yaml b/.github/workflows/cd.yaml
index 7647117..b2031cb 100644
--- a/.github/workflows/cd.yaml
+++ b/.github/workflows/cd.yaml
@@ -2,12 +2,28 @@ name: 'CD'
on:
workflow_dispatch:
+ inputs:
+ tag:
+ description: 'Tag to change to'
+ default: 'latest'
+ required: false
+ type: string
+
+env:
+ IMAGE_NAME: registry.digitalocean.com/cutu2024/cutu2024-backend
jobs:
deploy:
runs-on: ubuntu-latest
steps:
+ - name: Set new image tag
+ uses: actions-hub/kubectl@master
+ env:
+ KUBE_CONFIG: ${{ secrets.KUBE_CONFIG }}
+ with:
+ args: set image deployment/cutu2024-backend cutu2024-backend=${{ env.IMAGE_NAME }}:${{ inputs.tag }}
+
- name: Rollout new deployment
uses: actions-hub/kubectl@master
env:
diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml
index c9ff562..b871e56 100644
--- a/.github/workflows/ci.yaml
+++ b/.github/workflows/ci.yaml
@@ -1,10 +1,13 @@
name: 'CI'
on:
- push:
- branches:
- - main
workflow_dispatch:
+ inputs:
+ tag:
+ description: 'Image tag'
+ default: 'latest'
+ required: false
+ type: string
env:
IMAGE_NAME: registry.digitalocean.com/cutu2024/cutu2024-backend
diff --git a/apps/web/src/app/(screen)/display/components/FootBallSlider.tsx b/apps/web/src/app/(screen)/display/components/FootBallSlider.tsx
index a04fa20..f8dec12 100644
--- a/apps/web/src/app/(screen)/display/components/FootBallSlider.tsx
+++ b/apps/web/src/app/(screen)/display/components/FootBallSlider.tsx
@@ -52,7 +52,7 @@ const FootBallSlider = (props: FootBallSliderProps) => {
transition: "left 0.3s ease",
}}
>
-
{
return (
-
+
-
+
{
const OverLay = ({data}: OverLayProps) => {
+
return (
diff --git a/apps/web/src/app/(screen)/screen/page.tsx b/apps/web/src/app/(screen)/screen/page.tsx
index 65f3bd0..3c9f283 100644
--- a/apps/web/src/app/(screen)/screen/page.tsx
+++ b/apps/web/src/app/(screen)/screen/page.tsx
@@ -14,8 +14,9 @@ const Screen = () => {
cu: 50,
tu: 50
})
- const cookies = new Cookies( null, { path: "/" } )
+ const cookies = new Cookies( null, {httpOnly: true} )
console.log(data)
+ //console.log('show: ', showedPage)
useEffect(() => {
const handleConnect = (socket: Socket) => {
@@ -31,13 +32,13 @@ const Screen = () => {
const cuScore = Math.round(parseFloat(parts[1]));
const tuScore = Math.round(parseFloat(parts[3]));
- //console.log({cuScore, tuScore} )
+ //console.log({cuScore, tuScore})
setData(data => ({...data, cu: cuScore, tu: tuScore}))
}
const handleScreen = (screen: string) => {
- //console.log(screen);
- //setShowPage('full' ? 'overlay' : 'display')
+ console.log(screen);
+ setShowPage(screen == 'overlay' ? 'overlay' : 'display')
}
const handleCid = (serverCid: string) => {
@@ -103,9 +104,9 @@ const Screen = () => {
}, []);
return (
-
+
{showedPage == "overlay" ? : }
-
+ {/* */}
);
}
diff --git a/apps/web/src/app/(user)/shake/[university]/page.tsx b/apps/web/src/app/(user)/shake/[university]/page.tsx
index cd13e25..9032edd 100644
--- a/apps/web/src/app/(user)/shake/[university]/page.tsx
+++ b/apps/web/src/app/(user)/shake/[university]/page.tsx
@@ -22,7 +22,7 @@ export default function Shake() {
const cookies = new Cookies();
const [ socketState, setSocketState ] = useState
(null)
- const temp = setTimeout(() => {
+ /* const temp = setTimeout(() => {
setCount(prevCount => {
const newCount = prevCount + 1;
if (socketState?.connected) {
@@ -30,7 +30,7 @@ export default function Shake() {
}
return newCount;
});
- }, 100)
+ }, 100) */
useEffect(() => {
const handleConnect = () => {