-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #2 from NBISweden/push-static-files
Push static files
- Loading branch information
Showing
44 changed files
with
6,463 additions
and
14 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
web/content/datasets/* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
name: Push | ||
on: | ||
push: | ||
branches: | ||
- master | ||
|
||
jobs: | ||
publish-image: | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
|
||
- name: Login to GitHub Container Registry | ||
uses: docker/login-action@v1 | ||
with: | ||
registry: ghcr.io | ||
username: ${{ github.actor }} | ||
password: ${{ secrets.GITHUB_TOKEN }} | ||
- name: Build and push | ||
uses: docker/build-push-action@v5 | ||
with: | ||
context: . | ||
file: ./Dockerfile | ||
push: true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,7 @@ | ||
web/* | ||
web/public/ | ||
dev_utils/config.yaml | ||
web/static/img/m_p_b/ | ||
web/static/img/m_p_c/ | ||
web/static/img/m_p_p/ | ||
web/static/img/m_r_f/ | ||
web/content/datasets/* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,16 @@ | ||
FROM golang:1.20.3-alpine3.17 as build | ||
|
||
WORKDIR /lp_app | ||
COPY . . | ||
ENV GO111MODULE=on | ||
ENV GOPATH=$PWD | ||
ENV GOOS=linux | ||
RUN go build -o /test . | ||
|
||
ENV CGO_ENABLED=0 | ||
RUN go build -o test . | ||
|
||
FROM alpine:3.17 | ||
|
||
WORKDIR /gen_app | ||
RUN apk add --repository=https://dl-cdn.alpinelinux.org/alpine/edge/community hugo | ||
COPY --from=build /test /gen_app/ | ||
RUN apk add --no-cache --repository=https://dl-cdn.alpinelinux.org/alpine/edge/community hugo | ||
COPY --from=build /lp_app/test /gen_app | ||
COPY dev_utils . | ||
CMD ["/gen_app/test"] | ||
COPY /web /web | ||
|
||
CMD ["./test"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,22 @@ | ||
# bp-landing-pages | ||
# Bigpicture-landing-pages-service | ||
Bigpicture project dataset landing page generator | ||
|
||
|
||
## Development environment | ||
|
||
To start S3 minio service, navigate to dev_utils folder and run | ||
|
||
``` | ||
docker compose up | ||
``` | ||
|
||
Set config.yaml in environment file | ||
|
||
``` | ||
export CONFIGFILE="dev_utils/config.yaml" | ||
``` | ||
|
||
Start the application by running | ||
``` | ||
go run . | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,22 @@ | ||
package main | ||
|
||
import ( | ||
"os/exec" | ||
|
||
log "github.com/sirupsen/logrus" | ||
) | ||
|
||
func main() { | ||
log.Infoln("started app successfully") | ||
mConf := getConfig() | ||
Metadataclient := connect_to_s3(mConf) | ||
mConf := getMetadataConfig() | ||
Metadataclient := connectMetadatas3(mConf) | ||
log.Infof("Connection to the bucket established") | ||
metadataDownloader(Metadataclient) | ||
cmd := exec.Command("hugo") | ||
cmd.Dir = "./web/" | ||
cmd.Run() | ||
log.Infof("Hugo successfully built") | ||
deConf := getDeploymentConfig() | ||
connectDeployments3(deConf) | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
--- | ||
title: "An Example Post" | ||
subtitle: "" | ||
description: "" | ||
date: 2018-06-04 | ||
author: "" | ||
image: "" | ||
tags: ["tag1", "tag2"] | ||
categories: ["Tech" ] | ||
--- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
--- | ||
title: "{{ replace .Name "-" " " | title }}" | ||
date: {{ .Date }} | ||
draft: true | ||
--- | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
baseurl = "https://nbisweden.github.io/hugo.bp.datasets.nbis.se" | ||
title = "Bigpicture datasets" | ||
languageCode = "en-us" | ||
preserveTaxonomyNames = true | ||
paginate = 5 #frontpage pagination | ||
|
||
|
||
[params] | ||
header_image = "img/bigpicture-banner.jpg" | ||
SEOTitle = "Bigpicture datasets" | ||
slogan = "Demo site for Bigpicture landing pages using HUGO" | ||
|
||
image_404 = "img/404-bg.jpg" | ||
|
||
# Sidebar settings | ||
sidebar_about_description = "Bigpicture dataset description pages" | ||
sidebar_avatar = "img/bigpicture_logo.svg" # use absolute URL, seeing it's used in both `/` and `/about/` | ||
|
||
|
||
[[params.addtional_menus]] |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Oops, something went wrong.