Skip to content

Commit

Permalink
Cleaned up some documents and created a compile,build,pushworkflow fo…
Browse files Browse the repository at this point in the history
…r main
  • Loading branch information
SeriousHorncat committed Apr 12, 2024
1 parent aee57da commit 5751db8
Show file tree
Hide file tree
Showing 7 changed files with 89 additions and 493 deletions.
29 changes: 29 additions & 0 deletions .github/workflows/build-and-publish-docker-images.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
name: Compile & Publish

on:
push:
branches:
- main

env:
REGISTRY: ghcr.io

jobs:
build-and-push-image:
runs-on: ubuntu-22.04
steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: Log in to the Container Registry
uses: docker/login-action@v3
with:
registry: ${{ env.REGISTRY }}
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Build Docker Image
run: docker build --no-cache=true --tag=ghcr.io/uab-cgds-worthey/cgds-domain-home-page:latest -f Dockerfile .

- name: Publish to GitHub
run: docker push ghcr.io/uab-cgds-worthey/cgds-domain-home-page:latest
4 changes: 4 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
FROM nginx:1.25.2-alpine3.18
COPY ./etc/default.conf /etc/nginx/conf.d/
COPY ./src /usr/share/nginx/html/
EXPOSE 80
45 changes: 11 additions & 34 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,11 @@ Markdown](https://github.com/uab-cgds-worthey/cgds_repo_template/actions/workflo

A basic linkout home page for cgds.uab.edu. Main CGDS website is still https://sites.uab.edu/cgds

## How to install
## How to build

:pencil2: Add installation instructions here.

## How to run

:pencil2: Add run instructions here. This includes necessary configurations as well as the commands used.
```bash
docker build --no-cache=true --tag=ghcr.io/uab-cgds-worthey/cgds-domain-home-page:latest -f Dockerfile .
```

## Repo's directory structure

Expand All @@ -24,10 +22,6 @@ $ tree -a cgds_repo_template/
cgds_repo_template
├── CHANGELOG.md <- Log of changes made
├── CONTRIBUTING.md <- Contribution guidelines
├── LICENSE.md <- License for the repo
├── README.md
├── .gitignore <- Specifies intentionally untracked files to ignore by git
Expand All @@ -37,35 +31,18 @@ cgds_repo_template
├── .markdownlint.json <- Markdown linting config
├── .pylintrc <- Python linting config
├── configs <- Dir to store config files. Conda env, requirements.txt, etc.
├── data <- Dir structure from http://drivendata.github.io/cookiecutter-data-science. Please give it a read.
│   ├── external <- Data from third party sources
│   ├── interim <- Intermediate data that has been transformed
│   ├── processed <- The final, canonical datasets and results
│   └── raw <- The original, immutable data dump
├── docs <- Dir to store documentation.
├── notebooks <- Dir to store Jupyter, R Markdown notebooks, etc.
├── src <- Dir to store source code for use in this project
├── .github
│   ├── ISSUE_TEMPLATE <- Github issue templates
│   │   ├── bug_report.md
│   │   └── feature_request.md
│   ├── PULL_REQUEST_TEMPLATE <- Github PR templates
│   │   └── pull_request_template.md
│   └── workflows <- Github actions workflows for automated processes (eg. linting, etc)
│   └── linting.yml
├── .test <- Dir to store test datasets
│   └── README.md
└── logs <- Dir to store log files
   ├── ISSUE_TEMPLATE <- Github issue templates
   │   ├── bug_report.md
   │   └── feature_request.md
   ├── PULL_REQUEST_TEMPLATE <- Github PR templates
   │   └── pull_request_template.md
   └── workflows <- Github actions workflows for automated processes (eg. linting, etc)
   └── linting.yml

```
Expand Down
45 changes: 45 additions & 0 deletions etc/default.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
server {
listen 80;
server_name localhost;

#charset koi8-r;
#access_log /var/log/nginx/host.access.log main;

location / {
root /usr/share/nginx/html;
# index index.html index.htm;
try_files $uri $uri/ /index.html;
}

#error_page 404 /404.html;

# redirect server error pages to the static page /50x.html
#
error_page 500 502 503 504 /50x.html;
location = /50x.html {
root /usr/share/nginx/html;
}

# proxy the PHP scripts to Apache listening on 127.0.0.1:80
#
#location ~ \.php$ {
# proxy_pass http://127.0.0.1;
#}

# pass the PHP scripts to FastCGI server listening on 127.0.0.1:9000
#
#location ~ \.php$ {
# root html;
# fastcgi_pass 127.0.0.1:9000;
# fastcgi_index index.php;
# fastcgi_param SCRIPT_FILENAME /scripts$fastcgi_script_name;
# include fastcgi_params;
#}

# deny access to .htaccess files, if Apache's document root
# concurs with nginx's one
#
#location ~ /\.ht {
# deny all;
#}
}
Loading

0 comments on commit 5751db8

Please sign in to comment.