{"id":20112866,"url":"https://github.com/cloudacademy/web-echo-app","last_synced_at":"2025-03-02T18:44:05.356Z","repository":{"id":77791761,"uuid":"537212821","full_name":"cloudacademy/web-echo-app","owner":"cloudacademy","description":"Web Echo App","archived":false,"fork":false,"pushed_at":"2023-11-15T03:41:35.000Z","size":65,"stargazers_count":0,"open_issues_count":0,"forks_count":3,"subscribers_count":4,"default_branch":"main","last_synced_at":"2025-01-13T06:07:16.113Z","etag":null,"topics":["app","cloudacademy","container","devops","docker","go","kubernetes","web"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/cloudacademy.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2022-09-15T21:32:14.000Z","updated_at":"2022-09-19T01:26:43.000Z","dependencies_parsed_at":"2024-11-13T18:25:07.556Z","dependency_job_id":"2a018bf0-aaaa-49e0-b2d9-1b8c8a1a57ac","html_url":"https://github.com/cloudacademy/web-echo-app","commit_stats":null,"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cloudacademy%2Fweb-echo-app","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cloudacademy%2Fweb-echo-app/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cloudacademy%2Fweb-echo-app/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cloudacademy%2Fweb-echo-app/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/cloudacademy","download_url":"https://codeload.github.com/cloudacademy/web-echo-app/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":241557116,"owners_count":19981877,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["app","cloudacademy","container","devops","docker","go","kubernetes","web"],"created_at":"2024-11-13T18:22:52.815Z","updated_at":"2025-03-02T18:44:05.333Z","avatar_url":"https://github.com/cloudacademy.png","language":"Go","readme":"![Build Status](https://github.com/cloudacademy/web-echo-app/actions/workflows/go.yml/badge.svg) \n![GitHub release (latest SemVer)](https://img.shields.io/github/v/release/cloudacademy/web-echo-app)\n\n# Web Echo App\nA simple web based application that prints a message on a coloured background, both of which can be configured using environment variables.\n\n## Usage\nTo start the web application, configure the following optional environment variables:\n - `HOSTPORT=0.0.0.0:8080`\n - `MESSAGE=\"CloudAcademy ❤ DevOps\"`\n - `BACKGROUND_COLOR=yellow`\n - `AUTO_RELOAD=30`\n\n## Build\nThe following commands can be used to build and package the source code:\n\nCurrent operating system:\n```\ngo build .\n```\n\n**Linux** operating system:\n```\nCGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -o webapp\n```\n\n**macOS** operating system:\n```\nCGO_ENABLED=0 GOOS=darwin GOARCH=amd64 go build -o webapp\n```\n\nDocker:\n```\ndocker buildx build --platform=linux/amd64 -t cloudacademydevops/webappecho .\n```\n\n## Startup:\n\nExample 1:\n```\n./webapp\n```\n\nExample 2:\n```\nHOSTPORT=0.0.0.0:8080 MESSAGE=\"CloudAcademy ❤ DevOps\" BACKGROUND_COLOR=cyan ./webapp\n```\n\nExample 3:\n```\nHOSTPORT=0.0.0.0:8080 MESSAGE=\"CloudAcademy ❤ DevOps\" BACKGROUND_COLOR=yellow AUTO_RELOAD=30 ./webapp\n```\n\n![webapp](./docs/webapp.png)\n\n## Docker\nThe web application has been packaged into a Docker image. The Docker image can be pulled with the following command:\n\n```\ndocker pull cloudacademydevops/webappecho\n```\n\nUse the following command to launch the web echoing application within Docker:\n```\ndocker run --name webapp \\\n--env MESSAGE=CloudAcademy \\\n--env BACKGROUND_COLOR=yellow \\\n--env AUTO_RELOAD=30 \\\n-p 8080:8080 cloudacademydevops/webappecho\n```\n\n## Kubernetes\nUse the following command to launch the web echoing application as a Deployment resource within a cluster:\n\n```\ncat \u003c\u003c EOF | kubectl apply -f -\napiVersion: apps/v1\nkind: Deployment\nmetadata:\n  name: webecho\n  namespace: cloudacademy\n  labels:\n    app: webecho\n    version: v1\nspec:\n  replicas: 2\n  selector:\n    matchLabels:\n      app: webecho\n      version: v1\n  template:\n    metadata:\n      labels:\n        app: webecho\n        version: v1\n    spec:\n      containers:\n      - name: webecho\n        image: cloudacademydevops/webappecho\n        imagePullPolicy: IfNotPresent\n        command: [\"/go/bin/webapp\"]\n        ports:\n        - containerPort: 8080\n        env:\n        - name: MESSAGE\n          value: \"CloudAcademy ❤ DevOps\"\n        - name: BACKGROUND_COLOR\n          value: yellow\n        - name: AUTO_RELOAD\n          value: 30\nEOF\n```","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcloudacademy%2Fweb-echo-app","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcloudacademy%2Fweb-echo-app","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcloudacademy%2Fweb-echo-app/lists"}