Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
X
xpub-faraday
Manage
Activity
Members
Labels
Plan
Issues
2
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Merge requests
0
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Deploy
Releases
Container Registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
This is an archived project. Repository and other project resources are read-only.
Show more breadcrumbs
xpub
xpub-faraday
Commits
f5b69426
Commit
f5b69426
authored
7 years ago
by
Yannis Barlas
Browse files
Options
Downloads
Plain Diff
Merge branch 'faster-ci' into 'master'
Faster ci Closes #82 See merge request
xpub!84
parents
666deeb6
1805e189
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
.gitlab-ci.yml
+1
-5
1 addition, 5 deletions
.gitlab-ci.yml
Dockerfile
+7
-23
7 additions, 23 deletions
Dockerfile
with
8 additions
and
28 deletions
.gitlab-ci.yml
+
1
−
5
View file @
f5b69426
variables
:
DOCKER_DRIVER
:
overlay
IMAGE_NAME
:
xpub
BASE_DOMAIN
:
gateway.xpub.semioticsquares.com
CONFIGURATION_REPOSITORY
:
https://gitlab.coko.foundation/pubsweet/infra.git
...
...
@@ -14,15 +13,12 @@ stages:
build
:
image
:
docker:latest
services
:
-
docker:dind
stage
:
build
script
:
-
docker version
-
docker login -u $DOCKERHUB_USERNAME -p $DOCKERHUB_PASSWORD
-
echo "Ignore warning! Cannot perform an interactive login from a non TTY device"
-
docker build --pull -t $DOCKERHUB_USERNAME/$IMAGE_NAME .
-
docker tag $DOCKERHUB_USERNAME/$IMAGE_NAME $DOCKERHUB_USERNAME/$IMAGE_NAME:$CI_COMMIT_SHA
-
docker build -t $DOCKERHUB_USERNAME/$IMAGE_NAME:$CI_COMMIT_SHA .
-
docker push $DOCKERHUB_USERNAME/$IMAGE_NAME:$CI_COMMIT_SHA
lint
:
...
...
This diff is collapsed.
Click to expand it.
Dockerfile
+
7
−
23
View file @
f5b69426
FROM
node:8.9-alpine
MAINTAINER
PubSweet Team <richard@coko.foundation>
FROM
xpub/xpub:base
ENV
HOME "/home/xpub"
RUN
mkdir
-p
${
HOME
}
# git required for yarn. Why isn't it included!?
# the rest is for compiling leveldown
RUN
apk add
--no-cache
--virtual
.gyp
\
python
\
curl
\
make
\
g++
\
git
RUN
git config
--global
user.email
"test@testing.com"
&&
\
git config
--global
user.name
"Fakey McFakerson"
WORKDIR
${HOME}
COPY
package.json yarn.lock lerna.json .eslintignore .eslintrc .prettierrc .stylelintignore .stylelintrc ./
COPY
package.json yarn.lock ./
COPY
lerna.json .eslintignore .eslintrc .prettierrc .stylelintignore .stylelintrc ./
COPY
packages packages
RUN
[
"yarn"
,
"config"
,
"set"
,
"workspaces-experimental"
,
"true"
]
# We do a development install because react-styleguidist is a dev dependency
RUN
[
"yarn"
,
"install"
,
"--frozen-lockfile"
]
RUN
[
"npm"
,
"rebuild"
,
"bcrypt"
,
"--build-from-source=bcrypt"
]
# Remove cache and offline mirror
RUN
[
"yarn"
,
"cache"
,
"clean"
]
RUN
[
"rm"
,
"-rf"
,
"/npm-packages-offline-cache"
]
ENV
NODE_ENV "production"
# We are temporarily going to use the same image with different commands to deploy different apps in the monorepo. This is bad :(.
WORKDIR
${HOME}/packages/xpub-collabra
# TODO pass in username and password as build arguments
RUN
[
"npx"
,
"pubsweet"
,
"build"
]
## No xpub-ui to deploy yet
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment