Skip to content

Commit b734478

Browse files
ci: minimize the workflow
1 parent 822fa5b commit b734478

1 file changed

Lines changed: 5 additions & 21 deletions

File tree

.github/workflows/deploy.yml

Lines changed: 5 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -41,23 +41,6 @@ jobs:
4141
environment: production
4242

4343
steps:
44-
- name: Checkout code
45-
uses: actions/checkout@v4
46-
with:
47-
ref: release
48-
49-
- name: Setup Node.js
50-
uses: actions/setup-node@v4
51-
with:
52-
node-version: ${{ env.NODE_VERSION }}
53-
cache: 'yarn'
54-
55-
- name: Install dependencies
56-
run: yarn install --frozen-lockfile
57-
58-
- name: Setup Docker Buildx
59-
uses: docker/setup-buildx-action@v3
60-
6144
- name: Add VPS to known hosts
6245
run: |
6346
mkdir -p ~/.ssh
@@ -98,8 +81,8 @@ jobs:
9881
sudo rm -rf /var/www/$APP_NAME/dist
9982
sudo mv dist /var/www/$APP_NAME/
10083
101-
# Set proper ownership for nginx to serve files
102-
sudo chown -R www-data:www-data /var/www/$APP_NAME/dist
84+
# Make the file globally readable
85+
sudo chmod -R a+rX /var/www/$APP_NAME/dist
10386
10487
# Check if nginx config has changed and update if needed
10588
if ! cmp -s nginx/nginx.conf /etc/nginx/sites-available/$NGINX_SITE_NAME.conf; then
@@ -110,6 +93,7 @@ jobs:
11093
fi
11194
11295
# Cleanup
113-
rm -rf dist
114-
# docker system prune -f
96+
docker system prune -f
11597
EOF
98+
99+
rm -f ~/.ssh/deploy_key

0 commit comments

Comments
 (0)