Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
Sharkey
Manage
Activity
Members
Labels
Plan
Issues
0
Issue boards
Milestones
Wiki
Requirements
Code
Merge requests
0
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Dima Krasner
Sharkey
Commits
3720a7fb
Unverified
Commit
3720a7fb
authored
6 years ago
by
syuilo
Browse files
Options
Downloads
Plain Diff
Merge branch 'develop' of
https://github.com/syuilo/misskey
into develop
parents
7afa541a
6f979c82
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
.ci/default.yml
+0
-0
0 additions, 0 deletions
.ci/default.yml
.ci/test.yml
+0
-0
0 additions, 0 deletions
.ci/test.yml
.circleci/config.yml
+103
-34
103 additions, 34 deletions
.circleci/config.yml
.travis.yml
+2
-2
2 additions, 2 deletions
.travis.yml
Dockerfile
+6
-5
6 additions, 5 deletions
Dockerfile
with
111 additions
and
41 deletions
.
travis
/default.yml
→
.
ci
/default.yml
+
0
−
0
View file @
3720a7fb
File moved
This diff is collapsed.
Click to expand it.
.
travis
/test.yml
→
.
ci
/test.yml
+
0
−
0
View file @
3720a7fb
File moved
This diff is collapsed.
Click to expand it.
.circleci/config.yml
+
103
−
34
View file @
3720a7fb
version
:
2
version
:
2
.1
general
:
branches
:
ignore
:
-
l10n_develop
-
imgbot
jobs
:
webpack-build
:
working_directory
:
/misskey
executors
:
default
:
working_directory
:
/tmp/workspace
docker
:
-
image
:
misskey/ci:latest
-
image
:
circleci/mongo:latest
-
image
:
circleci/redis:latest
docker
:
working_directory
:
/tmp/workspace
docker
:
-
image
:
yukimochi/misskey-builder:latest
-
image
:
docker:latest
jobs
:
build
:
executor
:
default
steps
:
-
checkout
-
restore_cache
:
name
:
Restore npm package caches
keys
:
-
npm-v1-arch-{{ arch }}-env-{{ .Environment.variableName }}-package-{{ checksum "package.json" }}-lock-{{ checksum "package-lock.json" }}-
-
npm-v1-arch-{{ arch }}-env-{{ .Environment.variableName }}-package-{{ checksum "package.json" }}-
-
npm-v1-arch-{{ arch }}-env-{{ .Environment.variableName }}-
-
npm-v1-arch-{{ arch }}-
-
npm-v1-
-
run
:
name
:
Setup Dependencies
command
:
|
yarn install
yarn global add web-push
-
run
:
name
:
Import default.yml
name
:
Install Dependencies
command
:
|
echo ${IMPORT_DEFAULT_YML} | base64 -d | gzip -d > .config/default.ym
l
npm instal
l
-
run
:
name
:
Build Webpack
name
:
Configure
command
:
|
yarn run build
cp .ci/default.yml .config
cp .ci/test.yml .config
-
run
:
name
:
Compress clients
name
:
Build
command
:
|
find ./built/client -name "*.js" -or -name "*.js.map" -or -name "*.css" -or -name "*.svg" -or -name "*.html" -or -name "*.json" | xargs -t gzip -k -9
find ./built/client -name "*.js" -or -name "*.js.map" -or -name "*.css" -or -name "*.svg" -or -name "*.html" -or -name "*.json" | xargs -t brotli -q 10
tar cfz ~/built-${CIRCLE_SHA1}.tar.gz built
npm run build || (echo -e '\033[0;34mRebuild modules\033[0;39m' && ls -1A node_modules | grep '^[^@]' | xargs npm rebuild && ls -1A node_modules | grep '^@' | xargs -I%1 sh -c 'ls -1A node_modules/'%1' | xargs -P0 -I%2 npm rebuild node_modules/'%1'/%2' && npm run build)
ls -1ARl node_modules > ls
-
save_cache
:
name
:
Cache npm packages
key
:
npm-v1-arch-{{ arch }}-env-{{ .Environment.variableName }}-package-{{ checksum "package.json" }}-lock-{{ checksum "package-lock.json" }}-ls-{{ checksum "ls" }}
paths
:
-
node_modules
-
store_artifacts
:
path
:
built
-
persist_to_workspace
:
root
:
.
paths
:
-
.
test
:
parameters
:
without_redis
:
type
:
string
default
:
"
"
executor
:
default
steps
:
-
attach_workspace
:
at
:
/tmp/workspace
-
when
:
condition
:
<<parameters.without_redis>>
steps
:
-
run
:
name
:
Configure
command
:
|
mv .config/test.yml .config/test_redis.yml
touch .config/test.yml
cat .config/test_redis.yml | while IFS= read line; do if [[ "$line" = '# __REDIS__' ]]; then break; else echo "$line" >> .config/test.yml; fi; done
-
run
:
name
:
Send built s3
name
:
Test
command
:
|
mc config host add ykmc ${s3_endpoint} ${s3_accesskey} ${s3_secretkey}
mc cp ~/built-${CIRCLE_SHA1}.tar.gz ${backet}/${CIRCLE_BRANCH}/
docker-build
:
docker
:
-
image
:
docker:17-git
npm run test || (npm rebuild && npm run test) || ((node-gyp configure && node-gyp build && npm run build || (echo -e '\033[0;34mRebuild modules\033[0;39m' && ls -1A node_modules | grep '^[^@]' | xargs npm rebuild && ls -1A node_modules | grep '^@' | xargs -I%1 sh -c 'ls -1A node_modules/'%1' | xargs -P0 -I%2 npm rebuild node_modules/'%1'/%2' && npm run build)) && npm run test)
ls -1ARl node_modules > ls
-
save_cache
:
name
:
Cache npm packages
key
:
npm-v1-arch-{{ arch }}-env-{{ .Environment.variableName }}-package-{{ checksum "package.json" }}-lock-{{ checksum "package-lock.json" }}-ls-{{ checksum "ls" }}
paths
:
-
node_modules
docker
:
parameters
:
with_deploy
:
type
:
string
default
:
"
"
executor
:
docker
steps
:
-
checkout
-
setup_remote_docker
-
run
:
name
:
b
uild
docker image
name
:
B
uild
command
:
|
docker build -t misskey:latest .
-
run
:
name
:
upload image to docker hub.
command
:
|
docker login --username=${DOCKER_USER} --password=${DOCKER_PASS}
docker push ${DOCKER_USER}/misskey:latest
docker build .
-
when
:
condition
:
<<parameters.with_deploy>>
steps
:
-
run
:
name
:
Deploy
command
:
|
docker login -u $DOCKERHUB_USERNAME -p $DOCKERHUB_PASSWORD && docker push misskey/misskey
workflows
:
version
:
2
build
:
build
-and-test
:
jobs
:
-
webpack-build
-
docker-build
-
build
-
test
:
requires
:
-
build
-
test
:
without_redis
:
"
true"
requires
:
-
build
-
docker
:
filters
:
branches
:
ignore
:
master
-
docker
:
with_deploy
:
"
true"
filters
:
branches
:
only
:
master
This diff is collapsed.
Click to expand it.
.travis.yml
+
2
−
2
View file @
3720a7fb
...
...
@@ -35,7 +35,7 @@ before_script:
-
npm install
# 設定ファイルを配置
-
cp ./.
travis
/default.yml ./.config
-
cp ./.
travis
/test.yml ./.config
-
cp ./.
ci
/default.yml ./.config
-
cp ./.
ci
/test.yml ./.config
-
travis_wait npm run build
This diff is collapsed.
Click to expand it.
Dockerfile
+
6
−
5
View file @
3720a7fb
...
...
@@ -21,11 +21,12 @@ RUN apk add --no-cache \
pkgconfig
\
libtool
\
zlib-dev
RUN
npm
install
\
&&
npm
install
-g
node-gyp
\
&&
node-gyp configure
\
&&
node-gyp build
\
&&
npm run build
RUN
npm i
-g
npm@latest
\
&&
npm i
\
&&
npm i
-g
node-gyp
\
&&
node-gyp configure
\
&&
node-gyp build
\
&&
npm run build
FROM
base
AS
runner
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
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