Skip to content

Commit

Permalink
Merge pull request #2 from thisiscleverson/development
Browse files Browse the repository at this point in the history
Development
  • Loading branch information
thisiscleverson authored Mar 27, 2024
2 parents 6038fb4 + 794db12 commit 311f992
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 2 deletions.
5 changes: 3 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,5 +20,6 @@ jobs:
REMOTE_HOST: ${{ secrets.HOST }}
REMOTE_USER: ${{ secrets.USERNAME }}
TARGET: ${{ secrets.TARGET }}
EXCLUDE: ".env, /test/, .gitignore"

EXCLUDE: ".env, /test/, .gitignore, README.md"
SCRIPT_AFTER: |
make deploy
4 changes: 4 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
deploy:
sudo mv ~/http-server.service /etc/systemd/system/ \
&& sudo systemctl enable http-server \
&& sudo systemctl restart http-server \
12 changes: 12 additions & 0 deletions http-server.service
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
[Unit]
Description=My Docker Application
Requires=docker.service
After=docker.service

[Service]
Restart=always
ExecStart=/usr/local/bin/docker-compose -f /var/www/blog/docker-compose.yml up
ExecStop=/usr/local/bin/docker-compose -f /var/www/blog/docker-compose.yml down

[Install]
WantedBy=multi-user.target

0 comments on commit 311f992

Please sign in to comment.