Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
docker-ICEcoder
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
JetBrains YouTrack
External wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
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
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
This is an archived project. Repository and other project resources are read-only.
Show more breadcrumbs
Griefed
docker-ICEcoder
Commits
904a63ac
Commit
904a63ac
authored
4 years ago
by
Griefed
Browse files
Options
Downloads
Patches
Plain Diff
Cleanup and fixes
parent
62e4d606
No related branches found
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
root/etc/cont-init.d/40-install
+7
-4
7 additions, 4 deletions
root/etc/cont-init.d/40-install
root/etc/cont-init.d/50-config
+40
-2
40 additions, 2 deletions
root/etc/cont-init.d/50-config
root/etc/cont-init.d/60-git
+0
-39
0 additions, 39 deletions
root/etc/cont-init.d/60-git
with
47 additions
and
45 deletions
root/etc/cont-init.d/40-install
+
7
−
4
View file @
904a63ac
...
...
@@ -6,13 +6,16 @@ if [ ! -f "/config/www/ICEcoder/index.php" ]; then
"https://github.com/icecoder/ICEcoder/archive/
${
ICECODER_VERSION
}
.zip"
cd
/tmp
||
exit
unzip
-qq
install.zip
mkdir
/plugins
mv
ICEcoder-
*
/data/
*
/data/
mv
ICEcoder-
*
/plugins/
*
/plugins/
mv
ICEcoder-
*
/data/.gitkeep /data/
mv
ICEcoder-
*
/plugins/index.php /plugins/
mv
ICEcoder-
*
/app/ICEcoder
cd
/
||
exit
rm
-rf
/tmp/
*
/config/www/data
rm
-rf
/app/ICEcoder/data
rm
-rf
/app/ICEcoder/plugins
chown
-R
abc:abc /app/ICEcoder
chown
-R
abc:abc
\
/app/ICEcoder
\
/data
\
/config
\
/plugins
fi
This diff is collapsed.
Click to expand it.
root/etc/cont-init.d/50-config
+
40
−
2
View file @
904a63ac
...
...
@@ -6,6 +6,44 @@ ln -sf /plugins /app/ICEcoder/plugins
# permissions
chown
-R
abc:abc
\
/config
/data
/config
\
/data
\
/plugins
# check for lock file to only run git operations once
if
[
!
-e
/lock.file
]
;
then
# Give abc a sudo shell for development
chsh abc
-s
/bin/bash
sed
-e
's/# %wheel ALL=(ALL) NOPASSWD: ALL/%wheel ALL=(ALL) NOPASSWD: ALL/g'
\
-i
/etc/sudoers
sed
-e
's/^wheel:\(.*\)/wheel:\1,abc/g'
-i
/etc/group
# create directory for project
mkdir
-p
/data/code
# make sure URL is set and folder is empty to clone code
if
[
${
GITURL
+x
}
]
&&
[
!
"
$(
/bin/ls
-A
/data/code 2>/dev/null
)
"
]
;
then
\
# clone the url the user passed to this directory
git clone
"
${
GITURL
}
"
/data/code
fi
else
# lock exists not importing project this is a restart
echo
"Lock exists just starting pylon"
fi
# create lock file after first run
touch
/lock.file
# copy php ini for user editing
[[
!
-e
"/config/php/php.ini"
]]
&&
\
cp
/etc/php7/php.ini /config/php/php.ini
cp
/config/php/php.ini /etc/php7/php.ini
# permissions
mkdir
-p
/config/sessions
echo
"[cont-init.d] Setting permissions this may take some time"
chown
-R
abc:abc
\
/data
\
/config
\
/plugins
# make our folders
mkdir
-p
\
/config/
{
log/ICEcoder,php,sess
}
This diff is collapsed.
Click to expand it.
root/etc/cont-init.d/60-git
deleted
100644 → 0
+
0
−
39
View file @
62e4d606
#!/usr/bin/with-contenv bash
# check for lock file to only run git operations once
if
[
!
-e
/lock.file
]
;
then
# Give abc a sudo shell for development
chsh abc
-s
/bin/bash
sed
-e
's/# %wheel ALL=(ALL) NOPASSWD: ALL/%wheel ALL=(ALL) NOPASSWD: ALL/g'
\
-i
/etc/sudoers
sed
-e
's/^wheel:\(.*\)/wheel:\1,abc/g'
-i
/etc/group
# create directory for project
mkdir
-p
/data/code
# make sure URL is set and folder is empty to clone code
if
[
${
GITURL
+x
}
]
&&
[
!
"
$(
/bin/ls
-A
/data/code 2>/dev/null
)
"
]
;
then
\
# clone the url the user passed to this directory
git clone
"
${
GITURL
}
"
/data/code
fi
else
# lock exists not importing project this is a restart
echo
"Lock exists just starting pylon"
fi
# create lock file after first run
touch
/lock.file
# copy php ini for user editing
[[
!
-e
"/config/php/php.ini"
]]
&&
\
cp
/etc/php7/php.ini /config/php/php.ini
cp
/config/php/php.ini /etc/php7/php.ini
# permissions
mkdir
-p
/config/sessions
echo
"[cont-init.d] Setting permissions this may take some time"
chown
-R
abc:abc
\
/data
\
/config
/plugins
# make our folders
mkdir
-p
\
/config/
{
log/ICEcoder,php,sess
}
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