forked from projectatomic/atomic-site
-
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.
Finished atomic app setup for atomic-site.
- Loading branch information
Showing
10 changed files
with
126 additions
and
6 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
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 |
---|---|---|
@@ -0,0 +1,9 @@ | ||
FROM projectatomic/atomicapp:0.4.2 | ||
|
||
MAINTAINER Red Hat, Inc. <[email protected]> | ||
|
||
LABEL io.projectatomic.nulecule.providers="kubernetes,docker" \ | ||
io.projectatomic.nulecule.specversion="0.0.2" | ||
|
||
ADD /Nulecule /Dockerfile README.md /application-entity/ | ||
ADD /artifacts /application-entity/artifacts |
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,24 @@ | ||
--- | ||
specversion: 0.0.2 | ||
id: atomic-site | ||
|
||
metadata: | ||
name: Atomic Site app | ||
appversion: 0.0.2 | ||
description: Atomic app for testing the Atomic Website | ||
graph: | ||
- name: atomic-site | ||
params: | ||
- name: image | ||
description: The webserver image | ||
default: jberkus/atomic-site | ||
- name: hostport | ||
description: The host TCP port as the external endpoint | ||
default: 4567 | ||
- name: sourcedir | ||
description: location of the middleman source directory | ||
- name: datadir | ||
description: the middleman data directory | ||
artifacts: | ||
docker: | ||
- file://artifacts/docker/atomic-site-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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
# atomic-site atomic app | ||
|
||
This directory contains the configuration files for running the atomic-site | ||
as an atomic app. The guide to bringing it up is in BUILD.md in the main directory. | ||
What's in this file is some additional information about the atomic app setup | ||
for this application. | ||
|
||
## providers | ||
|
||
Currently only the Docker provider is defined for atomic-site. PRs for | ||
other providers are more than welcome. | ||
|
||
## answers.conf | ||
|
||
Here are the current parameters in the answers.conf file, and what they mean: | ||
|
||
* **image**: the usual, currently jberkus/atomic-site until projectatomic/atomic-site goes up | ||
* **hostport**: the port to map to on the host, default 4567 | ||
* **sourcedir**: the full path to the directory of /source in your clone of | ||
the atomic-site repository | ||
* **datadir**: the full path to the directory of /data in your clone of the | ||
atomic-site repository | ||
|
||
## volumes | ||
|
||
Both /source and /data are mounted as volumes. This allows you to branch and edit | ||
contents of the atomic site and see the results in the displayed webpage. | ||
|
||
## autoremove | ||
|
||
Currently, under the Docker provider, atomic-site is set up to autoremove the container | ||
when you exit. |
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,8 @@ | ||
[atomic-site] | ||
image = jberkus/atomic-site | ||
hostport = 4567 | ||
sourcedir = /home/josh/git/redhat/atomic-site-master/source | ||
datadir = /home/josh/git/redhat/atomic-site-master/data | ||
[general] | ||
namespace = default | ||
provider = docker |
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 @@ | ||
docker run --rm -p 4567:4567 --volume /home/josh/git/redhat/atomic-site-master/source:/tmp/source --volume /home/josh/git/redhat/atomic-site-master/data:/tmp/data jberkus/atomic-site |
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 @@ | ||
docker run --rm -p $hostport:4567 --volume $sourcedir:/tmp/source --volume $datadir:/tmp/data $image |
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 |
---|---|---|
@@ -0,0 +1,7 @@ | ||
#/bin/bash | ||
|
||
#tell SELinux to share the Data and Source directories | ||
#with the container | ||
|
||
chcon -Rt svirt_sandbox_file_t source/ | ||
chcon -Rt svirt_sandbox_file_t data/ |