Skip to content

Commit

Permalink
display-right-localhost-url
Browse files Browse the repository at this point in the history
  • Loading branch information
atas committed Dec 11, 2023
1 parent 6c91433 commit 824daee
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 10 deletions.
14 changes: 7 additions & 7 deletions .github/workflows/build-deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ jobs:
runs-on: ubuntu-latest

container:
image: ghcr.io/atas/ssg-builder:202310152231
image: ghcr.io/atas/ssg-builder:202312111157

steps:
- name: Checkout repository
Expand All @@ -47,13 +47,13 @@ jobs:
- name: Run Ata's SSG HTML Builder
uses: atas/[email protected]
with:
less_file_path: 'assets/styles/style.less'
less_file_path: "assets/styles/style.less"

- name: Upload artifact
uses: actions/upload-artifact@v2
with:
name: 'html'
path: 'html'
name: "html"
path: "html"

deploy:
environment:
Expand All @@ -71,14 +71,14 @@ jobs:
- name: Download artifact
uses: actions/download-artifact@v2
with:
name: 'html'
path: './html'
name: "html"
path: "./html"

- name: Upload artifact
uses: actions/upload-pages-artifact@v2
with:
# Upload entire repository
path: 'html'
path: "html"

- name: Deploy to GitHub Pages
id: deployment
Expand Down
7 changes: 5 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,11 @@

CONTAINER_IMAGE := $(shell grep 'image:' .github/workflows/build-deploy.yml | sed -e 's/image://g' | tr -d ' \t')

# Define a variable for the port number
DEV_SERVER_PORT := 8002

dev-server:
@echo "Starting dev server on image $(CONTAINER_IMAGE)"
@echo "Starting dev server on image $(CONTAINER_IMAGE) at\n-----------\nhttp://localhost:$(DEV_SERVER_PORT)\n-----------"
@chmod 777 tmp
docker run --rm -it --entrypoint /dev-server-entrypoint.sh -p 8001:80 \
docker run --rm -it --entrypoint /dev-server-entrypoint.sh -p $(DEV_SERVER_PORT):80 \
-v $(shell pwd):/workspace $(CONTAINER_IMAGE)
2 changes: 1 addition & 1 deletion config.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,4 @@
"github_url": "https://github.com/atas",
"location": "City, Country",
"default_opengraph_image": "assets/images/site-icon-big.jpg"
}
}
3 changes: 3 additions & 0 deletions layout/header.php
Original file line number Diff line number Diff line change
Expand Up @@ -142,8 +142,11 @@
<?php } ?>
</div>

<?php if (isset($ssg->config->location) && strlen($ssg->config->location) > 0) { ?>
<div class="location">
<img src="/assets/images/location.svg" alt="Location Icon"/>
<?= $ssg->config->location ?>
</div>
<?php } ?>

<div class="clear"></div>

0 comments on commit 824daee

Please sign in to comment.