LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 03-13-2016, 03:37 PM   #1
novaglider
LQ Newbie
 
Registered: Mar 2016
Posts: 5

Rep: Reputation: Disabled
How to add an entry to a file?


I am new to linux and while installing Docker https://docs.docker.com/engine/insta...x/ubuntulinux/ I got stuck at step 7.

So I am trying to add deb https://apt.dockerproject.org/repo ubuntu-wily main to the docker.list file I created yet nothing seems to work the way it should.

I tried this: http://www.cyberciti.biz/faq/unix-li...ext-to-a-file/
and this: http://unix.stackexchange.com/questi...-the-last-line
and several more yet the closest I get is:

Code:
mitja@mitja-N73SV:/etc/apt/sources.list.d$ sudo echo 'deb https://apt.dockerproject.org/repo ubuntu-wily main' >>docker.list
bash: docker.list: Permission denied
 
Old 03-13-2016, 04:15 PM   #2
BW-userx
LQ Guru
 
Registered: Sep 2013
Location: Somewhere in my head.
Distribution: Slackware (15 current), Slack15, Ubuntu studio, MX Linux, FreeBSD 13.1, WIn10
Posts: 10,342

Rep: Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242
are you trying to add an entry to a file?


Quote:
Open the file in your favorite editor.


$ sudo geany <or your favorite editor> /etc/apt/sources.list.d/docker.list
If the file doesn’t exist, create it.

Remove any existing entries.

Add an entry for your Ubuntu operating system.
Quote:
as you see here you have NO editor with root privileges
right here
Code:
mitja@mitja-N73SV:/etc/apt/sources.list.d$ sudo echo 'deb https://apt.dockerproject.org/repo ubuntu-wily main' >>docker.list
bash: docker.list: Permission denied

Last edited by BW-userx; 03-13-2016 at 04:18 PM.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] do I need to add entry to logrotate? plisken Slackware 5 03-11-2014 01:56 AM
Add Windows XP entry to GRUB bforbes Linux - Software 16 05-25-2011 11:08 AM
Trying to add "Hello world" system call: missing entry.S file courteous Linux - Kernel 5 01-04-2011 07:13 AM
Add route entry ust Linux - Newbie 5 09-04-2008 09:43 PM
add entry to startup? TomalakBORG SUSE / openSUSE 1 11-22-2005 05:53 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 04:09 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration